aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorJohn Levon <john.levon@nutanix.com>2020-12-11 10:39:14 +0000
committerGitHub <noreply@github.com>2020-12-11 10:39:14 +0000
commit0e3d7e722dce6e9a8eb3560831164c2234cadaf3 (patch)
tree31cb471ecac67367e35a8b776de1c297448872bd /Makefile
parent13e7ba93d0dd6549a5042099c15ce00fe25f0bd7 (diff)
downloadlibvfio-user-0e3d7e722dce6e9a8eb3560831164c2234cadaf3.zip
libvfio-user-0e3d7e722dce6e9a8eb3560831164c2234cadaf3.tar.gz
libvfio-user-0e3d7e722dce6e9a8eb3560831164c2234cadaf3.tar.bz2
allow over-riding "cmake" (#184)
Signed-off-by: John Levon <john.levon@nutanix.com> Reviewed-by: Swapnil Ingle <swapnil.ingle@nutanix.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile4
1 files changed, 3 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 4375c57..a140ccd 100644
--- a/Makefile
+++ b/Makefile
@@ -41,6 +41,8 @@ ifeq ($(VERBOSE),)
MAKEFLAGS += -s
endif
+CMAKE = cmake
+
BUILD_DIR_BASE = $(CURDIR)/build
BUILD_DIR = $(BUILD_DIR_BASE)/$(BUILD_TYPE)
@@ -69,7 +71,7 @@ force_cmake: $(BUILD_DIR)/Makefile
$(BUILD_DIR)/Makefile:
mkdir -p $(BUILD_DIR)
- cd $(BUILD_DIR); cmake \
+ cd $(BUILD_DIR); $(CMAKE) \
-D "CMAKE_C_FLAGS:STRING=$(CFLAGS)" \
-D "CMAKE_BUILD_TYPE:STRING=$(CMAKE_BUILD_TYPE)" \
-D "CMAKE_INSTALL_PREFIX=$(INSTALL_PREFIX)" \