2011-11-20 03:29:08 +00:00
|
|
|
TARGETNAME=rufus
|
|
|
|
|
|
|
|
CC = gcc
|
|
|
|
RC = windres
|
|
|
|
STRIP = strip
|
2011-11-20 22:49:55 +00:00
|
|
|
CFLAGS = -std=gnu99 -Wall -Wundef -Wunused -Wstrict-prototypes -Werror-implicit-function-declaration -Wno-pointer-sign -Wshadow -O2 -Wl,--subsystem,windows -DWINVER=0x501 -D_WIN32_IE=0x501
|
2011-11-21 17:06:17 +00:00
|
|
|
LIBS = -lsetupapi -lole32 -lgdi32
|
|
|
|
|
|
|
|
RUFUS_SRC = rufus.c stdlg.c
|
2011-11-20 03:29:08 +00:00
|
|
|
|
|
|
|
.PHONY: all clean
|
|
|
|
|
|
|
|
all: $(TARGETNAME)
|
|
|
|
|
2011-11-21 17:06:17 +00:00
|
|
|
$(TARGETNAME): $(RUFUS_SRC) $(TARGETNAME)_rc.o
|
2011-11-20 03:29:08 +00:00
|
|
|
@echo "[CCLD] $@"
|
|
|
|
@$(CC) -o $@ $(CFLAGS) $^ $(TARGETNAME)_rc.o $(LIBS)
|
|
|
|
@$(STRIP) $(TARGETNAME).exe
|
|
|
|
|
|
|
|
$(TARGETNAME)_rc.o: $(TARGETNAME).rc
|
|
|
|
@echo "[RC] $@"
|
|
|
|
@$(RC) -i $< -o $@
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f *.exe *.o
|