summaryrefslogtreecommitdiff
path: root/pkg/win32
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/win32')
-rw-r--r--pkg/win32/GNUmakefile55
1 files changed, 36 insertions, 19 deletions
diff --git a/pkg/win32/GNUmakefile b/pkg/win32/GNUmakefile
index 6b45152e..690da608 100644
--- a/pkg/win32/GNUmakefile
+++ b/pkg/win32/GNUmakefile
@@ -3,11 +3,11 @@ include ../config.make
TOPLEVEL=../..
-EXE_FILES=$(TOPLEVEL)/src/$(PROGRAM_PREFIX)doom.exe \
- $(TOPLEVEL)/src/$(PROGRAM_PREFIX)heretic.exe \
- $(TOPLEVEL)/src/$(PROGRAM_PREFIX)hexen.exe \
- $(TOPLEVEL)/src/$(PROGRAM_PREFIX)server.exe \
- $(TOPLEVEL)/src/$(PROGRAM_PREFIX)setup.exe
+DOOM_ZIP=$(PROGRAM_PREFIX)doom-$(PACKAGE_VERSION)-win32.zip
+HERETIC_ZIP=$(PROGRAM_PREFIX)heretic-$(PACKAGE_VERSION)-win32.zip
+HEXEN_ZIP=$(PROGRAM_PREFIX)hexen-$(PACKAGE_VERSION)-win32.zip
+STRIFE_ZIP=$(PROGRAM_PREFIX)strife-$(PACKAGE_VERSION)-win32.zip
+ZIPS=$(DOOM_ZIP) $(HERETIC_ZIP) $(HEXEN_ZIP) $(STRIFE_ZIP)
DLL_FILES=$(TOPLEVEL)/src/SDL.dll \
$(TOPLEVEL)/src/SDL_mixer.dll \
@@ -15,26 +15,43 @@ DLL_FILES=$(TOPLEVEL)/src/SDL.dll \
DOC_FILES += README.OPL
-ZIP=$(PACKAGE_TARNAME)-$(PACKAGE_VERSION)-win32.zip
+all: $(ZIPS)
-$(ZIP) : staging
- zip -j -r $@ staging/
+$(ZIPS):
+ unix2dos $</*.txt
+ zip -j -r $@ $</*
-staging: $(EXE_FILES) $(DLL_FILES) $(patsubst %,../../%,$(DOC_FILES))
- rm -rf staging
- mkdir staging
- cp $(EXE_FILES) $(DLL_FILES) staging/
- $(STRIP) staging/*.exe
+$(DOOM_ZIP): staging-doom hook-doom
+$(HERETIC_ZIP): staging-heretic
+$(HEXEN_ZIP): staging-hexen
+$(STRIFE_ZIP): staging-strife
+
+# Special hooks to custom modify files for particular games.
+
+hook-doom: staging-doom
+ cp $(TOPLEVEL)/NOT-BUGS $</NOT-BUGS.txt
+
+# Build up a staging dir for a particular game.
+
+staging-%:
+ mkdir $@
+ cp $(TOPLEVEL)/src/$(PROGRAM_PREFIX)$*.exe \
+ $(DLL_FILES) \
+ $@/
+ cp $(TOPLEVEL)/src/$(PROGRAM_PREFIX)setup.exe \
+ $@/$(PROGRAM_PREFIX)$*-setup.exe
+ $(STRIP) $@/*.exe
+
for f in $(DOC_FILES); do \
- cp $(TOPLEVEL)/$$f staging/$$f.txt; \
- unix2dos staging/$$f.txt; \
+ cp $(TOPLEVEL)/$$f $@/$$f.txt; \
done
+ cp $(TOPLEVEL)/man/CMDLINE.$* $@/CMDLINE.txt
+
$(TOPLEVEL)/man/simplecpp -D_WIN32 -DPRECOMPILED \
< $(TOPLEVEL)/man/INSTALL.template \
- > staging/INSTALL.txt
- unix2dos staging/INSTALL.txt
+ > $@/INSTALL.txt
clean:
- rm -f $(ZIP)
- rm -rf staging
+ rm -f $(ZIPS)
+ rm -rf staging-*