Skip to content

Commit 0d3b8e9

Browse files
committed
Allow win32/cygwin link against the first matching library symbol rather
than erroring out. This is the Unix behavior.
1 parent 3a372d6 commit 0d3b8e9

File tree

3 files changed

+10
-7
lines changed

3 files changed

+10
-7
lines changed

src/bin/pg_dump/Makefile

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
66
# Portions Copyright (c) 1994, Regents of the University of California
77
#
8-
# $PostgreSQL: pgsql/src/bin/pg_dump/Makefile,v 1.57 2004/10/07 13:45:48 momjian Exp $
8+
# $PostgreSQL: pgsql/src/bin/pg_dump/Makefile,v 1.58 2004/11/08 05:23:23 momjian Exp $
99
#
1010
#-------------------------------------------------------------------------
1111

@@ -22,12 +22,6 @@ OBJS= pg_backup_archiver.o pg_backup_db.o pg_backup_custom.o \
2222

2323
EXTRA_OBJS = $(top_builddir)/src/backend/parser/keywords.o
2424

25-
# Not sure why MinGW needs this but it prevents a link failure
26-
# of duplicate definitions for pg_tolower(). 2004-10-06
27-
ifeq ($(PORTNAME), win32)
28-
EXTRA_OBJS += $(top_builddir)/src/port/exec.o
29-
endif
30-
3125
all: submake-libpq submake-libpgport submake-backend pg_dump pg_restore pg_dumpall
3226

3327
pg_dump: pg_dump.o common.o pg_dump_sort.o $(OBJS) $(libpq_builddir)/libpq.a

src/template/cygwin

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,6 @@
11
SRCH_LIB="/usr/local/lib"
2+
3+
# This is required to link pg_dump because it finds pg_toupper() in
4+
# libpq and pgport
5+
LDFLAGS="-Wl,--allow-multiple-definition"
6+

src/template/win32

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# This is required to link pg_dump because it finds pg_toupper() in
2+
# libpq and pgport
3+
LDFLAGS="-Wl,--allow-multiple-definition"
4+

0 commit comments

Comments
 (0)