Commit 42572575 authored by Antoine Lemasson's avatar Antoine Lemasson Committed by Jérémie Dudouet
Browse files

Add the detection of the OS_Type in Gw

parent c6ba9341
......@@ -57,6 +57,21 @@ link_directories(${CMAKE_LIBRARY_OUTPUT_DIRECTORY})
#
# configure file
#
#TEST current configuration OS
if ( UNIX )
set(CMAKE_OS_TYPE 1)
endif()
if ( WIN32 )
set(CMAKE_OS_TYPE 2)
endif()
if ( CYGWIN )
set(CMAKE_OS_TYPE 3)
endif()
if ( APPLE )
set(CMAKE_OS_TYPE 4)
endif()
configure_file (
"${CMAKE_CURRENT_SOURCE_DIR}/GwConfig.h.cmake"
"${CMAKE_BINARY_DIR}/include/GwConfig.h"
......
......@@ -43,3 +43,14 @@
#define GW_MacrosPath "@GW_DATA_DIR@/macros";
#endif
//////////////////////////////
////// Define OS_TYPE ////////
//////////////////////////////
#define OS_LINUX 1
#define OS_WINDOWS 2
#define OS_CYGWIN 3 // rather useless ==> to be removed ??
#define OS_APPLE 4
#define OS_TYPE @CMAKE_OS_TYPE@
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment