aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames McCoy <jamessan@jamessan.com>2018-12-01 19:39:23 -0500
committerGitHub <noreply@github.com>2018-12-01 19:39:23 -0500
commit109a792e25c6120afc554c74bd539ee19ad21a85 (patch)
treed658200c1b019a48de6b816554f442fab734c23c
parent799d9c32157c841c3b8d355fa98a5ace435eef07 (diff)
parentb14b2883e9e395c4850d8fae17936b43b04fa46c (diff)
downloadrneovim-109a792e25c6120afc554c74bd539ee19ad21a85.tar.gz
rneovim-109a792e25c6120afc554c74bd539ee19ad21a85.tar.bz2
rneovim-109a792e25c6120afc554c74bd539ee19ad21a85.zip
Merge pull request #9303 from jamessan/cmp-0075
Unset CMAKE_REQUIRED_* after they're done being used
-rw-r--r--CMakeLists.txt8
1 files changed, 7 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 26a6529fcd..15718c94cf 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -6,7 +6,10 @@ cmake_minimum_required(VERSION 2.8.12)
project(nvim C)
if(POLICY CMP0059)
- cmake_policy(SET CMP0059 OLD) # Needed until cmake 2.8.12. #4389
+ # Needed for use of DEFINITIONS variable, which is used to collect the
+ # compilation flags for reporting in "nvim --version"
+ # https://github.com/neovim/neovim/pull/8558#issuecomment-398033140
+ cmake_policy(SET CMP0059 OLD)
endif()
# Point CMake at any custom modules we may ship
@@ -389,6 +392,7 @@ main(void)
return MSGPACK_OBJECT_FLOAT32;
}
" MSGPACK_HAS_FLOAT32)
+unset(CMAKE_REQUIRED_LIBRARIES)
if(MSGPACK_HAS_FLOAT32)
add_definitions(-DNVIM_MSGPACK_HAS_FLOAT32)
endif()
@@ -410,6 +414,8 @@ if(FEAT_TUI)
return unibi_num_from_var(unibi_var_from_num(0));
}
" UNIBI_HAS_VAR_FROM)
+ unset(CMAKE_REQUIRED_INCLUDES)
+ unset(CMAKE_REQUIRED_LIBRARIES)
if(UNIBI_HAS_VAR_FROM)
add_definitions(-DNVIM_UNIBI_HAS_VAR_FROM)
endif()