aocc23

Advent of Code 2023
git clone git://www.tkruger.se/aocc23.git
Log | Files | Refs | README

Makefile (599B)


      1 CC=clang
      2 CFLAGS+=-std=c99 -pedantic -Wall -Werror -Wstrict-prototypes
      3 CFLAGS+=-Wmissing-prototypes -Wmissing-declarations -Wshadow
      4 CFLAGS+=-Wpointer-arith -Wcast-qual -Wsign-compare
      5 CFLAGS+=-O2 -g
      6 CFLAGS+=-fstack-protector-all -Wtype-limits -fno-common
      7 CFLAGS+=-fno-builtin
      8 CFLAGS+=-I/usr/local/include
      9 LDFLAGS=-lcunit -L/usr/local/lib
     10 
     11 OBJS=\
     12   ../reading.o \
     13 	../stack_u64.o \
     14   ../wdg.o \
     15 	../fheap.o
     16 
     17 all: utils tests
     18 
     19 utils:
     20 	make -C ../
     21 
     22 tests: tests.c $(TEST_OBJS)
     23 	$(CC) $(CFLAGS) $(LDFLAGS) -o tests tests.c $(OBJS)
     24 	./tests
     25 
     26 .c.o:
     27 	$(CC) $(CFLAGS) -c $<
     28 
     29 clean:
     30 	rm -rf tests $(TEST_OBJS)