pdftk-1.44-Makefile.Base-DEST-LDFLAGS.patch 1.34 KB
Newer Older
1 2 3 4 5
diff --git a/pdftk/Makefile.Base b/pdftk/Makefile.Base
index 0bedd04..36a439e 100644
--- a/pdftk/Makefile.Base
+++ b/pdftk/Makefile.Base
@@ -35,22 +35,24 @@ javalib :
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
 	$(MAKE) -f Makefile -iC $(JAVALIBPATH) all
 
 attachments.o : attachments.cc attachments.h pdftk.h $(JAVALIB)
-	$(CXX) $(CPPFLAGS) $(CXXFLAGS) -I$(JAVALIBPATH) attachments.cc -c
+	$(CXX) $(CPPFLAGS) $(LDFLAGS) $(CXXFLAGS) -I$(JAVALIBPATH) attachments.cc -c
 
 report.o : report.cc report.h pdftk.h $(JAVALIB)
-	$(CXX) $(CPPFLAGS) $(CXXFLAGS) -I$(JAVALIBPATH) report.cc -c
+	$(CXX) $(CPPFLAGS) $(LDFLAGS) $(CXXFLAGS) -I$(JAVALIBPATH) report.cc -c
 
 pdftk.o : pdftk.cc pdftk.h attachments.h report.h $(JAVALIB) $(GCJ_LOCAL_LIB_FULL)
-	$(CXX) $(CPPFLAGS) $(CXXFLAGS) -I$(JAVALIBPATH) pdftk.cc -c
+	$(CXX) $(CPPFLAGS) $(LDFLAGS) $(CXXFLAGS) -I$(JAVALIBPATH) pdftk.cc -c
 
 pdftk : pdftk.o attachments.o report.o $(JAVALIB) $(GCJ_LOCAL_LIB_FULL)
-	$(CXX) $(CXXFLAGS) attachments.o report.o pdftk.o $(JAVALIB) $(GCJ_LOCAL_LIB_FULL) $(LDLIBS) -o pdftk
+	$(CXX) $(CXXFLAGS) $(LDFLAGS) attachments.o report.o pdftk.o $(JAVALIB) $(GCJ_LOCAL_LIB_FULL) $(LDLIBS) -o pdftk
 
 install:
-	/usr/bin/install pdftk /usr/local/bin 
+	mkdir -p ${DEST}/bin
27
+	install pdftk ${DEST}/bin
28 29 30 31 32 33 34 35
 
 uninstall:
-	$(RM) $(RMFLAGS) /usr/local/bin/pdftk
+	$(RM) $(RMFLAGS) ${DEST}/pdftk
+	rmdir ${DEST}
 
 clean:
 	$(RM) $(RMFLAGS) *.o