-# $PostgreSQL: pgsql/contrib/earthdistance/Makefile,v 1.19 2007/11/10 23:59:50 momjian Exp $
+# $PostgreSQL: pgsql/contrib/earthdistance/Makefile,v 1.20 2010/07/05 23:15:55 tgl Exp $
MODULES = earthdistance
DATA_built = earthdistance.sql
DATA = uninstall_earthdistance.sql
REGRESS = earthdistance
-SHLIB_LINK += $(filter -lm, $(LIBS))
+LDFLAGS_SL += $(filter -lm, $(LIBS))
ifdef USE_PGXS
PG_CONFIG = pg_config
-# $PostgreSQL: pgsql/contrib/spi/Makefile,v 1.28 2007/12/03 04:22:54 tgl Exp $
+# $PostgreSQL: pgsql/contrib/spi/Makefile,v 1.29 2010/07/05 23:15:56 tgl Exp $
MODULES = autoinc insert_username moddatetime refint timetravel
DATA_built = $(addsuffix .sql, $(MODULES))
# comment out if you want a quieter refint package for other uses
PG_CPPFLAGS = -DREFINT_VERBOSE
+LDFLAGS_SL += -L$(top_builddir)/src/port -lpgport
+
ifdef USE_PGXS
PG_CONFIG = pg_config
PGXS := $(shell $(PG_CONFIG) --pgxs)
include $(top_builddir)/src/Makefile.global
include $(top_srcdir)/contrib/contrib-global.mk
endif
-
-SHLIB_LINK += -L$(top_builddir)/src/port -lpgport
-# $PostgreSQL: pgsql/contrib/tablefunc/Makefile,v 1.9 2007/11/10 23:59:51 momjian Exp $
+# $PostgreSQL: pgsql/contrib/tablefunc/Makefile,v 1.10 2010/07/05 23:15:56 tgl Exp $
MODULES = tablefunc
DATA_built = tablefunc.sql
DATA = uninstall_tablefunc.sql
REGRESS = tablefunc
-SHLIB_LINK += $(filter -lm, $(LIBS))
+LDFLAGS_SL += $(filter -lm, $(LIBS))
ifdef USE_PGXS
PG_CONFIG = pg_config
# Rule for building a shared library from a single .o file
%$(DLSUFFIX): %.o %.exp
- $(CC) $(CFLAGS) $(LDFLAGS) $(LDFLAGS_SL) -o $@ $*.o -Wl,-bE:$*.exp $(SHLIB_LINK)
+ $(CC) $(CFLAGS) $(LDFLAGS) $(LDFLAGS_SL) -o $@ $*.o -Wl,-bE:$*.exp $(BE_DLLLIBS)
-# $PostgreSQL: pgsql/src/makefiles/Makefile.cygwin,v 1.14 2010/07/05 18:54:38 tgl Exp $
+# $PostgreSQL: pgsql/src/makefiles/Makefile.cygwin,v 1.15 2010/07/05 23:15:56 tgl Exp $
DLLTOOL= dlltool
DLLWRAP= dllwrap
ifdef PGXS
# Rule for building a shared library from a single .o file
%.dll: %.o
$(DLLTOOL) --export-all --output-def $*.def $<
- $(DLLWRAP) -o $@ --def $*.def $< $(SHLIB_LINK)
+ $(DLLWRAP) -o $@ --def $*.def $< $(LDFLAGS) $(LDFLAGS_SL) $(BE_DLLLIBS)
rm -f $*.def
# Rule for building a shared library from a single .o file
%.so: %.o
- $(CC) $(CFLAGS) $(LDFLAGS) $(LDFLAGS_SL) -bundle -o $@ $< $(BE_DLLLIBS)
+ $(CC) $(CFLAGS) $(LDFLAGS) $(LDFLAGS_SL) -bundle $(BE_DLLLIBS) -o $@ $<
-# $PostgreSQL: pgsql/src/makefiles/Makefile.win32,v 1.16 2010/07/05 18:54:38 tgl Exp $
+# $PostgreSQL: pgsql/src/makefiles/Makefile.win32,v 1.17 2010/07/05 23:15:56 tgl Exp $
# Use replacement include files for those missing on Win32
override CPPFLAGS+="-I$(top_srcdir)/src/include/port/win32"
# Rule for building a shared library from a single .o file
%.dll: %.o
$(DLLTOOL) --export-all --output-def $*.def $<
- $(DLLWRAP) -o $@ --def $*.def $< $(SHLIB_LINK)
+ $(DLLWRAP) -o $@ --def $*.def $< $(LDFLAGS) $(LDFLAGS_SL) $(BE_DLLLIBS)
rm -f $*.def