From 90f36bba94661dde8e12600c690ec3a111425b6c Mon Sep 17 00:00:00 2001 From: Alexander Neundorf Date: Sun, 29 Jan 2006 09:46:30 +0000 Subject: -make "make install" work in kate/data/ -add cmake/systeminfo/CMakeLists.txt, which prints out useful information when run Alex svn path=/trunk/KDE/kdelibs/; revision=503448 --- systeminfo/CMakeLists.txt | 34 ++++++++++++++++++++++++++++++++++ systeminfo/README | 6 ++++++ 2 files changed, 40 insertions(+) create mode 100644 systeminfo/CMakeLists.txt create mode 100644 systeminfo/README (limited to 'systeminfo') diff --git a/systeminfo/CMakeLists.txt b/systeminfo/CMakeLists.txt new file mode 100644 index 00000000..a134ee78 --- /dev/null +++ b/systeminfo/CMakeLists.txt @@ -0,0 +1,34 @@ +message(STATUS "-----------------------------------") +message(STATUS "Printing system information: ") +message(STATUS "-----------------------------------") +message(STATUS "C compiler: ${CMAKE_C_COMPILER}") +message(STATUS "CXX compiler: ${CMAKE_CXX_COMPILER}") +message(STATUS "C compiler is gcc: ${CMAKE_COMPILER_IS_GNUCC}") +message(STATUS "CXX compiler is g++: ${CMAKE_COMPILER_IS_GNUCXX}") +message(STATUS "System: ${CMAKE_SYSTEM}") +message(STATUS "System name: ${CMAKE_SYSTEM_NAME}") +message(STATUS "System version: ${CMAKE_SYSTEM_VERSION}") + +if(UNIX) + message(STATUS "This is some kind of UNIX environment") +endif(UNIX) + +if(WIN32) + message(STATUS "This is Windows") +endif(WIN32) + +if(APPLE) + message(STATUS "This is an Apple") +endif(APPLE) + +if(MINGW) + message(STATUS "This is MinGW") +endif(MINGW) + +if(CYGWIN) + message(STATUS "This is Cygwin") +endif(CYGWIN) + + +message(STATUS "-----------------------------------") + diff --git a/systeminfo/README b/systeminfo/README new file mode 100644 index 00000000..ec080fa8 --- /dev/null +++ b/systeminfo/README @@ -0,0 +1,6 @@ +Run cmake on the CMakeLists.txt file in this directory and it will print out +the value of some cmake variables. These variables can be used in +CMakeLists.txt to determine the current system type. + +Alex + -- cgit v1.2.1 From 773bcd10a8e1f8ebc9cb64bb0db91f86f745085e Mon Sep 17 00:00:00 2001 From: Alexander Neundorf Date: Sun, 29 Jan 2006 13:51:46 +0000 Subject: also write a log file SystemInfo.txt Alex svn path=/trunk/KDE/kdelibs/; revision=503519 --- systeminfo/CMakeLists.txt | 32 +++++++++++++++++++------------- 1 file changed, 19 insertions(+), 13 deletions(-) (limited to 'systeminfo') diff --git a/systeminfo/CMakeLists.txt b/systeminfo/CMakeLists.txt index a134ee78..d78e37f3 100644 --- a/systeminfo/CMakeLists.txt +++ b/systeminfo/CMakeLists.txt @@ -1,34 +1,40 @@ +macro(LOG line) + message(STATUS ${line}) + file(APPEND ${CMAKE_CURRENT_BINARY_DIR}/SystemInfo.txt "${line}\n") +endmacro(LOG line) + +file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/SystemInfo.txt "CMake system information: \n") message(STATUS "-----------------------------------") message(STATUS "Printing system information: ") message(STATUS "-----------------------------------") -message(STATUS "C compiler: ${CMAKE_C_COMPILER}") -message(STATUS "CXX compiler: ${CMAKE_CXX_COMPILER}") -message(STATUS "C compiler is gcc: ${CMAKE_COMPILER_IS_GNUCC}") -message(STATUS "CXX compiler is g++: ${CMAKE_COMPILER_IS_GNUCXX}") -message(STATUS "System: ${CMAKE_SYSTEM}") -message(STATUS "System name: ${CMAKE_SYSTEM_NAME}") -message(STATUS "System version: ${CMAKE_SYSTEM_VERSION}") + +log("C compiler: ${CMAKE_C_COMPILER}") +log("CXX compiler: ${CMAKE_CXX_COMPILER}") +log("C compiler is gcc: ${CMAKE_COMPILER_IS_GNUCC}") +log("CXX compiler is g++: ${CMAKE_COMPILER_IS_GNUCXX}") +log("System: ${CMAKE_SYSTEM}") +log("System name: ${CMAKE_SYSTEM_NAME}") +log("System version: ${CMAKE_SYSTEM_VERSION}") if(UNIX) - message(STATUS "This is some kind of UNIX environment") + log("This is some kind of UNIX environment") endif(UNIX) if(WIN32) - message(STATUS "This is Windows") + log("This is Windows") endif(WIN32) if(APPLE) - message(STATUS "This is an Apple") + log("This is an Apple") endif(APPLE) if(MINGW) - message(STATUS "This is MinGW") + log("This is MinGW") endif(MINGW) if(CYGWIN) - message(STATUS "This is Cygwin") + log("This is Cygwin") endif(CYGWIN) - message(STATUS "-----------------------------------") -- cgit v1.2.1 From ce810f657f2c4f53cba4624e00bdb05edb8c3c18 Mon Sep 17 00:00:00 2001 From: Alexander Neundorf Date: Sun, 29 Jan 2006 16:48:53 +0000 Subject: borland test Alex svn path=/trunk/KDE/kdelibs/; revision=503587 --- systeminfo/CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'systeminfo') diff --git a/systeminfo/CMakeLists.txt b/systeminfo/CMakeLists.txt index d78e37f3..77339d79 100644 --- a/systeminfo/CMakeLists.txt +++ b/systeminfo/CMakeLists.txt @@ -36,5 +36,10 @@ if(CYGWIN) log("This is Cygwin") endif(CYGWIN) +if(BORLAND) + log("This is for a Borland compiler") +endif(BORLAND) + + message(STATUS "-----------------------------------") -- cgit v1.2.1