diff options
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -11,15 +11,18 @@ CC ?= gcc CFLAGS ?= -std=c99 -pipe -O2 -Werror -Wall -Wpedantic -Wextra -Wno-sign-compare -Wno-unused-parameter -Wunreachable-code -Wshadow -Wpointer-arith -Wwrite-strings -Wcast-align -Wstrict-prototypes -LDFLAGS ?= -lm -lpng +LDFLAGS ?= -Wl,-O1,--sort-common,--as-needed,-z,relro +LIBS ?= -lm -lpng RM ?= rm -f kd-forest: kd-forest.c kd-forest.h util.c util.h color.c color.h main.c - $(CC) $(CFLAGS) $(LDFLAGS) -o kd-forest kd-forest.c util.c color.c main.c + $(CC) $(CFLAGS) $(LDFLAGS) kd-forest.c util.c color.c main.c $(LIBS) -o kd-forest -image: kd-forest +kd-forest.png: kd-forest ./kd-forest +image: kd-forest.png + clean: $(RM) kd-forest |