aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorludwig <ludwig@edf5b092-35ff-0310-97b2-ce42778d08ea>2008-05-06 20:24:32 +0000
committerludwig <ludwig@edf5b092-35ff-0310-97b2-ce42778d08ea>2008-05-06 20:24:32 +0000
commit212a4ed7d0837952cfd56ca00ec3f71cf531952f (patch)
tree6699753bd9322f9768afd0c0ab74abdb100b216d /Makefile
parente728e351889cc329d86b88b0c9ec88318324c27e (diff)
downloadioquake3-aero-212a4ed7d0837952cfd56ca00ec3f71cf531952f.tar.gz
ioquake3-aero-212a4ed7d0837952cfd56ca00ec3f71cf531952f.zip
define the product version in the Makefile
git-svn-id: svn://svn.icculus.org/quake3/trunk@1340 edf5b092-35ff-0310-97b2-ce42778d08ea
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile29
1 files changed, 9 insertions, 20 deletions
diff --git a/Makefile b/Makefile
index 3492de5..7a8d932 100644
--- a/Makefile
+++ b/Makefile
@@ -168,27 +168,17 @@ OPENAL_LIBS=$(shell pkg-config --libs openal)
SDL_CFLAGS=$(shell pkg-config --cflags sdl|sed 's/-Dmain=SDL_main//')
SDL_LIBS=$(shell pkg-config --libs sdl)
-# extract version info
-
-ifeq ($(BUILD_STANDALONE),1)
- VERSION=$(shell grep "\#define *PRODUCT_VERSION" $(CMDIR)/q_shared.h | head -n 1 | \
- sed -e 's/[^"]*"\(.*\)"/\1/')
-else
- VERSION=$(shell grep "\#define *PRODUCT_VERSION" $(CMDIR)/q_shared.h | tail -n 1 | \
- sed -e 's/[^"]*"\(.*\)"/\1/')
-endif
+# version info
+VERSION=1.35
USE_SVN=
ifeq ($(wildcard .svn),.svn)
SVN_REV=$(shell LANG=C svnversion .)
ifneq ($(SVN_REV),)
- SVN_VERSION=$(VERSION)_SVN$(SVN_REV)
+ VERSION:=$(VERSION)_SVN$(SVN_REV)
USE_SVN=1
endif
endif
-ifneq ($(USE_SVN),1)
- SVN_VERSION=$(VERSION)
-endif
#############################################################################
@@ -801,9 +791,7 @@ else
DEPEND_CFLAGS =
endif
-ifeq ($(USE_SVN),1)
- BASE_CFLAGS += -DSVN_VERSION=\\\"$(SVN_VERSION)\\\"
-endif
+BASE_CFLAGS += -DPRODUCT_VERSION=\\\"$(VERSION)\\\"
ifeq ($(V),1)
echo_cmd=@:
@@ -918,6 +906,7 @@ targets: makedirs
@echo "Building ioquake3 in $(B):"
@echo " PLATFORM: $(PLATFORM)"
@echo " ARCH: $(ARCH)"
+ @echo " VERSION: $(VERSION)"
@echo " COMPILE_PLATFORM: $(COMPILE_PLATFORM)"
@echo " COMPILE_ARCH: $(COMPILE_ARCH)"
@echo " CC: $(CC)"
@@ -2011,10 +2000,10 @@ else
endif
dist:
- rm -rf ioquake3-$(SVN_VERSION)
- svn export . ioquake3-$(SVN_VERSION)
- tar --owner=root --group=root --force-local -cjf ioquake3-$(SVN_VERSION).tar.bz2 ioquake3-$(SVN_VERSION)
- rm -rf ioquake3-$(SVN_VERSION)
+ rm -rf ioquake3-$(VERSION)
+ svn export . ioquake3-$(VERSION)
+ tar --owner=root --group=root --force-local -cjf ioquake3-$(VERSION).tar.bz2 ioquake3-$(VERSION)
+ rm -rf ioquake3-$(VERSION)
#############################################################################
# DEPENDENCIES