Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit bdf0054

Browse files
committed
Make sure LDFLAGS come before LIBS when linking contrib programs.
Solaris, at least, seems to be sensitive to the relative order of -L and -l switches, so this is needed. Per buildfarm results.
1 parent f9e9da6 commit bdf0054

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/makefiles/pgxs.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# PGXS: PostgreSQL extensions makefile
22

3-
# $PostgreSQL: pgsql/src/makefiles/pgxs.mk,v 1.20 2010/07/05 18:54:38 tgl Exp $
3+
# $PostgreSQL: pgsql/src/makefiles/pgxs.mk,v 1.21 2010/07/05 23:30:50 tgl Exp $
44

55
# This file contains generic rules to build many kinds of simple
66
# extension modules. You only need to set a few variables and include
@@ -286,5 +286,5 @@ endif
286286

287287
ifdef PROGRAM
288288
$(PROGRAM): $(OBJS)
289-
$(CC) $(CFLAGS) $(OBJS) $(PG_LIBS) $(LIBS) $(LDFLAGS) $(LDFLAGS_EX) -o $@
289+
$(CC) $(CFLAGS) $(OBJS) $(LDFLAGS) $(LDFLAGS_EX) $(PG_LIBS) $(LIBS) -o $@
290290
endif

0 commit comments

Comments
 (0)