Stop building resource PWADs and "make dist" generates a single Zip

The resource PWADs have been around for a very long time and dated
from before Freedoom was capable of running as a complete IWAD on its
own. Few people ever cared about these files, as evident by a lack of
reports about freedoom_levels.wad not even being correct.

Additionally, the separate Zips for each IWAD is gone. With that,
Freedoom will be distributed as a single Zip file only that includes
all of the subprojects.
master
Mike Swanson 2014-01-06 22:34:47 -08:00
parent 683169965f
commit bfb95753bd
3 changed files with 25 additions and 98 deletions

1
.gitignore vendored
View File

@ -16,6 +16,7 @@ textures/freedm/pnames.txt
textures/freedm/texture1.txt
textures/texture1.txt
wads/*.wad
wads/*.zip
wad*.txt
*.bak
*.pyc

View File

@ -34,17 +34,12 @@ DEUTEX=deutex
DEUTEX_BASIC_ARGS=-v0 -fullsnd -rate accept -rgb 0 255 255
DEUTEX_ARGS=$(DEUTEX_BASIC_ARGS) -doom2 bootstrap/
OBJS = \
$(WADS)/freedoom.wad \
$(WADS)/freedoom_levels.wad \
$(WADS)/freedoom_sprites.wad \
$(WADS)/freedoom_sounds.wad \
$(WADS)/freedoom_textures.wad \
OBJS= \
$(WADS)/doom2.wad \
$(WADS)/doom.wad \
$(WADS)/freedm.wad
all : $(OBJS)
all: $(OBJS)
subdirs:
make -C graphics/text
@ -95,15 +90,6 @@ wadinfo_freedm.txt : buildcfg.txt force textures/freedm/pnames.txt
# entries, so we have to change the texture1 symlink to point
# to whichever wad we are working on
#---------------------------------------------------------
# build wad
$(WADS)/freedoom.wad: wadinfo.txt subdirs force
@mkdir -p $(WADS)
ln -sf doom2/texture1.txt textures/texture1.txt
rm -f $@
$(DEUTEX) $(DEUTEX_ARGS) -textures -lumps -patch -flats -sounds -musics -graphics -sprites -build wadinfo.txt $@
#---------------------------------------------------------
# freedm iwad
@ -114,7 +100,7 @@ $(WADS)/freedm.wad: wadinfo_freedm.txt subdirs force
$(DEUTEX) $(DEUTEX_ARGS) -iwad -build wadinfo_freedm.txt $@
#---------------------------------------------------------
# iwad
# doom2 iwad
$(WADS)/doom2.wad: wadinfo_iwad.txt subdirs force
@mkdir -p $(WADS)
@ -131,39 +117,6 @@ $(WADS)/doom.wad: wadinfo_ult.txt subdirs force
rm -f $@
$(DEUTEX) $(DEUTEX_ARGS) -iwad -textures -lumps -patch -flats -sounds -musics -graphics -sprites -levels -build wadinfo_ult.txt $@
#---------------------------------------------------------
# build levels wad
$(WADS)/freedoom_levels.wad : wadinfo.txt force
@mkdir -p $(WADS)
rm -f $@
$(DEUTEX) $(DEUTEX_ARGS) -levels -build wadinfo.txt $@
#---------------------------------------------------------
# build texture wad
$(WADS)/freedoom_textures.wad : wadinfo.txt force
@mkdir -p $(WADS)
ln -sf doom2/texture1.txt textures/texture1.txt
rm -f $@
$(DEUTEX) $(DEUTEX_ARGS) -textures -patch -flats -build wadinfo.txt $@
#---------------------------------------------------------
# build sprites wad
$(WADS)/freedoom_sprites.wad : wadinfo.txt force
@mkdir -p $(WADS)
rm -f $@
$(DEUTEX) $(DEUTEX_ARGS) -sprites -build wadinfo.txt $@
#---------------------------------------------------------
# build sounds wad
$(WADS)/freedoom_sounds.wad : wadinfo.txt force
@mkdir -p $(WADS)
rm -f $@
$(DEUTEX) $(DEUTEX_ARGS) -sounds -musics -build wadinfo.txt $@
doc: BUILD-SYSTEM.asc README.asc
asciidoc BUILD-SYSTEM.asc
asciidoc README.asc

View File

@ -1,6 +1,5 @@
#!/usr/bin/env python
#
# Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2013
# Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2013, 2014
# Contributors to the Freedoom project. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
@ -39,14 +38,7 @@ DIST_DOCS = [
"README.html"
]
# Most WADs are given a ZIP equal to their name, but some have different
# names:
DIR_NAMES = {
'doom2' : 'freedoom-iwad',
'doom' : 'freedoom-ultimate',
'freedoom' : 'freedoom-resource-wad',
}
DIR_NAME='freedoom'
# Run a command, displaying it before executing it.
@ -59,47 +51,28 @@ def run_command(command):
version = os.getenv("VERSION")
if version is None:
raise Exception("Version not specified for release!")
sys.stderr.write("Version not specific for release\n")
sys.exit(1)
if version[0] is 'v':
# Strip the leading 'v' from versioning
version = version[1:]
# Build all of the packages
path = os.path.dirname(sys.argv[1])
basename = os.path.basename(sys.argv[1])
for filename in sys.argv[1:]:
base_dir = DIR_NAME + "-" + version
full_path = path + "/" + base_dir
path = os.path.dirname(filename)
basename = os.path.basename(filename)
# Create directory and add files
# Cut off the extension, and build the directory name
run_command("mkdir %s" % full_path)
for files in DIST_DOCS + sys.argv[1:]:
run_command("cp %s %s" % (files, full_path))
pkgname = basename[0:-4]
orig_dir = os.getcwd()
if pkgname in DIR_NAMES:
base_dir = DIR_NAMES[pkgname]
else:
base_dir = pkgname
# Append the version:
base_dir += "-" + version
# Replace underscores with hyphens:
base_dir = base_dir.replace("_", "-")
full_path = path + "/" + base_dir
# Create directory, and add files.
run_command("mkdir %s" % full_path)
for doc in DIST_DOCS + [ filename ]:
run_command("cp %s %s" % (doc, full_path))
# Change to the parent directory, and build the zip
orig_dir = os.getcwd()
os.chdir(path)
run_command("rm -f %s.zip" % base_dir)
run_command("zip -r %s.zip %s" % (base_dir, base_dir))
run_command("rm -rf %s" % base_dir)
os.chdir(orig_dir)
os.chdir(path)
run_command("rm -f %s.zip" % base_dir)
run_command("zip -r %s.zip %s" % (base_dir, base_dir))
run_command("rm -rf %s" % base_dir)
os.chdir(orig_dir)