CCOPTS=-std=gnu18 -O2 -Wall -Werror -Wpedantic all: daily weekly daily: lib cc $(CCOPTS) obj/*.o src/daily.c -o dailyjournal weekly: lib cc $(CCOPTS) obj/*.o src/weekly.c -o weeklyjournal lib: if [ ! -d obj ]; then mkdir obj; fi cc $(CCOPTS) src/path.c -c -o obj/path.o cc $(CCOPTS) src/edit.c -c -o obj/edit.o clean: rm -rf obj