summaryrefslogtreecommitdiff
blob: 4763839624af5dde68a1ee6666db19ee17dd23e4 (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
--- a/Makefile
+++ b/Makefile
@@ -1,15 +1,15 @@
-CC = gcc
-CCFLAGS = `gtk-config --cflags`
-LDFLAGS = `gtk-config --libs`
+CC ?= gcc
+CFLAGS += `${PKG_CONFIG} --cflags gtk+-2.0`
+LIBS = `${PKG_CONFIG} --libs gtk+-2.0`
 
 gbase:	gbase.o
-	$(CC) gbase.o $(LDFLAGS) -o gbase
+	$(CC) $(LDFLAGS) gbase.o $(LIBS) -o gbase
 
 clean:
 	rm -f gbase gbase.o gbase.c~
 
 # Make object files:
 %.o:
-	$(CC) $(CCFLAGS) -c $*.c
+	$(CC) $(CFLAGS) -c $*.c
 
-gbase.o: gbase.c
\ No newline at end of file
+gbase.o: gbase.c