aboutsummaryrefslogtreecommitdiff
path: root/Makefile
blob: 2e623378367dd7387074254a14014dee50701a79 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
SRC = $(wildcard *.c)
OBJ = $(SRC:.c=.o)
BIN = comet.bin

DEPS = cairo \
       xcb \
       xcb-icccm \
       xcb-xrm \
       "xcb-randr >= 1.5" \
       "glib-2.0 >= 2.44" \
       gio-2.0

CFLAGS  := $(shell pkg-config --cflags $(DEPS)) -ggdb
LDFLAGS := $(shell pkg-config --libs $(DEPS)) -lm

all: $(BIN)

$(BIN): $(OBJ)
	$(CC) -o $@ $(LDFLAGS) $^

%.o: %.c
	$(CC) -o $@ -c $(CFLAGS) $^

clean:
	rm -rf $(BIN) $(OBJ)