mirror of
https://github.com/neovim/neovim.git
synced 2024-12-23 20:55:18 -07:00
Makefile: CMAKE_INSTALL_PREFIX: skip parsing CMAKE_EXTRA_FLAGS if set (#10374)
Fixes: > Recursive variable 'CMAKE_EXTRA_FLAGS' references itself (eventually). Stop.
This commit is contained in:
parent
0364f517bb
commit
72ae0a6e5e
6
Makefile
6
Makefile
@ -16,12 +16,12 @@ CMAKE_EXTRA_FLAGS ?=
|
|||||||
# CMAKE_INSTALL_PREFIX
|
# CMAKE_INSTALL_PREFIX
|
||||||
# - May be passed directly or as part of CMAKE_EXTRA_FLAGS.
|
# - May be passed directly or as part of CMAKE_EXTRA_FLAGS.
|
||||||
# - `checkprefix` target checks that it matches the CMake-cached value. #9615
|
# - `checkprefix` target checks that it matches the CMake-cached value. #9615
|
||||||
ifneq (,$(CMAKE_EXTRA_FLAGS))
|
ifneq (,$(CMAKE_INSTALL_PREFIX)$(CMAKE_EXTRA_FLAGS))
|
||||||
CMAKE_INSTALL_PREFIX ?= $(shell echo $(CMAKE_EXTRA_FLAGS) | 2>/dev/null \
|
CMAKE_INSTALL_PREFIX := $(shell echo $(CMAKE_EXTRA_FLAGS) | 2>/dev/null \
|
||||||
grep -o 'CMAKE_INSTALL_PREFIX=[^ ]\+' | cut -d '=' -f2)
|
grep -o 'CMAKE_INSTALL_PREFIX=[^ ]\+' | cut -d '=' -f2)
|
||||||
endif
|
endif
|
||||||
ifneq (,$(CMAKE_INSTALL_PREFIX))
|
ifneq (,$(CMAKE_INSTALL_PREFIX))
|
||||||
CMAKE_EXTRA_FLAGS += -DCMAKE_INSTALL_PREFIX=$(CMAKE_INSTALL_PREFIX)
|
CMAKE_EXTRA_FLAGS += -DCMAKE_INSTALL_PREFIX=$(CMAKE_INSTALL_PREFIX)
|
||||||
|
|
||||||
checkprefix:
|
checkprefix:
|
||||||
@if [ -f build/.ran-cmake ]; then \
|
@if [ -f build/.ran-cmake ]; then \
|
||||||
|
Loading…
Reference in New Issue
Block a user