-clean: clean-$(SUFFIX)
-
-.PHONY: clean-git
-clean-git:
- ./all clean
-
-.PHONY: clean-zip
-clean-zip-binary:
- @echo Nothing to do
-
-.PHONY: clean-zip
-clean-zip-source:
- $(MAKE) -C source/d0_blind_id distclean
- $(MAKE) -C source/gmqcc clean
- $(MAKE) -C source/qcsrc clean
- $(MAKE) -C source/darkplaces clean
-
-
-.PHONY: install-data
-install-data: install-data-$(SUFFIX)
-
-.PHONY: install-data-git
-install-data-git: all-git
- $(RM) -rf $(DESTDIR)$(LIBDIR)/data
- $(INSTALL) -d $(DESTDIR)$(LIBDIR)/data
- for p in data/*.pk3; do $(INSTALL) $$p $(DESTDIR)$(LIBDIR)/$$p || exit 1; done
- for p in data/*.pk3dir; do ( cd $$p && $(ZIP) -r $(DESTDIR)$(LIBDIR)/$${p%dir} * ) || exit 1; done
-
-.PHONY: install-data-zip-binary
-install-data-zip-binary: all-zip-binary
- $(RM) -rf $(DESTDIR)$(LIBDIR)/data
- $(INSTALL) -d $(DESTDIR)$(LIBDIR)/data
- for p in data/*.pk3; do $(INSTALL) $$p $(DESTDIR)$(LIBDIR)/$$p || exit 1; done
-
-.PHONY: install-data-zip-source
-install-data-zip-source: all-zip-source
- $(RM) -rf $(DESTDIR)$(LIBDIR)/data
- $(INSTALL) -d $(DESTDIR)$(LIBDIR)/data
- for p in data/*.pk3; do $(INSTALL) $$p $(DESTDIR)$(LIBDIR)/$$p || exit 1; done
- for p in data/xonotic-*-data*.pk3; do cd source && $(ZIP) $(DESTDIR)$(LIBDIR)/$$p progs.dat menu.dat csprogs.dat; done
-
-
-.PHONY: install-engine
-install-engine: install-engine-$(SUFFIX)
-
-.PHONY: install-engine-git
-install-engine-git: all-git
- $(INSTALL) -d $(DESTDIR)$(LIBDIR)
- $(INSTALL) xonotic-linux-glx.sh $(DESTDIR)$(LIBDIR)/xonotic-linux-glx.sh
- $(INSTALL) xonotic-linux-sdl.sh $(DESTDIR)$(LIBDIR)/xonotic-linux-sdl.sh
- $(INSTALL) xonotic-linux-dedicated.sh $(DESTDIR)$(LIBDIR)/xonotic-linux-dedicated.sh
- $(INSTALL) darkplaces/darkplaces-sdl $(DESTDIR)$(LIBDIR)/xonotic-$(ARCH)-sdl
- $(INSTALL) darkplaces/darkplaces-glx $(DESTDIR)$(LIBDIR)/xonotic-$(ARCH)-glx
- $(INSTALL) darkplaces/darkplaces-dedicated $(DESTDIR)$(LIBDIR)/xonotic-$(ARCH)-dedicated
-
-.PHONY: install-engine-zip-binary
-install-engine-zip-binary: all-zip-binary
- $(INSTALL) -d $(DESTDIR)$(LIBDIR)
- $(INSTALL) xonotic-linux-glx.sh $(DESTDIR)$(LIBDIR)/xonotic-linux-glx.sh
- $(INSTALL) xonotic-linux-sdl.sh $(DESTDIR)$(LIBDIR)/xonotic-linux-sdl.sh
- $(INSTALL) xonotic-linux-dedicated.sh $(DESTDIR)$(LIBDIR)/xonotic-linux-dedicated.sh
- $(INSTALL) xonotic-$(ARCH)-sdl $(DESTDIR)$(LIBDIR)/xonotic-$(ARCH)-sdl
- $(INSTALL) xonotic-$(ARCH)-glx $(DESTDIR)$(LIBDIR)/xonotic-$(ARCH)-glx
- $(INSTALL) xonotic-$(ARCH)-dedicated $(DESTDIR)$(LIBDIR)/xonotic-$(ARCH)-dedicated
-
-.PHONY: install-engine-zip-source
-install-engine-zip-source: all-zip-source
- $(INSTALL) -d $(DESTDIR)$(LIBDIR)
- $(INSTALL) xonotic-linux-glx.sh $(DESTDIR)$(LIBDIR)/xonotic-linux-glx.sh
- $(INSTALL) xonotic-linux-sdl.sh $(DESTDIR)$(LIBDIR)/xonotic-linux-sdl.sh
- $(INSTALL) xonotic-linux-dedicated.sh $(DESTDIR)$(LIBDIR)/xonotic-linux-dedicated.sh
- $(INSTALL) source/darkplaces/darkplaces-sdl $(DESTDIR)$(LIBDIR)/xonotic-$(ARCH)-sdl
- $(INSTALL) source/darkplaces/darkplaces-glx $(DESTDIR)$(LIBDIR)/xonotic-$(ARCH)-glx
- $(INSTALL) source/darkplaces/darkplaces-dedicated $(DESTDIR)$(LIBDIR)/xonotic-$(ARCH)-dedicated
-
-
-.PHONY: install-links
-install-links:
- $(INSTALL) -d $(BINDIR)
- $(LN) -snf $(LIBDIR)/xonotic-linux-sdl.sh $(DESTDIR)$(BINDIR)/xonotic-sdl
- $(LN) -snf $(LIBDIR)/xonotic-linux-glx.sh $(DESTDIR)$(BINDIR)/xonotic-glx
- $(LN) -snf $(LIBDIR)/xonotic-linux-dedicated.sh $(DESTDIR)$(BINDIR)/xonotic-dedicated
-
-
-.PHONY: install-doc
-install-doc:
- $(INSTALL) -d $(DESTDIR)$(DOCDIR)/server
- $(CP) -R Docs/* $(DESTDIR)$(DOCDIR)/
- $(CP) -R server/* $(DESTDIR)$(DOCDIR)/server
-
-
-.PHONY: install
-install: install-data install-engine install-links install-doc
+clean: clean-sources
+ $(RM) $(CLIENT) $(SERVER)
+
+.PHONY: update-stable
+update-stable:
+ misc/tools/rsync-updater/update-to-release.sh
+
+.PHONY: update-beta
+update-beta:
+ misc/tools/rsync-updater/update-to-autobuild.sh
+
+
+$(D0SRC)/.libs/libd0_blind_id.a $(D0SRC)/.libs/libd0_rijndael.a:
+ ( cd $(D0SRC) && ./autogen.sh && ./configure --enable-static --disable-shared )
+ $(MAKE) -C $(D0SRC) clean # ensures missing .a files are created FIXME WORKAROUND
+ $(MAKE) -C $(D0SRC)
+
+$(DPSRC)/darkplaces-dedicated: $(D0SRC)/.libs/libd0_blind_id.a
+ $(MAKE) -C $(DPSRC) sv-release
+$(SERVER): $(DPSRC)/darkplaces-dedicated
+ cp $(DPSRC)/darkplaces-dedicated $(SERVER)
+
+$(DPSRC)/darkplaces-sdl: $(D0SRC)/.libs/libd0_blind_id.a
+ $(MAKE) -C $(DPSRC) sdl-release
+$(CLIENT): $(DPSRC)/darkplaces-sdl
+ cp $(DPSRC)/darkplaces-sdl $(CLIENT)
+
+
+.PHONY: server
+server: $(SERVER)
+
+.PHONY: client
+client: $(CLIENT)
+
+.PHONY: both
+both: client server
+