X-Git-Url: http://git.xonotic.org/?a=blobdiff_plain;f=Makefile;h=1c376fc89c7a819467d7246f7059203b125d017e;hb=24856f26219a65e51ad7c9599f7f31117b78b710;hp=a300b6af4e9d861f38d252f4611f4e1381d232f5;hpb=85fdf3de309bbed7071b88e9d6285c62a12850f6;p=xonotic%2Fnetradiant.git diff --git a/Makefile b/Makefile index a300b6af..1c376fc8 100644 --- a/Makefile +++ b/Makefile @@ -224,7 +224,8 @@ endif endif # VERSION! -RADIANT_VERSION = 1.5.0n +RADIANT_VERSION_NUMBER = 1.5.0 +RADIANT_VERSION = $(RADIANT_VERSION_NUMBER)n RADIANT_MAJOR_VERSION = 5 RADIANT_MINOR_VERSION = 0 Q3MAP_VERSION = 2.5.17n @@ -304,11 +305,20 @@ dependencies-check: { \ $(ECHO_NOLF) "Checking for $$2 ($$1)... "; \ if \ - $(CXX) conftest.cpp $(CFLAGS) $(CXXFLAGS) $(CFLAGS_COMMON) $(CXXFLAGS_COMMON) $(CPPFLAGS) $(CPPFLAGS_COMMON) $$4 -DCONFTEST_HEADER="<$$2>" -DCONFTEST_SYMBOL="$$3" $(TARGET_ARCH) $(LDFLAGS) -c -o conftest.o >&3 $(STDERR_TO_STDOUT) && \ - $(CXX) conftest.o $(LDFLAGS) $(LDFLAGS_COMMON) $$5 $(LIBS_COMMON) $(LIBS) -o conftest >&3 $(STDERR_TO_STDOUT); \ + $(CXX) conftest.cpp $(CFLAGS) $(CXXFLAGS) $(CFLAGS_COMMON) $(CXXFLAGS_COMMON) $(CPPFLAGS) $(CPPFLAGS_COMMON) $$4 -DCONFTEST_HEADER="<$$2>" -DCONFTEST_SYMBOL="$$3" $(TARGET_ARCH) $(LDFLAGS) -c -o conftest.o >&3 $(STDERR_TO_STDOUT); \ then \ - $(RM) conftest conftest.o conftest.d; \ - $(ECHO) "found."; \ + if \ + $(CXX) conftest.o $(LDFLAGS) $(LDFLAGS_COMMON) $$5 $(LIBS_COMMON) $(LIBS) -o conftest >&3 $(STDERR_TO_STDOUT); \ + then \ + $(RM) conftest conftest.o conftest.d; \ + $(ECHO) "found and links."; \ + else \ + $(RM) conftest.o conftest.d; \ + $(ECHO) "found but does not link, please install it or set PKG_CONFIG_PATH right!"; \ + $(ECHO) "To see the failed commands, set DEPENDENCIES_CHECK=verbose"; \ + $(ECHO) "To proceed anyway, set DEPENDENCIES_CHECK=off"; \ + failed=1; \ + fi; \ else \ $(RM) conftest conftest.o conftest.d; \ $(ECHO) "not found, please install it or set PKG_CONFIG_PATH right!"; \ @@ -333,7 +343,17 @@ endif .PHONY: binaries binaries: \ - $(INSTALLDIR)/heretic2/h2data.$(EXE) \ + binaries-tools \ + binaries-radiant-all \ + +.PHONY: binaries-radiant-all +binaries-radiant-all: \ + binaries-radiant-modules \ + binaries-radiant-plugins \ + binaries-radiant \ + +.PHONY: binaries-radiant-modules +binaries-radiant-modules: \ $(INSTALLDIR)/modules/archivepak.$(DLL) \ $(INSTALLDIR)/modules/archivewad.$(DLL) \ $(INSTALLDIR)/modules/archivezip.$(DLL) \ @@ -348,17 +368,56 @@ binaries: \ $(INSTALLDIR)/modules/model.$(DLL) \ $(INSTALLDIR)/modules/shaders.$(DLL) \ $(INSTALLDIR)/modules/vfspk3.$(DLL) \ + +.PHONY: binaries-radiant-plugins +binaries-radiant-plugins: \ $(INSTALLDIR)/plugins/bobtoolz.$(DLL) \ $(INSTALLDIR)/plugins/brushexport.$(DLL) \ $(INSTALLDIR)/plugins/prtview.$(DLL) \ $(INSTALLDIR)/plugins/shaderplug.$(DLL) \ $(INSTALLDIR)/plugins/sunplug.$(DLL) \ $(INSTALLDIR)/plugins/ufoaiplug.$(DLL) \ + +.PHONY: binaries-radiant +binaries-radiant: \ + $(INSTALLDIR)/radiant.$(EXE) \ + +.PHONY: binaries-tools +binaries-tools: \ + binaries-tools-quake2 \ + binaries-tools-quake3 \ + +.PHONY: binaries-tools-quake2 +binaries-tools-quake2: \ + binaries-q2map \ + binaries-qdata3 \ + binaries-heretic2 \ + +.PHONY: binaries-q2map +binaries-q2map: \ $(INSTALLDIR)/q2map.$(EXE) \ + +.PHONY: binaries-qdata3 +binaries-qdata3: \ + $(INSTALLDIR)/qdata3.$(EXE) \ + +.PHONY: binaries-heretic2 +binaries-heretic2: \ + $(INSTALLDIR)/heretic2/h2data.$(EXE) + +.PHONY: binaries-tools-quake3 +binaries-tools-quake3: \ + binaries-q3data \ + binaries-q3map2 \ + +.PHONY: binaries-q3data +binaries-q3data: \ $(INSTALLDIR)/q3data.$(EXE) \ + +.PHONY: binaries-q3map2 +binaries-q3map2: \ $(INSTALLDIR)/q3map2.$(EXE) \ - $(INSTALLDIR)/qdata3.$(EXE) \ - $(INSTALLDIR)/radiant.$(EXE) \ + .PHONY: clean clean: @@ -415,6 +474,7 @@ $(INSTALLDIR)/q3map2.$(EXE): \ tools/quake3/q3map2/bspfile_rbsp.o \ tools/quake3/q3map2/bsp.o \ tools/quake3/q3map2/convert_ase.o \ + tools/quake3/q3map2/convert_obj.o \ tools/quake3/q3map2/convert_map.o \ tools/quake3/q3map2/decals.o \ tools/quake3/q3map2/facebsp.o \ @@ -997,4 +1057,25 @@ install-dll: binaries endif endif +# release building... NOT for general users +# these may use tools not in the list that is checked by the build system +release-src: BUILD_DATE := $(shell date +%Y%m%d) +release-src: INSTALLDIR := netradiant-$(RADIANT_VERSION_NUMBER)-$(BUILD_DATE) +release-src: + $(GIT) archive --format=tar --prefix=$(INSTALLDIR)/ HEAD | bzip2 > ../$(INSTALLDIR).tar.bz2 + +release-win32: BUILD_DATE := $(shell date +%Y%m%d) +release-win32: INSTALLDIR := netradiant-$(RADIANT_VERSION_NUMBER)-$(BUILD_DATE) +release-win32: + $(MAKE) all INSTALLDIR=$(INSTALLDIR) MAKEFILE_CONF=cross-Makefile.conf RADIANT_ABOUTMSG="Official release build" BUILD=release + 7za a -sfx../../../../../../../../../../$(HOME)/7z.sfx ../$(INSTALLDIR)-win32-7z.exe $(INSTALLDIR)/ + chmod 644 ../$(INSTALLDIR)-win32-7z.exe # 7zip is evil + $(MAKE) clean INSTALLDIR=$(INSTALLDIR) MAKEFILE_CONF=cross-Makefile.conf RADIANT_ABOUTMSG="Official release build" BUILD=release + +release-all: + $(GIT) clean -xdf + $(MAKE) release-src + $(MAKE) release-win32 + +# load dependency files -include $(shell find . -name \*.d)