TaKl/Makefile

36 lines
546 B
Makefile
Raw Normal View History

FLAGS = -g -Wall -Wextra -DLOG_USE_COLOR
LD_FLAGS = -lsqlite3
2023-07-12 11:08:40 +02:00
$(shell mkdir -p out)
all: takl takl-daemon
2023-07-12 11:08:40 +02:00
out/%.o: src/%.c
$(CC) -c $(FLAGS) $^ -o $@
out/%.o: src/main/%.c
$(CC) -c $(FLAGS) $^ -o $@
out/%.o: src/log/%.c
$(CC) -c $(FLAGS) $^ -o $@
2023-07-12 11:08:40 +02:00
takl: out/main.o out/db.o out/tasks.o
$(CC) $(FLAGS) $(LD_FLAGS) $^ -o $@
takl-daemon: out/daemon.o out/db.o out/tasks.o out/log.o
$(CC) $(FLAGS) $(LD_FLAGS) $^ -o $@
2023-07-12 11:08:40 +02:00
2023-07-12 22:55:38 +02:00
install: takl
sudo cp takl /usr/bin/takl
uninstall: takl
sudo rm /usr/bin/takl
2023-07-12 11:08:40 +02:00
clean:
rm out -r
rm ./takl