Mercurial > hg > demos > krapula
diff Makefile @ 59:7daf69b39f34
Cleanups, add license, file_id.diz, fix and update build system.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Sat, 19 Aug 2017 16:06:58 +0300 |
parents | 554e3f02ba6f |
children | 6ee701e2d8d9 |
line wrap: on
line diff
--- a/Makefile Tue Oct 04 00:15:43 2016 +0300 +++ b/Makefile Sat Aug 19 16:06:58 2017 +0300 @@ -1,27 +1,38 @@ # # Generic build target # -DMLIB = ./dmlib/ -MAKE ?= make +include config.mak export DMLIB +export BINPATH -unix: - $(MAKE) -f $(DMLIB)Makefile EXEEXT=.bin +linux-bin: + $(MAKE) -f $(DMLIB)Makefile EXEEXT=-linux.bin mingw-win32: $(MAKE) -f $(DMLIB)Makefile.cross-mingw \ - OBJPATH=./obj/win32/ \ + OBJPATH=$(BPATH)/obj/win32/ \ MINGW_PREFIX=i686-w64-mingw32- \ MINGW_PATH=/usr/i686-w64-mingw32 mingw-win64: $(MAKE) -f $(DMLIB)Makefile.cross-mingw \ - OBJPATH=./obj/win64/ \ + OBJPATH=$(BPATH)/obj/win64/ \ MINGW_PREFIX=x86_64-w64-mingw32- \ MINGW_PATH=/usr/x86_64-w64-mingw32 +$(DATA): + cd $(BPATH)/data && $(DMLIB)/tools/packed -p $@ -c -x \*~ -v * + +package: linux-bin mingw-win32 $(DATA) + strip $(BINPATH)/*.bin $(BINPATH)/*.exe + $(RM) $(PACKAGE) + @cp SDL.dll LICENSE.txt README.txt file_id.diz $(BINPATH) + cd $(BINPATH) && zip -x "*~" -9 $(PACKAGE) * + + clean: - -$(MAKE) -f $(DMLIB)Makefile clean EXEEXT=.bin + -$(RM) $(DATA) + -$(MAKE) -f $(DMLIB)Makefile clean EXEEXT=-linux.bin -$(MAKE) -f $(DMLIB)Makefile.cross-mingw clean \ No newline at end of file