annotate Makefile @ 20:07316b0cdace

Strip binaries.
author Matti Hamalainen <ccr@tnsp.org>
date Sat, 23 May 2015 05:40:03 +0300
parents da7ac3f7d014
children feba3bc729a5
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
1 #
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
2 # Generic build target
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
3 #
19
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
4 BPATH := /home/ccr/bussi
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
5 DMLIB := $(BPATH)/dmlib/
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
6 PACKAGE = $(BPATH)/ap-bussi.zip
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
7 BINPATH = $(BPATH)/bin/
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
8 DATA = $(BINPATH)/bussi.dat
0
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
9 MAKE ?= make
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
10
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
11 export DMLIB
19
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
12 export BINPATH
0
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
13
19
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
14 linux-bin:
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
15 $(MAKE) -f $(DMLIB)Makefile EXEEXT=-linux.bin
0
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
16
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
17 mingw-win32:
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
18 $(MAKE) -f $(DMLIB)Makefile.cross-mingw \
19
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
19 OBJPATH=$(BPATH)/obj/win32/ \
0
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
20 MINGW_PREFIX=i686-w64-mingw32- \
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
21 MINGW_PATH=/usr/i686-w64-mingw32
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
22
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
23 mingw-win64:
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
24 $(MAKE) -f $(DMLIB)Makefile.cross-mingw \
19
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
25 OBJPATH=$(BPATH)/obj/win64/ \
0
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
26 MINGW_PREFIX=x86_64-w64-mingw32- \
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
27 MINGW_PATH=/usr/x86_64-w64-mingw32
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
28
19
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
29 $(DATA):
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
30 cd $(BPATH)/data && $(DMLIB)/tools/packed -p $@ -c -v *
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
31
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
32 package: linux-bin mingw-win32 $(BINPATH)/bussi.dat
20
07316b0cdace Strip binaries.
Matti Hamalainen <ccr@tnsp.org>
parents: 19
diff changeset
33 strip $(BINPATH)/*.bin $(BINPATH)/*.exe
19
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
34 $(RM) $(PACKAGE)
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
35 @cp README.txt file_id.diz $(BINPATH)
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
36 cd $(BINPATH) && zip -x\*~ -9 $(PACKAGE) *
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
37
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
38
0
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
39 clean:
19
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
40 -$(RM) $(DATA)
da7ac3f7d014 Work on build process.
Matti Hamalainen <ccr@tnsp.org>
parents: 3
diff changeset
41 -$(MAKE) -f $(DMLIB)Makefile clean EXEEXT=-linux.bin
0
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
42 -$(MAKE) -f $(DMLIB)Makefile.cross-mingw clean
f339a3903bc9 Initial import.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
43