If you have set MY_PATH variable using SET(MY_PATH  XXXX)
then INCLUDE_DIRECTORIES(${MY_PATH}/XXX/XXX) should work.

if you want to get from environment variable use $ENV{MY_PATH}.

Vikranth
--------------------------------------------------
From: "Tyler Roscoe" <[email protected]>
Sent: Wednesday, April 22, 2009 10:23 AM
To: "Peterson, Isaac F." <[email protected]>
Cc: <[email protected]>
Subject: Re: [CMake] How to insert environment variable inINCLUDE_DIRECTORIES

On Tue, Apr 21, 2009 at 08:08:34PM -0500, Peterson, Isaac F. wrote:
I'd like to do the following

INCLUDE_DIRECTORIES(
   include
   some_local_folder/include
   $(MY_PATH)/some_library/include
)

Which would generate the following includes in VS:

..\include
..\some_local_folder\include
$(MY_PATH)\some_library\include

Did you try getting creative with quotes and/or backslashes? Something
like \$\(MY_PATH\) might get the job done.

tyler
_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to