From d00f8b35b4838ba7c6bf00b7b211f463810f4ae5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?John=20Ankarstr=C3=B6m?= Date: Fri, 15 Jul 2022 16:57:15 +0200 Subject: Improve makedeps script. --- Makefile | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index df0a190..8a50d02 100644 --- a/Makefile +++ b/Makefile @@ -1,26 +1,26 @@ -C = c/main.cpp -PL = pl/cfg.pl pl/episode_data.pl pl/local_episodes.pl pl/track_episodes.pl +EXE = EpisodeBrowser.exe OBJ = b/common.obj b/datalistview.obj b/episodelistview.obj b/listview.obj b/pl.obj b/resource.obj +PL = pl/cfg.pl pl/episode_data.pl pl/local_episodes.pl pl/track_episodes.pl CC = swipl-ld CFLAGS += -Wall -Wpedantic -O -cc-options,-std=c++17 -ld-options,-mwindows CFLAGS += -DUNICODE -D_UNICODE LDFLAGS += -lcomctl32 -luxtheme -all: b/EpisodeBrowser.exe +all: b/$(EXE) cp $< "C:\Users\John\Desktop\Delat" clean: - rm -fr b/EpisodeBrowser.exe b/*.obj + rm -fr b/$(EXE) b/*.obj TAGS: c/*.cpp c/*.h pl/*.pl etags c/*.cpp c/*.h -lprolog pl/*.pl deps.mk: c/*.cpp - perl makedeps.pl + perl makedeps -b/EpisodeBrowser.exe: Makefile deps.mk $(C) $(OBJ) $(PL) c/*.h - $(CC) -v $(CFLAGS) $(LDFLAGS) -goal true -o $@ $(C) $(OBJ) $(PL) +b/$(EXE): Makefile deps.mk c/main.cpp $(OBJ) $(PL) + $(CC) -v $(CFLAGS) $(LDFLAGS) -goal true -o $@ c/main.cpp $(OBJ) $(PL) b/resource.obj: c/resource.h c/resource.rc c/application.manifest windres -i c/resource.rc -o b/resource.obj @@ -28,4 +28,6 @@ b/resource.obj: c/resource.h c/resource.rc c/application.manifest b/%.obj: c/%.cpp $(CC) -c $(CFLAGS) -o $@ $< +# deps.mk includes additional, dynamically generated dependencies for +# b/*.obj and b/EpisodeBrowser.exe. -include deps.mk -- cgit v1.2.3