diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2016-01-24 21:16:00 -0500 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2016-01-24 21:18:44 -0500 |
commit | b5f6f43095fc556cfc4b909bd810059f94967a68 (patch) | |
tree | 76e5f418be19b66ee88ade570b5f9f1b4dca3783 | |
parent | e1d81178ccf374e7142207356a022bdf10571918 (diff) | |
download | rneovim-b5f6f43095fc556cfc4b909bd810059f94967a68.tar.gz rneovim-b5f6f43095fc556cfc4b909bd810059f94967a68.tar.bz2 rneovim-b5f6f43095fc556cfc4b909bd810059f94967a68.zip |
cmake: Linux: define _GNU_SOURCE.
Closes #4042
-rw-r--r-- | CMakeLists.txt | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 6c3f4d927d..ed87dc30a2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -254,6 +254,10 @@ 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") + + # For O_CLOEXEC, O_DIRECTORY, and O_NOFOLLOW flags on older systems + # (pre POSIX.1-2008: glibc 2.11 and earlier). #4042 + add_definitions(-D_GNU_SOURCE) endif() if(CMAKE_COMPILER_IS_GNUCXX AND CMAKE_SYSTEM_NAME STREQUAL "SunOS") |