-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
49 lines (37 loc) · 1.87 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
all: sneakin.wad sneakin-maps.wad sneakin-tex.wad
clean:
rm -rf build release full_wadinfo.txt sneakin.wad sneakin-maps.wad sneakin-tex.wad
make -C textures clean
REL_WAD=release/sneakins-wad/sneakin.wad
release: release/sneakins-wad.tgz release/sneakins-wad.zip
release/sneakins-wad:
rm -rf $@ && mkdir -p $@
release/sneakins-wad/README.md: README.md ./release/sneakins-wad release/sneakins-wad/sneakin.wad
cp $< $@
echo -e "\n\n# Hashes\n\n* SHA256: $$(sha256sum $(REL_WAD) | cut -f 1 -d ' ')\n* SHA512: $$(sha512sum $(REL_WAD) | cut -f 1 -d ' ')\n" >> $@
release/sneakins-wad/README.html: release/sneakins-wad/README.md ./release/sneakins-wad
markdown_py $< > $@
release/sneakins-wad/sneakin.wad: sneakin.wad ./release/sneakins-wad
cp $< $@
release/sneakins-wad.tgz: release/sneakins-wad/README.md release/sneakins-wad/README.html release/sneakins-wad/sneakin.wad
cd release && tar cvf sneakins-wad.tgz sneakins-wad
release/sneakins-wad.zip: release/sneakins-wad/README.md release/sneakins-wad/README.html release/sneakins-wad/sneakin.wad
cd release && zip -r -u sneakins-wad.zip sneakins-wad
./build:
mkdir -p build
build/full_wadinfo.txt: maps_wadinfo.txt textures/wadinfo.txt
cat $^ > $@
sneakin.wad: ./build build/full_wadinfo.txt sneakin-tex.wad $(wildcard levels/*.wad)
cd build && \
cp -r ../levels . && \
cp -r ../textures/flats ../textures/patches ../textures/textures ../textures/lumps . && \
deutex -overwrite -build full_wadinfo.txt $@ && \
ln -nsf build/$@ ../$@
sneakin-maps.wad: maps_wadinfo.txt $(wildcard levels/*)
deutex -overwrite -build maps_wadinfo.txt $@
textures/wadinfo.txt: textures/wadinfo.txt.erb
make -C textures
textures/sneakin-tex.wad: textures/wadinfo.txt textures/textures/texture2.txt $(wildcard textures/*/*.png textures/*/*.txt textures/*/*.lmp textures/*/*.erb)
make -C textures
sneakin-tex.wad: textures/sneakin-tex.wad
ln -nsf $< $@