diff options
author | John Szakmeister <john@szakmeister.net> | 2014-05-14 21:14:28 -0400 |
---|---|---|
committer | John Szakmeister <john@szakmeister.net> | 2014-05-14 21:14:28 -0400 |
commit | 21bd9906036ae266eea7ee01f7827baca9702cb8 (patch) | |
tree | 4a92374ea3a6858246e1b30fda7311ecb5159fa6 | |
parent | 0d1094d709bf15206cf2c1fb39657c3801852141 (diff) | |
download | rneovim-21bd9906036ae266eea7ee01f7827baca9702cb8.tar.gz rneovim-21bd9906036ae266eea7ee01f7827baca9702cb8.tar.bz2 rneovim-21bd9906036ae266eea7ee01f7827baca9702cb8.zip |
Don't allow undefined references under Linux.
Many other systems expect this already, but on Linux the default is to
allow them. Let's turn that off.
-rw-r--r-- | CMakeLists.txt | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index a3d4c26280..4c242f11bc 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -33,6 +33,12 @@ else() set(DEBUG 0) endif() +if(CMAKE_COMPILER_IS_GNUCXX AND CMAKE_SYSTEM_NAME STREQUAL "Linux") + set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--no-undefined") + set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,--no-undefined") + set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,--no-undefined") +endif() + option(USE_GCOV "Enable gcov support" OFF) if(USE_GCOV) |