summaryrefslogtreecommitdiffstats
path: root/Modules/CMakeDefaultMakeRuleVariables.cmake
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2002-10-23 20:53:53 (GMT)
committerBill Hoffman <bill.hoffman@kitware.com>2002-10-23 20:53:53 (GMT)
commitfa782867b33a8a5569d88de5b1f0b5f968e3cd6f (patch)
treeb1f69679d18c58433efa0671d205e9641e0eb91a /Modules/CMakeDefaultMakeRuleVariables.cmake
parentf6a70573b0c87c285bc798e479435c9a3c1d1fe6 (diff)
downloadCMake-fa782867b33a8a5569d88de5b1f0b5f968e3cd6f.zip
CMake-fa782867b33a8a5569d88de5b1f0b5f968e3cd6f.tar.gz
CMake-fa782867b33a8a5569d88de5b1f0b5f968e3cd6f.tar.bz2
closer to removing autoconf
Diffstat (limited to 'Modules/CMakeDefaultMakeRuleVariables.cmake')
-rw-r--r--Modules/CMakeDefaultMakeRuleVariables.cmake69
1 files changed, 69 insertions, 0 deletions
diff --git a/Modules/CMakeDefaultMakeRuleVariables.cmake b/Modules/CMakeDefaultMakeRuleVariables.cmake
new file mode 100644
index 0000000..d0134fc
--- /dev/null
+++ b/Modules/CMakeDefaultMakeRuleVariables.cmake
@@ -0,0 +1,69 @@
+# this file contains rule variables that tell cmake how to
+# do things like build a .o file, create a shared or static library
+#
+
+# create a shared C++ librar
+IF(NOT CMAKE_CXX_CREATE_SHARED_LIBRARY)
+ SET(CMAKE_CXX_CREATE_SHARED_LIBRARY
+ "${CMAKE_CXX_COMPILER} ${CMAKE_SHARED_LIBRARY_CREATE_FLAGS} "
+ "${CMAKE_CXX_LINK_SHARED_OUT_FLAG} <TARGET> <OBJECTS>")
+ENDIF(NOT CMAKE_CXX_CREATE_SHARED_LIBRARY)
+
+# create a c++ shared module
+IF(NOT CMAKE_CXX_CREATE_SHARED_MODULE)
+ SET(CMAKE_CXX_CREATE_SHARED_MODULE
+ "${CMAKE_CXX_COMPILER} ${CMAKE_SHARED_MODULE_CREATE_FLAGS} "
+ "${CMAKE_CXX_LINK_SHARED_OUT_FLAG} <TARGET> <OBJECTS>")
+ENDIF(NOT CMAKE_CXX_CREATE_SHARED_MODULE)
+
+# create a C shared library
+IF(NOT CMAKE_C_CREATE_SHARED_LIBRARY)
+ SET(CMAKE_C_CREATE_SHARED_LIBRARY
+ "${CMAKE_C_COMPILER} ${CMAKE_SHARED_LIBRARY_CREATE_FLAGS} "
+ "${CMAKE_C_LINK_SHARED_OUT_FLAG} <TARGET> <OBJECTS>")
+ENDIF(NOT CMAKE_C_CREATE_SHARED_LIBRARY)
+
+# create a C shared module
+IF(NOT CMAKE_C_CREATE_SHARED_MODULE)
+ SET(CMAKE_C_CREATE_SHARED_MODULE
+ "${CMAKE_C_COMPILER} ${CMAKE_SHARED_MODULE_CREATE_FLAGS} "
+ "${CMAKE_C_LINK_SHARED_OUT_FLAG} <TARGET> <OBJECTS>")
+ENDIF(NOT CMAKE_C_CREATE_SHARED_MODULE)
+
+# create a C++ static library
+IF(NOT CMAKE_CXX_CREATE_STATIC_LIBRARY)
+ SET(CMAKE_CXX_CREATE_STATIC_LIBRARY
+ "${CMAKE_CXX_AR} cr <TARGET> <OBJECTS> "
+ "${CMAKE_RANLIB} <TARGET> ")
+ENDIF(NOT CMAKE_CXX_CREATE_STATIC_LIBRARY)
+
+# create a C static library
+IF(NOT CMAKE_C_CREATE_STATIC_LIBRARY)
+ SET(CMAKE_C_CREATE_STATIC_LIBRARY
+ "${CMAKE_AR} cr <TARGET> <OBJECTS> "
+ "${CMAKE_RANLIB} <TARGET> ")
+ENDIF(NOT CMAKE_C_CREATE_STATIC_LIBRARY)
+
+# compile a C++ file into an object file
+IF(NOT CMAKE_CXX_COMPILE_OBJECT)
+ SET(CMAKE_CXX_COMPILE_OBJECT
+ "${CMAKE_CXX_COMPILER} -o <OBJECT> <INCLUDE_FLAGS> <SHARED_FLAGS> ${CMAKE_CXX_FLAGS} -c <SOURCE>")
+ENDIF(NOT CMAKE_CXX_COMPILE_OBJECT)
+
+# compile a C file into an object file
+IF(NOT CMAKE_C_COMPILE_OBJECT)
+ SET(CMAKE_C_COMPILE_OBJECT
+ "${CMAKE_C_COMPILER} -o <OBJECT> <INCLUDE_FLAGS> <SHARED_FLAGS> ${CMAKE_C_FLAGS} -c <SOURCE>")
+ENDIF(NOT CMAKE_C_COMPILE_OBJECT)
+
+
+IF(NOT CMAKE_C_LINK_EXECUTABLE)
+ SET(CMAKE_C_LINK_EXECUTABLE
+ "${CMAKE_C_COMPILER} <SHARED_FLAGS> <OBJECTS> -o <TARGET> ")
+ENDIF(NOT CMAKE_C_LINK_EXECUTABLE)
+
+
+IF(NOT CMAKE_CXX_LINK_EXECUTABLE)
+ SET(CMAKE_CXX_LINK_EXECUTABLE
+ "${CMAKE_CXX_COMPILER} <SHARED_FLAGS> <OBJECTS> -o <TARGET> ")
+ENDIF(NOT CMAKE_CXX_LINK_EXECUTABLE)