2002-01-17 23:49:08 +03:00
|
|
|
#
|
|
|
|
# A simple test case
|
|
|
|
#
|
2001-08-23 21:57:45 +04:00
|
|
|
PROJECT (Complex)
|
|
|
|
|
2002-01-17 23:49:08 +03:00
|
|
|
#
|
|
|
|
# Use the ansi CXX compile flag for building cmake
|
|
|
|
#
|
2001-08-29 00:06:52 +04:00
|
|
|
IF (CMAKE_ANSI_CXXFLAGS)
|
|
|
|
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_ANSI_CXXFLAGS}")
|
|
|
|
ENDIF (CMAKE_ANSI_CXXFLAGS)
|
2001-08-27 18:11:48 +04:00
|
|
|
|
2001-08-23 21:57:45 +04:00
|
|
|
ADD_DEFINITIONS(-DCMAKE_IS_FUN)
|
|
|
|
|
|
|
|
INCLUDE(${Complex_SOURCE_DIR}/VarTests.txt)
|
|
|
|
|
|
|
|
CONFIGURE_FILE(
|
2002-01-17 23:49:08 +03:00
|
|
|
${Complex_SOURCE_DIR}/cmTestConfigure.h.in
|
|
|
|
${Complex_BINARY_DIR}/cmTestConfigure.h)
|
2001-08-23 21:57:45 +04:00
|
|
|
|
|
|
|
INCLUDE_DIRECTORIES(
|
2002-01-17 23:49:08 +03:00
|
|
|
${Complex_BINARY_DIR}
|
|
|
|
${Complex_SOURCE_DIR}/Library
|
|
|
|
${Complex_SOURCE_DIR}/../../Source
|
2001-08-23 21:57:45 +04:00
|
|
|
)
|
2002-01-17 23:49:08 +03:00
|
|
|
|
2001-08-23 21:57:45 +04:00
|
|
|
LINK_DIRECTORIES(
|
2002-01-17 23:49:08 +03:00
|
|
|
${Complex_BINARY_DIR}/Library
|
2001-08-23 21:57:45 +04:00
|
|
|
)
|
|
|
|
|
|
|
|
INCLUDE_REGULAR_EXPRESSION("^(cmTest|file|sharedFile).*$")
|
|
|
|
|
2002-01-17 23:49:08 +03:00
|
|
|
SET (LIBRARY_OUTPUT_PATH
|
|
|
|
${Complex_BINARY_DIR}/bin/ CACHE PATH
|
|
|
|
"Single output directory for building all libraries.")
|
|
|
|
|
|
|
|
SET (EXECUTABLE_OUTPUT_PATH
|
|
|
|
${Complex_BINARY_DIR}/bin/ CACHE PATH
|
|
|
|
"Single output directory for building all executables.")
|
|
|
|
|
|
|
|
#
|
|
|
|
# Where will executable tests be written ?
|
|
|
|
#
|
|
|
|
IF (EXECUTABLE_OUTPUT_PATH)
|
|
|
|
SET (CXX_TEST_PATH ${EXECUTABLE_OUTPUT_PATH})
|
|
|
|
ELSE (EXECUTABLE_OUTPUT_PATH)
|
|
|
|
SET (CXX_TEST_PATH .)
|
|
|
|
ENDIF (EXECUTABLE_OUTPUT_PATH)
|
|
|
|
|
|
|
|
SUBDIRS(Library Executable)
|
|
|
|
SUBDIR_DEPENDS(Executable Library)
|
|
|
|
|
|
|
|
|