Simplify the automake processed makefiles in data/

* Getting rid of the custom crafted installation rules
 * Replace them with a single automake primary build rule: nodist_<instdir>_DATA

This closes ticket:62

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5995 4a71c877-e1ca-e34f-864e-861f7616d084
master
Giel van Schijndel 2008-09-12 08:19:57 +00:00
parent 77f3599ada
commit 5daf3d8035
5 changed files with 8 additions and 60 deletions

View File

@ -19,25 +19,7 @@ PATCHARCHIVE = mp.wz
CLEANFILES = $(BASEARCHIVE) $(PATCHARCHIVE)
data: $(BASEARCHIVE) $(PATCHARCHIVE)
$(MAKE) $(AM_MAKEFLAGS) -C mods data
$(BASEARCHIVE): $(BASELIST:%=$(basename $(BASEARCHIVE))/%)
$(PATCHARCHIVE): $(PATCHLIST:%=$(basename $(PATCHARCHIVE))/%)
install-data-local: $(BASEARCHIVE) $(PATCHARCHIVE)
$(MKDIR_P) $(DESTDIR)$(pkgdatadir)
$(INSTALL_DATA) $(BASEARCHIVE) $(DESTDIR)$(pkgdatadir)/$(BASEARCHIVE)
$(INSTALL_DATA) $(PATCHARCHIVE) $(DESTDIR)$(pkgdatadir)/$(PATCHARCHIVE)
uninstall-local:
rm -f $(DESTDIR)$(pkgdatadir)/$(BASEARCHIVE)
rm -f $(DESTDIR)$(pkgdatadir)/$(PATCHARCHIVE)
installcheck:
[ -f $(BASEARCHIVE) ] && zip -T $(BASEARCHIVE)
[ -f $(PATCHARCHIVE) ] && zip -T $(PATCHARCHIVE)
dist-hook: $(BASEARCHIVE) $(PATCHARCHIVE)
cp -fu $(BASEARCHIVE) $(DESTDIR)$(distdir)
cp -fu $(PATCHARCHIVE) $(DESTDIR)$(distdir)
nodist_pkgdata_DATA = $(BASEARCHIVE) $(PATCHARCHIVE)

View File

@ -1,5 +1 @@
SUBDIRS = global multiplay
data:
$(MAKE) $(AM_MAKEFLAGS) -C global data
$(MAKE) $(AM_MAKEFLAGS) -C multiplay data

View File

@ -16,29 +16,9 @@ NEWST_TILESARCHIVE = newst_tiles.wz
CLEANFILES = $(AIVOLUTIONARCHIVE) $(GRIMARCHIVE) $(NEWST_TILESARCHIVE)
data: $(AIVOLUTIONARCHIVE) $(GRIMARCHIVE) $(NEWST_TILESARCHIVE)
$(AIVOLUTIONARCHIVE): $(AIVOLUTIONLIST:%=$(basename $(AIVOLUTIONARCHIVE))/%)
$(GRIMARCHIVE): $(GRIMLIST:%=$(basename $(GRIMARCHIVE))/%)
$(NEWST_TILESARCHIVE): $(NEWST_TILESLIST:%=$(basename $(NEWST_TILESARCHIVE))/%)
install-data-local: $(AIVOLUTIONARCHIVE) $(GRIMARCHIVE) $(NEWST_TILESARCHIVE)
$(MKDIR_P) $(DESTDIR)$(pkgdatadir)/mods/global
$(INSTALL_DATA) $(AIVOLUTIONARCHIVE) $(DESTDIR)$(pkgdatadir)/mods/global/$(AIVOLUTIONARCHIVE)
$(INSTALL_DATA) $(GRIMARCHIVE) $(DESTDIR)$(pkgdatadir)/mods/global/$(GRIMARCHIVE)
$(INSTALL_DATA) $(NEWST_TILESARCHIVE) $(DESTDIR)$(pkgdatadir)/mods/global/$(NEWST_TILESARCHIVE)
uninstall-local:
rm -f $(DESTDIR)$(pkgdatadir)/mods/global/$(AIVOLUTIONARCHIVE)
rm -f $(DESTDIR)$(pkgdatadir)/mods/global/$(GRIMARCHIVE)
rm -f $(DESTDIR)$(pkgdatadir)/mods/global/$(NEWST_TILESARCHIVE)
installcheck:
[ -f $(AIVOLUTIONARCHIVE) ] && zip -T $(AIVOLUTIONARCHIVE)
[ -f $(GRIMARCHIVE) ] && zip -T $(GRIMARCHIVE)
[ -f $(NEWST_TILESARCHIVE) ] && zip -T $(NEWST_TILESARCHIVE)
dist-hook: $(AIVOLUTIONARCHIVE) $(GRIMARCHIVE) $(NEWST_TILESARCHIVE)
cp -fu $(AIVOLUTIONARCHIVE) $(DESTDIR)$(distdir)
cp -fu $(GRIMARCHIVE) $(DESTDIR)$(distdir)
cp -fu $(NEWST_TILESARCHIVE) $(DESTDIR)$(distdir)
globalmodsdir = $(pkgdatadir)/mods/global
nodist_globalmods_DATA = $(AIVOLUTIONARCHIVE) $(GRIMARCHIVE) $(NEWST_TILESARCHIVE)

