Simplify makefile rule
authorPeter Eisentraut <peter_e@gmx.net>
Sun, 29 Apr 2012 17:59:12 +0000 (20:59 +0300)
committerPeter Eisentraut <peter_e@gmx.net>
Sun, 29 Apr 2012 18:20:14 +0000 (21:20 +0300)
Instead of writing out the .c -> .o rule, use the default one, so that
dependency tracking can be used.

src/port/Makefile

index 4e3a8edd3a151253a6cc65509d98f4b620277bee..0225b397a3080cae4d2c8ad4cb6babdadeebf147 100644 (file)
@@ -53,8 +53,7 @@ libpgport.a: $(OBJS)
        $(AR) $(AROPT) $@ $^
 
 # thread.o needs PTHREAD_CFLAGS (but thread_srv.o does not)
-thread.o: thread.c
-       $(CC) $(CFLAGS) $(CPPFLAGS) $(PTHREAD_CFLAGS) -c $<
+thread.o: CFLAGS+=$(PTHREAD_CFLAGS)
 
 #
 # Server versions of object files