Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
IPNL_GAMMA
gammaware
Commits
2112d8ba
Commit
2112d8ba
authored
Apr 14, 2019
by
Antoine Lemasson
Browse files
Add the detection of the OS_Type in Gw
parent
e65bfbb3
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
0 deletions
+26
-0
src/root/core/CMakeLists.txt
src/root/core/CMakeLists.txt
+15
-0
src/root/core/GwConfig.h.cmake
src/root/core/GwConfig.h.cmake
+11
-0
No files found.
src/root/core/CMakeLists.txt
View file @
2112d8ba
...
...
@@ -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"
...
...
src/root/core/GwConfig.h.cmake
View file @
2112d8ba
...
...
@@ -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@
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment