[CMake] EXEC_PROGRAM question
Doug Henry
brilligent at gmail.com
Fri Mar 25 11:05:01 EST 2005
I am doing the following command in my top level CMakeLists.txt file:
EXEC_PROGRAM(
date
ARGS +%y%j
OUTPUT_VARIABLE DATEVAR)
ADD_DEFINITIONS(-DDATESTR=${DATEVAR})
The thing I don't understand is that DATEVAR is only defined in the
top-level makefile. It does not appear in other subdirs/projects.
How do I get the DATEVAR variable to be cached and useable in a more
global way (e.g. like traditional SET statements)?
More information about the CMake
mailing list