CMake/Tests/SubDir/CMakeLists.txt

17 lines
482 B
CMake

PROJECT(SUBDIR)
SUBDIRS(Executable EXCLUDE_FROM_ALL Examples)
WRITE_FILE(${SUBDIR_BINARY_DIR}/ShouldBeHere "This file should exist.")
ADD_EXECUTABLE(TestFromSubdir
AnotherSubdir/testfromsubdir.c
AnotherSubdir/secondone
AnotherSubdir/pair+int.int.c
vcl_algorithm+vcl_pair+double.foo.c
)
AUX_SOURCE_DIRECTORY(ThirdSubDir SOURCES)
SET(SOURCES ${SOURCES}
vcl_algorithm+vcl_pair+double.foo.c)
MESSAGE("Sources: ${SOURCES}")
ADD_EXECUTABLE(TestWithAuxSourceDir ${SOURCES})