From 9bf21b932f692bbccace0f74cec8e2130d7f4477 Mon Sep 17 00:00:00 2001 From: Ozkan Sezer Date: Wed, 9 Aug 2017 12:10:13 +0000 Subject: [PATCH] Makefiles: replace '$^' with '$<' in build rules. add dependency list for image.o. git-svn-id: svn://svn.code.sf.net/p/quakespasm/code/trunk/quakespasm@1469 af15c1b1-3010-417e-b628-4374ebc0bcbd --- Quake/Makefile | 4 +++- Quake/Makefile.darwin | 8 +++++--- Quake/Makefile.w32 | 6 ++++-- Quake/Makefile.w64 | 6 ++++-- 4 files changed, 16 insertions(+), 8 deletions(-) diff --git a/Quake/Makefile b/Quake/Makefile index 3f9a7c6d..2b09be95 100644 --- a/Quake/Makefile +++ b/Quake/Makefile @@ -193,7 +193,7 @@ DEFAULT_TARGET := quakespasm # --------------------------- %.o: %.c - $(CC) $(DFLAGS) -c $(CFLAGS) $(SDL_CFLAGS) -o $@ $^ + $(CC) $(DFLAGS) -c $(CFLAGS) $(SDL_CFLAGS) -o $@ $< # ---------------------------------------------------------------------------- # objects @@ -290,6 +290,8 @@ quakespasm: $(OBJS) $(LINKER) $(OBJS) $(LDFLAGS) $(LIBS) $(SDL_LIBS) -o $@ $(call do_strip,$@) +image.o: lodepng.c lodepng.h stb_image_write.h + release: quakespasm debug: $(error Use "make DEBUG=1") diff --git a/Quake/Makefile.darwin b/Quake/Makefile.darwin index d6068aa7..b2afdbb1 100644 --- a/Quake/Makefile.darwin +++ b/Quake/Makefile.darwin @@ -215,11 +215,11 @@ DEFAULT_TARGET := quakespasm # --------------------------- %.o: %.c - $(CC) $(DFLAGS) -c $(CFLAGS) $(SDL_CFLAGS) -o $@ $^ + $(CC) $(DFLAGS) -c $(CFLAGS) $(SDL_CFLAGS) -o $@ $< %.o: %.m - $(CC) $(DFLAGS) -c $(CFLAGS) $(SDL_CFLAGS) -o $@ $^ + $(CC) $(DFLAGS) -c $(CFLAGS) $(SDL_CFLAGS) -o $@ $< %.o: ../MacOSX/%.m - $(CC) $(DFLAGS) -c -I../MacOSX $(CFLAGS) $(SDL_CFLAGS) -o $@ $^ + $(CC) $(DFLAGS) -c -I../MacOSX $(CFLAGS) $(SDL_CFLAGS) -o $@ $< # ---------------------------------------------------------------------------- # objects @@ -316,6 +316,8 @@ quakespasm: $(OBJS) $(LINKER) $(OBJS) $(LDFLAGS) $(LIBS) $(SDL_LIBS) -o $@ $(call do_strip,$@) +image.o: lodepng.c lodepng.h stb_image_write.h + release: quakespasm debug: $(error Use "make DEBUG=1") diff --git a/Quake/Makefile.w32 b/Quake/Makefile.w32 index c3598062..7ec7b892 100644 --- a/Quake/Makefile.w32 +++ b/Quake/Makefile.w32 @@ -181,9 +181,9 @@ DEFAULT_TARGET := quakespasm.exe # --------------------------- %.o: %.c - $(CC) $(DFLAGS) -c $(CFLAGS) $(SDL_CFLAGS) -o $@ $^ + $(CC) $(DFLAGS) -c $(CFLAGS) $(SDL_CFLAGS) -o $@ $< %.res: ../Windows/%.rc - $(WINDRES) -I../Windows --output-format=coff --target=pe-i386 -o $@ $^ + $(WINDRES) -I../Windows --output-format=coff --target=pe-i386 -o $@ $< # ---------------------------------------------------------------------------- # objects @@ -280,6 +280,8 @@ quakespasm.exe: $(OBJS) $(LINKER) $(OBJS) $(LDFLAGS) $(LIBS) $(SDL_LIBS) -o $@ $(call do_strip,$@) +image.o: lodepng.c lodepng.h stb_image_write.h + release: quakespasm.exe debug: $(error Use "make DEBUG=1") diff --git a/Quake/Makefile.w64 b/Quake/Makefile.w64 index 8112c2ae..6b56878e 100644 --- a/Quake/Makefile.w64 +++ b/Quake/Makefile.w64 @@ -179,9 +179,9 @@ DEFAULT_TARGET := quakespasm.exe # --------------------------- %.o: %.c - $(CC) $(DFLAGS) -c $(CFLAGS) $(SDL_CFLAGS) -o $@ $^ + $(CC) $(DFLAGS) -c $(CFLAGS) $(SDL_CFLAGS) -o $@ $< %.res: ../Windows/%.rc - $(WINDRES) -I../Windows --output-format=coff --target=pe-x86-64 -o $@ $^ + $(WINDRES) -I../Windows --output-format=coff --target=pe-x86-64 -o $@ $< # ---------------------------------------------------------------------------- # objects @@ -278,6 +278,8 @@ quakespasm.exe: $(OBJS) $(LINKER) $(OBJS) $(LDFLAGS) $(LIBS) $(SDL_LIBS) -o $@ $(call do_strip,$@) +image.o: lodepng.c lodepng.h stb_image_write.h + release: quakespasm.exe debug: $(error Use "make DEBUG=1")