############################################################ # Launch5j, by LoRd_MuldeR # # Java JAR wrapper for creating Windows native executables # # https://github.com/lordmulder/ # # # # This work has been released under the MIT license. # # Please see LICENSE.TXT for details! # # # # ACKNOWLEDGEMENT # # This project is partly inspired by the Launch4j project: # # https://sourceforge.net/p/launch4j/ # ############################################################ MARCH ?= i586 MTUNE ?= intel CFLAGS = -O3 -municode -mwindows -march=$(MARCH) -mtune=$(MTUNE) .PHONY: all init headers resources clean all: headers init: mkdir -p bin mkdir -p obj resources: init windres -o obj/icon.o res/icon.rc windres -o obj/splash_screen.o res/splash_screen.rc headers: init resources $(CC) $(CFLAGS) -o bin/head.exe -DJAR_FILE_WRAPPED=0 -DSTAY_ALIVE=1 -DENABLE_SPLASH=1 src/head.c obj/icon.o obj/splash_screen.o $(CC) $(CFLAGS) -o bin/head_nosplash.exe -DJAR_FILE_WRAPPED=0 -DSTAY_ALIVE=1 -DENABLE_SPLASH=0 src/head.c obj/icon.o $(CC) $(CFLAGS) -o bin/head_nowait.exe -DJAR_FILE_WRAPPED=0 -DSTAY_ALIVE=0 -DENABLE_SPLASH=1 src/head.c obj/icon.o obj/splash_screen.o $(CC) $(CFLAGS) -o bin/head_nowait_nosplash.exe -DJAR_FILE_WRAPPED=0 -DSTAY_ALIVE=0 -DENABLE_SPLASH=0 src/head.c obj/icon.o $(CC) $(CFLAGS) -o bin/head_wrapped.exe -DJAR_FILE_WRAPPED=1 -DSTAY_ALIVE=1 -DENABLE_SPLASH=1 src/head.c obj/icon.o obj/splash_screen.o $(CC) $(CFLAGS) -o bin/head_wrapped_nosplash.exe -DJAR_FILE_WRAPPED=1 -DSTAY_ALIVE=1 -DENABLE_SPLASH=0 src/head.c obj/icon.o $(CC) $(CFLAGS) -o bin/head_wrapped_nowait.exe -DJAR_FILE_WRAPPED=1 -DSTAY_ALIVE=0 -DENABLE_SPLASH=1 src/head.c obj/icon.o obj/splash_screen.o $(CC) $(CFLAGS) -o bin/head_wrapped_nowait_nosplash.exe -DJAR_FILE_WRAPPED=1 -DSTAY_ALIVE=0 -DENABLE_SPLASH=0 src/head.c obj/icon.o strip bin/head.exe strip bin/head_nosplash.exe strip bin/head_nowait.exe strip bin/head_nowait_nosplash.exe strip bin/head_wrapped.exe strip bin/head_wrapped_nosplash.exe strip bin/head_wrapped_nowait.exe strip bin/head_wrapped_nowait_nosplash.exe clean: init rm -f bin/*.exe rm -f obj/*.o