From 4b4ad16b7f79fcb59bdbd4afe1129e759c741bc2 Mon Sep 17 00:00:00 2001 From: Tilman Sauerbeck Date: Wed, 5 May 2010 19:27:55 +0200 Subject: Get libarchive LDFLAGS for static linking from pkg-config. --- Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 36f11f46..6c68f2de 100644 --- a/Makefile +++ b/Makefile @@ -32,7 +32,9 @@ CXXFLAGS += -DNDEBUG CXXFLAGS += -O2 -Wall -pedantic -D_GNU_SOURCE -DVERSION=\"$(VERSION)\" \ -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -LDFLAGS += -static -larchive -lz +LIBARCHIVELIBS := $(shell pkg-config --libs --static libarchive) + +LDFLAGS += -static $(LIBARCHIVELIBS) OBJECTS = main.o pkgutil.o pkgadd.o pkgrm.o pkginfo.o -- cgit v1.2.3