2021-08-11 23:50:59 +10:00
|
|
|
TARGET = qtimer
|
2021-08-28 01:43:33 +10:00
|
|
|
LIBS = -lm -luiohook
|
2021-08-11 23:50:59 +10:00
|
|
|
CC = gcc
|
|
|
|
CFLAGS = -g -Wall
|
|
|
|
|
|
|
|
.PHONY: default all clean
|
|
|
|
|
|
|
|
default: $(TARGET)
|
|
|
|
all: default
|
|
|
|
|
|
|
|
OBJECTS = $(patsubst %.c, %.o, $(wildcard *.c))
|
|
|
|
HEADERS = $(wildcard *.h)
|
|
|
|
|
|
|
|
%.o: %.c $(HEADERS)
|
|
|
|
$(CC) $(CFLAGS) -c $< -o $@
|
|
|
|
|
|
|
|
.PRECIOUS: $(TARGET) $(OBJECTS)
|
|
|
|
|
|
|
|
$(TARGET): $(OBJECTS)
|
|
|
|
$(CC) $(OBJECTS) -Wall $(LIBS) -o $@
|
|
|
|
|
|
|
|
clean:
|
|
|
|
-rm -f *.o
|
|
|
|
-rm -f $(TARGET)
|