From 10d71adfc47091a62ad9b937943c312c1baf20af Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Sat, 20 Feb 2021 21:33:44 +0100 Subject: Use c99 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- Makefile | 24 +++++++----------------- 1 file changed, 7 insertions(+), 17 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 2023518..9f060d7 100644 --- a/Makefile +++ b/Makefile @@ -1,27 +1,17 @@ -OPTIMISE = -Og -g -WARN = -Wall -Wextra -pedantic -Wdouble-promotion -Wformat=2 -Winit-self -Wmissing-include-dirs \ - -Wtrampolines -Wfloat-equal -Wshadow -Wmissing-prototypes -Wmissing-declarations \ - -Wredundant-decls -Wnested-externs -Winline -Wno-variadic-macros -Wsync-nand \ - -Wunsafe-loop-optimizations -Wcast-align -Wstrict-overflow \ - -Wundef -Wbad-function-cast -Wcast-qual -Wwrite-strings -Wlogical-op -Waggregate-return \ - -Wstrict-prototypes -Wold-style-definition -Wpacked -Wvector-operation-performance \ - -Wunsuffixed-float-constants -Wsuggest-attribute=const -Wsuggest-attribute=noreturn \ - -Wsuggest-attribute=pure -Wsuggest-attribute=format -Wnormalized=nfkc -Wconversion \ - -fstrict-aliasing -fstrict-overflow -fipa-pure-const -ftree-vrp -fstack-usage \ - -funsafe-loop-optimizations -Wdeclaration-after-statement +.POSIX: + +CPPFLAGS = -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=700 +CFLAGS = -std=c99 -g +LDFLAGS = all: hungarian hungarian: hungarian.c - gcc -std=gnu99 $(OPTIMISE) $(WARN) $(CFLAGS) $(LDFLAGS) $(CPPFLAGS) -o $@ $< - -test: hungarian - ./hungarian + gcc -o $@ $< $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) clean: -rm -f -- hungarian -.PHONY: all test valgrind clean - +.PHONY: all clean -- cgit v1.2.3-70-g09d2