MAKE: use BUILDDIR variable

master
Martin Gerhardy 2021-11-06 20:43:21 +01:00
parent 3ce7b84e66
commit 6eed6015d2
1 changed files with 2 additions and 2 deletions

View File

@ -14,7 +14,7 @@ CMAKE_OPTIONS ?= -DCMAKE_BUILD_TYPE=$(BUILDTYPE) -G$(GENERATOR) --graphviz=$(BU
all:
$(Q)if [ ! -f $(BUILDDIR)/CMakeCache.txt ]; then $(CMAKE) -H$(CURDIR) -B$(BUILDDIR) $(CMAKE_OPTIONS); fi
$(Q)$(CMAKE) --build $(BUILDDIR) --target $@
$(Q)$(CMAKE) -E create_symlink build/Debug/compile_commands.json compile_commands.json
$(Q)$(CMAKE) -E create_symlink $(BUILDDIR)/compile_commands.json compile_commands.json
release:
$(Q)$(MAKE) BUILDTYPE=Release
@ -45,7 +45,7 @@ release-%:
$(Q)if [ ! -f $(BUILDDIR)/CMakeCache.txt ]; then $(CMAKE) -H$(CURDIR) -B$(BUILDDIR) $(CMAKE_OPTIONS); fi
$(Q)$(CMAKE) --build $(BUILDDIR) --target $@
$(Q)$(CMAKE) --install $(BUILDDIR) --component $@ --prefix $(INSTALL_DIR)/install-$@
$(Q)$(CMAKE) -E create_symlink build/Debug/compile_commands.json compile_commands.json
$(Q)$(CMAKE) -E create_symlink $(BUILDDIR)/compile_commands.json compile_commands.json
dependency-%:
$(Q)$(CMAKE) -H$(CURDIR) -B$(BUILDDIR) $(CMAKE_OPTIONS)