mirror of
https://github.com/yquake2/yquake2remaster.git
synced 2024-11-25 22:10:59 +00:00
Optional configuration file
Ability to read an optional configuration file which is read if exists, we can even decide which configuration file (default is config.mk) to use at the command line like this: $ make # it will read config.mk if exists $ make CONFIG_FILE=my-badass-conf.mk $ make CONFIG_FILE=no-retexturing.mk As always, build variables still can be set as well by command line. $ make WITH_SYSTEMWIDE=/media/cdrom/quake2-data CONFIG_FILE=my-badass-conf.mk
This commit is contained in:
parent
5ce3a266e9
commit
192f4c986d
2 changed files with 13 additions and 4 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -1,2 +1,3 @@
|
||||||
/build/
|
/build/
|
||||||
/release/
|
/release/
|
||||||
|
*.mk
|
||||||
|
|
16
Makefile
16
Makefile
|
@ -25,6 +25,10 @@
|
||||||
# - Windows (MinGW) #
|
# - Windows (MinGW) #
|
||||||
# ------------------------------------------------------ #
|
# ------------------------------------------------------ #
|
||||||
|
|
||||||
|
# ====================================================== #
|
||||||
|
# !!! DO NOT ALTER ANYTHING BELOW THIS LINE !!! #
|
||||||
|
# ====================================================== #
|
||||||
|
|
||||||
# User configurable options
|
# User configurable options
|
||||||
# -------------------------
|
# -------------------------
|
||||||
|
|
||||||
|
@ -87,9 +91,14 @@ OSX_ARCH:=-arch i386 -arch x86_64
|
||||||
# Contents/Resources
|
# Contents/Resources
|
||||||
OSX_APP:=yes
|
OSX_APP:=yes
|
||||||
|
|
||||||
# ====================================================== #
|
# This is an optional configuration file, it'll be used in
|
||||||
# !!! DO NOT ALTER ANYTHING BELOW THIS LINE !!! #
|
# case of presence.
|
||||||
# ====================================================== #
|
CONFIG_FILE := config.mk
|
||||||
|
|
||||||
|
# In case a of a configuration file being present, we'll just use it
|
||||||
|
ifeq ($(wildcard $(CONFIG_FILE)), $(CONFIG_FILE))
|
||||||
|
include $(CONFIG_FILE)
|
||||||
|
endif
|
||||||
|
|
||||||
# Detect the OS
|
# Detect the OS
|
||||||
ifdef SystemRoot
|
ifdef SystemRoot
|
||||||
|
@ -292,7 +301,6 @@ endif
|
||||||
# ----------
|
# ----------
|
||||||
|
|
||||||
# Phony targets
|
# Phony targets
|
||||||
#.PHONY : all client game icon refresher server
|
|
||||||
.PHONY : all client game icon server
|
.PHONY : all client game icon server
|
||||||
|
|
||||||
# ----------
|
# ----------
|
||||||
|
|
Loading…
Reference in a new issue