projects
/
centaur.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
f65740b
)
Use pkg-config
author
norly
<ny-git@enpas.org>
Tue, 12 Feb 2013 15:44:48 +0000
(15:44 +0000)
committer
norly
<ny-git@enpas.org>
Mon, 3 Jun 2013 01:08:00 +0000
(
02:08
+0100)
Makefile
patch
|
blob
|
history
diff --git
a/Makefile
b/Makefile
index b62b9ab7582ca6af70f0a73df2d214b412ad8cce..41e8fe5a34ee5be4a53b272f363d20e1e0179d2e 100644
(file)
--- a/
Makefile
+++ b/
Makefile
@@
-1,5
+1,7
@@
PROJ := elfedit
PROJ := elfedit
+LIBRARIES := libelf
+
BUILDDIR := build
INCLUDEDIR := include
SRCDIR := src
BUILDDIR := build
INCLUDEDIR := include
SRCDIR := src
@@
-11,9
+13,9
@@
HEADERS += $(shell find $(SRCDIR)/ -iname "*.h")
SOURCES := $(shell find $(SRCDIR)/ -iname "*.c")
OBJS := $(patsubst %.c, $(BUILDDIR)/%.o, $(SOURCES))
SOURCES := $(shell find $(SRCDIR)/ -iname "*.c")
OBJS := $(patsubst %.c, $(BUILDDIR)/%.o, $(SOURCES))
-INCLUDES := $(patsubst %, -I%, $(INCLUDEDIR) $(SRCDIR))
-CFLAGS := -g -Wall
-LDFLAGS :=
-lelf
+INCLUDES := $(patsubst %, -I%, $(INCLUDEDIR) $(SRCDIR))
$(shell pkg-config --cflags-only-I $(LIBRARIES))
+CFLAGS := -g -Wall
$(shell pkg-config --cflags-only-other $(LIBRARIES))
+LDFLAGS :=
$(shell pkg-config --libs $(LIBRARIES))