summaryrefslogtreecommitdiff
blob: 72695a951f7ee320b0ff852308a2c025ac5600e8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
Index: Makefile
===================================================================
--- a/Makefile	(revision 109)
+++ b/Makefile	(working copy)
@@ -19,7 +19,7 @@
 
 CC       ?= gcc
 
-LIBS  += -lncurses -lpthread -lrt -lm
+LIBS  += `pkg-config --libs ncurses` -lpthread -lrt -lm
 INCLUDEFLAGS = 
 
 BIN	= i7z
@@ -42,7 +42,7 @@
 
 #http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=644728 for -ltinfo on debian
 static-bin: message $(OBJ)
-	$(CC) $(CFLAGS) $(LDFLAGS) -o $(BIN) $(OBJ) -static-libgcc -DNCURSES_STATIC -static -lpthread -lncurses -lrt -lm -ltinfo
+	$(CC) $(CFLAGS) $(LDFLAGS) -o $(BIN) $(OBJ) -static-libgcc -DNCURSES_STATIC -static -lpthread `pkg-config --static --libs ncurses` -lrt -lm
 
 # perfmon-bin: message $(OBJ)
 # 	$(CC) $(CFLAGS) $(LDFLAGS) -o $(PERFMON-BIN) perfmon-i7z.c helper_functions.c $(LIBS)