Consider the following:
SET(TEST_DIR, "test")
INSTALL(PROGRAMS scripts/foo.py DESTINATION ${TEST_DIR})
INSTALL(PROGRAMS scripts/foo.py DESTINATION @TEST_DIR@)
The first INSTALL
command does not work. The second does. Why is that? What is the difference between those two? I have not found any reference to @@
expansion except in the context of creation of configuration files. Everything else only uses ${}
expansion.
UPDATE: OK, obvious bug in the above. My SET()
command has an extraneous comma. Removing it, such that it looks like:
SET(TEST_DIR "test")
results in both @@
and ${}
expansions working. Still wondering (a) what is the meaning of @@
as opposed to ${}
, and why only the former worked with my incorrect SET()
statement.