diff options
author | Bill Hoffman <bill.hoffman@kitware.com> | 2002-04-02 20:43:23 (GMT) |
---|---|---|
committer | Bill Hoffman <bill.hoffman@kitware.com> | 2002-04-02 20:43:23 (GMT) |
commit | 4ea0f6b9494f2b4a4a5a238f8ad51ee6fbbcfe0a (patch) | |
tree | b73c04c8bce53edbdf39e3e98ae6e2a361f47bef /Source/CMakeLists.txt | |
parent | 81ebecaea17cc18dfdda4fc3051eba08f6f076a0 (diff) | |
download | CMake-4ea0f6b9494f2b4a4a5a238f8ad51ee6fbbcfe0a.zip CMake-4ea0f6b9494f2b4a4a5a238f8ad51ee6fbbcfe0a.tar.gz CMake-4ea0f6b9494f2b4a4a5a238f8ad51ee6fbbcfe0a.tar.bz2 |
ENH: add enable language support for PROJECT command, this means that a C only project can be built with cmake, even without a cxx compiler
Diffstat (limited to 'Source/CMakeLists.txt')
-rw-r--r-- | Source/CMakeLists.txt | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/Source/CMakeLists.txt b/Source/CMakeLists.txt index bab332e..71ced9a 100644 --- a/Source/CMakeLists.txt +++ b/Source/CMakeLists.txt @@ -1,4 +1,4 @@ -SOURCE_FILES(SRCS +SET(SRCS cmake.cxx cmakewizard.cxx cmMakeDepend.cxx @@ -37,13 +37,15 @@ cmListFileCache.h CONFIGURE_FILE( ${CMake_SOURCE_DIR}/Source/cmConfigure.cmake.h.in ${CMake_BINARY_DIR}/Source/cmConfigure.h ) + # add the include path to find the .h INCLUDE_DIRECTORIES(${CMake_BINARY_DIR}/Source) + # let cmake know it is supposed to use it ADD_DEFINITIONS(-DCMAKE_BUILD_WITH_CMAKE) IF (WIN32) - SOURCE_FILES(SRCS + SET(SRCS ${SRCS} cmDSWWriter.cxx cmDSPWriter.cxx cmMSProjectGenerator.cxx @@ -73,17 +75,17 @@ IF (UNIX) ENDIF (CURSES_LIBRARY) ENDIF (UNIX) -SOURCE_FILES(SRCS cmUnixMakefileGenerator.cxx cmUnixMakefileGenerator.h) +SET(SRCS ${SRCS} cmUnixMakefileGenerator.cxx cmUnixMakefileGenerator.h) # create a library used by the command line and the GUI -ADD_LIBRARY(CMakeLib SRCS) +ADD_LIBRARY(CMakeLib ${SRCS}) # always link in the library LINK_LIBRARIES(CMakeLib) # the library is found here LINK_DIRECTORIES(${CMake_BINARY_DIR}/Source) -ADD_EXECUTABLE(cmake cmakemain) +ADD_EXECUTABLE(cmake cmakemain.cxx) ADD_EXECUTABLE(DumpDocumentation cmDumpDocumentation) ADD_EXECUTABLE(ctest ctest.cxx cmSystemTools.cxx cmRegularExpression.cxx) @@ -106,6 +108,11 @@ IF(BUILD_TESTING) ${CMake_BINARY_DIR}/Tests/Simple simple) + ADD_TEST(conly ${CMake_BINARY_DIR}/Source/cmaketest + ${CMake_SOURCE_DIR}/Tests/COnly + ${CMake_BINARY_DIR}/Tests/COnly + conly) + ADD_TEST(complex ${CMake_BINARY_DIR}/Source/cmaketest ${CMake_SOURCE_DIR}/Tests/Complex ${CMake_BINARY_DIR}/Tests/Complex |