aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Makefile
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2023-06-30 02:37:27 +0200
committerEgor Tensin <Egor.Tensin@gmail.com>2023-06-30 03:32:14 +0200
commite928ce51bd8c26742abfd537b054483a18a9689c (patch)
treead3bfcf7b509dbde4681c011237c8bd23ee8583f /Makefile
parentfix function names in error messages (diff)
downloadcimple-e928ce51bd8c26742abfd537b054483a18a9689c.tar.gz
cimple-e928ce51bd8c26742abfd537b054483a18a9689c.zip
show git hash with --version
Also, use cmake's configure_file to build string constants in.
Diffstat (limited to '')
-rw-r--r--Makefile3
1 files changed, 3 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 91806f0..769db70 100644
--- a/Makefile
+++ b/Makefile
@@ -28,11 +28,13 @@ install_dir := $(build_dir)/install
COMPILER ?= clang
CONFIGURATION ?= Debug
DEFAULT_HOST ?= 127.0.0.1
+DEFAULT_PORT ?= 5556
INSTALL_PREFIX ?= $(install_dir)
$(eval $(call noexpand,COMPILER))
$(eval $(call noexpand,CONFIGURATION))
$(eval $(call noexpand,DEFAULT_HOST))
+$(eval $(call noexpand,DEFAULT_PORT))
$(eval $(call noexpand,INSTALL_PREFIX))
.PHONY: all
@@ -51,6 +53,7 @@ build:
-D 'CMAKE_BUILD_TYPE=$(call escape,$(CONFIGURATION))' \
-D 'CMAKE_INSTALL_PREFIX=$(call escape,$(INSTALL_PREFIX))' \
-D 'DEFAULT_HOST=$(call escape,$(DEFAULT_HOST))' \
+ -D 'DEFAULT_PORT=$(call escape,$(DEFAULT_PORT))' \
-S '$(call escape,$(src_dir))' \
-B '$(call escape,$(cmake_dir))'
cmake --build '$(call escape,$(cmake_dir))' -- -j