View File

@ -12,19 +12,7 @@ NTWARCHIVE = ntw.wz
CLEANFILES = $(NTWARCHIVE)
data: $(NTWARCHIVE)
$(NTWARCHIVE): $(NTWLIST:%=$(basename $(NTWARCHIVE))/%)
install-data-local: $(NTWARCHIVE)
$(MKDIR_P) $(DESTDIR)$(pkgdatadir)/mods/global
$(INSTALL_DATA) $(NTWARCHIVE) $(DESTDIR)$(pkgdatadir)/mods/global/$(NTWARCHIVE)
uninstall-local:
rm -f $(DESTDIR)$(pkgdatadir)/mods/global/$(NTWARCHIVE)
installcheck:
[ -f $(NTWARCHIVE) ] && zip -T $(NTWARCHIVE)
dist-hook: $(AIVOLUTIONARCHIVE) $(GRIMARCHIVE) $(NEWST_TILESARCHIVE)
cp -fu $(NTWARCHIVE) $(DESTDIR)$(distdir)
multiplaymodsdir = $(pkgdata)/mods/multiplay
nodist_multiplaymods_DATA = $(NTWARCHIVE)

View File

@ -8,10 +8,12 @@ all: $(INSTALLERFILE)
endif
data:
$(MAKE) $(AM_MAKEFLAGS) -C ../../data/ data
$(MAKE) $(AM_MAKEFLAGS) -C ../../data/ all
$(INSTALLERFILE): warzone2100.nsi ../../src/warzone2100.exe data
$(MAKENSIS) -DPACKAGE="$(PACKAGE)" -DPACKAGE_NAME="$(PACKAGE_NAME)" -DPACKAGE_VERSION="$(PACKAGE_VERSION)" -DPACKAGE_BUGREPORT="$(PACKAGE_BUGREPORT)" -DVERSIONNUM="$(INSTALLER_VERSION)" -DEXTDIR="$(INSTALLER_EXTDIR)" -X"SetCompressor /FINAL /SOLID ${INSTALLER_COMPRESSION}" $<
$(UPDATERFILE): warzone2100.update.nsi
$(MAKENSIS) -DVERSION="$(VERSION)" -DVERSIONNUM="$(INSTALLER_VERSION)" -DEXTDIR="$(INSTALLER_EXTDIR)" -X"SetCompressor /FINAL /SOLID ${INSTALLER_COMPRESSION}" $<
.PHONY: all data