aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrew Dunstan <andrew@dunslane.net>2014-02-01 15:16:06 -0500
committerAndrew Dunstan <andrew@dunslane.net>2014-02-01 15:16:06 -0500
commit1e9876c3b69491906cfcd542ebc8c79e91df6904 (patch)
tree616932f6c5a4530d5fb94289fb4142b434cca903 /src
parent5d807a74bf66ba9fb4f55e49e7c601b0b9804123 (diff)
downloadpostgresql-1e9876c3b69491906cfcd542ebc8c79e91df6904.tar.gz
postgresql-1e9876c3b69491906cfcd542ebc8c79e91df6904.zip
Copy the libpq DLL to the bin directory on Mingw and Cygwin.
This has long been done by the MSVC build system, and has caused confusion in the past when programs like psql have failed to start because they can't find the DLL. If it's in the same directory as it now will be they will find it. Backpatch to all live branches.
Diffstat (limited to 'src')
-rw-r--r--src/interfaces/libpq/Makefile9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/interfaces/libpq/Makefile b/src/interfaces/libpq/Makefile
index 7ed79c4f27c..b676b58118a 100644
--- a/src/interfaces/libpq/Makefile
+++ b/src/interfaces/libpq/Makefile
@@ -121,12 +121,18 @@ install: all installdirs install-lib
$(INSTALL_DATA) $(srcdir)/libpq-int.h '$(DESTDIR)$(includedir_internal)'
$(INSTALL_DATA) $(srcdir)/pqexpbuffer.h '$(DESTDIR)$(includedir_internal)'
$(INSTALL_DATA) $(srcdir)/pg_service.conf.sample '$(DESTDIR)$(datadir)/pg_service.conf.sample'
+ifneq (,$findstring($(PORTNAME), win32 cygwin))
+ $(INSTALL_DATA) $(shlib) '$(DESTDIR)$(bindir)/$(shlib)'
+endif
installcheck:
$(MAKE) -C test $@
installdirs: installdirs-lib
$(MKDIR_P) '$(DESTDIR)$(includedir)' '$(DESTDIR)$(includedir_internal)' '$(DESTDIR)$(datadir)'
+ifneq (,$findstring($(PORTNAME), win32 cygwin))
+ $(MKDIR_P) '$(DESTDIR)$(bindir)'
+endif
uninstall: uninstall-lib
rm -f '$(DESTDIR)$(includedir)/libpq-fe.h'
@@ -134,6 +140,9 @@ uninstall: uninstall-lib
rm -f '$(DESTDIR)$(includedir_internal)/libpq-int.h'
rm -f '$(DESTDIR)$(includedir_internal)/pqexpbuffer.h'
rm -f '$(DESTDIR)$(datadir)/pg_service.conf.sample'
+ifneq (,$findstring($(PORTNAME), win32 cygwin))
+ rm -f '$(DESTDIR)$(bindir)/$(shlib)'
+endif
clean distclean: clean-lib
$(MAKE) -C test $@