aboutsummaryrefslogtreecommitdiff
path: root/Makefile
blob: df0fad2daa418467cc6dadc599807e4ee8c3ceb9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
CFLAGS:=-Wall -O2

view_cflags:=$(shell pkg-config --cflags glib-2.0 gio-unix-2.0 gdk-pixbuf-2.0)
view_libs:=$(shell pkg-config --libs glib-2.0 gio-unix-2.0 gdk-pixbuf-2.0) -lm

objs:=view.o

all: view

view: $(objs)
	$(CC) $(LDFLAGS) -o $@ $+ $(view_libs)

$(objs): %.o: %.c
	$(CC) $(view_cflags) $(CFLAGS) -o $@ -c $<

clean:
	rm -f view *.o

.PHONY: all clean