Make build rule even more explicit
authorSiraaj Khandkar <siraaj@khandkar.net>
Fri, 17 Apr 2020 18:29:11 +0000 (14:29 -0400)
committerSiraaj Khandkar <siraaj@khandkar.net>
Fri, 17 Apr 2020 18:29:11 +0000 (14:29 -0400)
src/Makefile

index 400e2ce..d672569 100644 (file)
@@ -1,6 +1,8 @@
 CPPFLAGS := -D_POSIX_C_SOURCE=200809L
-CFLAGS   := -std=c99 -Wall -Wextra
+CFLAGS   := -std=c99 -Wall -Wextra -pedantic
 LDLIBS   := -lncurses
+LDFLAGS  := -s  # Remove all symbol table and relocation information from the
+                # executable.
 
 .PHONY: build clean
 
@@ -9,5 +11,5 @@ build: clockloop
 clean:
        rm -f clockloop
 
-clockloop:
-       $(CC) $(LDLIBS) clockloop.c -o clockloop
+clockloop: clockloop.c
+       $(CC) $(LDFLAGS) $(CPPFLAGS) $(CFLAGS) -o $@ $< $(LDLIBS)
This page took 0.027782 seconds and 4 git commands to generate.