aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile9
1 files changed, 8 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index bf04586..c5e8670 100644
--- a/Makefile
+++ b/Makefile
@@ -1,10 +1,14 @@
PROJECT_ROOT = $(dir $(abspath $(lastword $(MAKEFILE_LIST))))
INPUTS = $(PROJECT_ROOT)win.c
+INPUTS += resource.obj
INPUTS += $(PROJECT_ROOT)track_episodes.pl
INPUTS += $(PROJECT_ROOT)local_episodes.pl
INPUTS += $(PROJECT_ROOT)episode_data.pl
+CFLAGS += -v -cc-options,-mwindows,-municode -DUNICODE -D_UNICODE
+LDFLAGS += -lcomctl32 -lgdi32
+
ifeq ($(BUILD_MODE),debug)
CFLAGS += -g
else ifeq ($(BUILD_MODE),run)
@@ -21,9 +25,12 @@ endif
all: episode_browser.exe
episode_browser.exe: $(INPUTS)
- swipl-ld -v $(CFLAGS) $(LDFLAGS) -goal true -o $@ $(INPUTS)
+ swipl-ld $(CFLAGS) $(LDFLAGS) -goal true -o $@ $(INPUTS)
$(EXTRA_CMDS)
+resource.obj: $(PROJECT_ROOT)resource.h $(PROJECT_ROOT)resource.rc
+ windres -i $(PROJECT_ROOT)resource.rc -o resource.obj
+
#%.o: $(PROJECT_ROOT)%.c
# $(CC) -c $(CFLAGS) -o $@ $<