diff --git a/ChangeLog b/ChangeLog index 5d74f7c3..415d2917 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2018-08-14 Jay Berkenbilt + + * For the mingw builds, change the name of the DLL import library + from libqpdf.a to libqpdf.dll.a to avoid confusing it with a + static library. This potentially clears the way for supporting a + static library in the future, though presently, the qpdf Windows + build only builds the DLL and executables. Fixes #225. + 2018-08-13 Jay Berkenbilt * Add new class QPDFSystemError, derived from std::runtime_error, diff --git a/make/installwin.mk b/make/installwin.mk index f4bc411e..960cc51f 100644 --- a/make/installwin.mk +++ b/make/installwin.mk @@ -1,4 +1,5 @@ DEST=$(INSTALL_DIR)/$(PACKAGE_TARNAME)-$(PACKAGE_VERSION) +IMPORT_LIB_NAME := $(call libname,qpdf) installwin: all $(RM) -r $(INSTALL_DIR) mkdir $(INSTALL_DIR) @@ -8,7 +9,7 @@ installwin: all mkdir $(DEST)/include mkdir $(DEST)/include/qpdf mkdir $(DEST)/doc - cp libqpdf/$(OUTPUT_DIR)/$(STATIC_LIB_NAME) $(DEST)/lib + cp libqpdf/$(OUTPUT_DIR)/$(IMPORT_LIB_NAME) $(DEST)/lib cp libqpdf/$(OUTPUT_DIR)/qpdf*.dll $(DEST)/bin perl copy_dlls libqpdf/$(OUTPUT_DIR)/qpdf*.dll $(DEST)/bin $(OBJDUMP) $(WINDOWS_WORDSIZE) cp qpdf/$(OUTPUT_DIR)/qpdf.exe $(DEST)/bin diff --git a/make/mingw.mk b/make/mingw.mk index 00119d1a..fbfbee9e 100644 --- a/make/mingw.mk +++ b/make/mingw.mk @@ -5,7 +5,7 @@ LOBJ=o # Usage: $(call libname,base) define libname -lib$(1).a +lib$(1).dll.a endef # Usage: $(call binname,base) @@ -62,8 +62,8 @@ endef # 1 2 3 4 5 6 7 # Usage: $(call makelib,objs,library,ldflags,libs,current,revision,age) define makelib - $(DLLTOOL) -l $(2) -D $$(basename `echo $(2) | sed -e 's,/lib\(.*\).a,/\1,'`$(shell expr $(5) - $(7)).dll) $(1); \ - $(CXX) -shared -o `echo $(2) | sed -e 's,/lib\(.*\).a,/\1,'`$(shell expr $(5) - $(7)).dll \ + $(DLLTOOL) -l $(2) -D $$(basename `echo $(2) | sed -e 's,/lib\(.*\).dll.a,/\1,'`$(shell expr $(5) - $(7)).dll) $(1); \ + $(CXX) -shared -o `echo $(2) | sed -e 's,/lib\(.*\).dll.a,/\1,'`$(shell expr $(5) - $(7)).dll \ $(1) $(3) $(4) endef @@ -76,7 +76,6 @@ endef # Install target INSTALL_DIR = install-mingw$(WINDOWS_WORDSIZE) -STATIC_LIB_NAME = libqpdf.a include make/installwin.mk install: installwin $(STRIP) $(DEST)/bin/*.exe diff --git a/make/msvc.mk b/make/msvc.mk index 3e061091..4af234c3 100644 --- a/make/msvc.mk +++ b/make/msvc.mk @@ -92,6 +92,5 @@ endef # Install target INSTALL_DIR = install-msvc$(WINDOWS_WORDSIZE) -STATIC_LIB_NAME = qpdf.lib include make/installwin.mk install: installwin