[Cmake] FW: contruction of variable names

Dekeyser, Kris Kris.Dekeyser at lms.be
Thu Aug 19 13:00:33 EDT 2004


I'm trying this code with CMake 2.0.3:

# project's name
SET(ThisProject "LMSCft")

#--- exported header files
INCLUDE_DIRECTORIES(${${ThisProject}_SOURCE_DIR}/export/include)

But the include directory is "_SOURCE_DIR}/export/include" in the MSDev
project file. 
I expected to have "<Source dir of the LMSCft project>/export/include". It
seems as if
the first ${ gets "eaten" by the rest. What did I do wrong?

BTW, in the CMake book (version 1.8) on page 33, the example says:

IF( ${${tfile}}_TEST_RESULT} MATCHES FAILED)
[...]

Notice the unbalanced } due to the double } after tfile. Is that a typo? 
I tried the same in my code, but ended up with
"}_SOURCE_DIR}/export/include". Not correct either.

- Kris
+-+-+- Email Confidentiality Footer +-+-+- 
Privileged/Confidential Information may be contained in this message. If you
are not the addressee indicated in this message (or responsible for delivery
of the message to such person), you may not print, retain, copy nor
disseminate this message or any part of it to anyone and you should notify
the sender by reply email and destroy this message. Neglecting this clause
could be a breach of confidence. Please advise immediately if you or your
employer does not consent to Internet email for messages of this kind.
Opinions, conclusions and other information in this message that are not
related to the official business of my firm shall be understood as neither
given nor endorsed by it.


More information about the Cmake mailing list