aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Makefile.global.in25
-rw-r--r--src/bin/pgevent/Makefile2
-rw-r--r--src/interfaces/libpq/Makefile4
-rw-r--r--src/makefiles/Makefile.win3223
4 files changed, 28 insertions, 26 deletions
diff --git a/src/Makefile.global.in b/src/Makefile.global.in
index 6789e182f46..58f2d83074f 100644
--- a/src/Makefile.global.in
+++ b/src/Makefile.global.in
@@ -1,5 +1,5 @@
# -*-makefile-*-
-# $PostgreSQL: pgsql/src/Makefile.global.in,v 1.247 2008/11/26 11:26:54 petere Exp $
+# $PostgreSQL: pgsql/src/Makefile.global.in,v 1.248 2008/12/07 08:36:22 petere Exp $
#------------------------------------------------------------------------------
# All PostgreSQL makefiles include this file and use the variables it sets,
@@ -226,6 +226,9 @@ DTRACEFLAGS = @DTRACEFLAGS@
# Linking
+AR = @AR@
+DLLTOOL = @DLLTOOL@
+DLLWRAP = @DLLWRAP@
LIBS = @LIBS@
LDAP_LIBS_FE = @LDAP_LIBS_FE@
LDAP_LIBS_BE = @LDAP_LIBS_BE@
@@ -238,6 +241,7 @@ LDFLAGS_SL = @LDFLAGS_SL@
LDREL = -r
LDOUT = -o
RANLIB = @RANLIB@
+WINDRES = @WINDRES@
X = @EXEEXT@
# Perl
@@ -466,25 +470,6 @@ TAS = @TAS@
%.bz2: %
$(BZIP2) -f $<
-ifeq ($(PORTNAME),win32)
-# Build rules to add versioninfo resources to win32 binaries
-WIN32RES += win32ver.o
-ifeq ($(PGFILESHLIB),1)
-PGFTYPE=VFT_DLL
-else
-PGFTYPE=VFT_APP
-endif
-ifneq (,$(PGAPPICON))
-PGICOSTR=$(subst /,\/,IDI_ICON ICON \"$(top_builddir)/src/port/$(PGAPPICON).ico\")
-endif
-win32ver.rc: $(top_builddir)/src/port/win32ver.rc
- sed -e 's;FILEDESC;$(PGFILEDESC);' -e 's;VFT_APP;$(PGFTYPE);' -e 's;_ICO_;$(PGICOSTR);' -e 's;\(VERSION.*\),0 *$$;\1,'`date '+%y%j' | sed 's/^0*//'`';' $(top_builddir)/src/port/win32ver.rc > win32ver.rc
-win32ver.o: $(top_builddir)/src/port/win32ver.rc
- sed -e 's;FILEDESC;$(PGFILEDESC);' -e 's;VFT_APP;$(PGFTYPE);' -e 's;_ICO_;$(PGICOSTR);' -e 's;\(VERSION.*\),0 *$$;\1,'`date '+%y%j' | sed 's/^0*//'`';' $(top_builddir)/src/port/win32ver.rc > win32ver.rc
- windres -i win32ver.rc -o win32ver.o --include-dir=$(top_builddir)/src/include
- rm -f win32ver.rc
-endif
-
ifndef PGXS
# Remake Makefile.global from Makefile.global.in if the latter
diff --git a/src/bin/pgevent/Makefile b/src/bin/pgevent/Makefile
index 69469f8fc99..d08eaa22507 100644
--- a/src/bin/pgevent/Makefile
+++ b/src/bin/pgevent/Makefile
@@ -25,7 +25,7 @@ pgevent.dll: $(OBJS) pgevent.def
$(DLLWRAP) --def pgevent.def -o $(NAME) $(OBJS)
pgmsgevent.o: pgmsgevent.rc win32ver.rc
- windres pgmsgevent.rc -o pgmsgevent.o --include-dir=$(top_builddir)/src/include
+ $(WINDRES) pgmsgevent.rc -o pgmsgevent.o --include-dir=$(top_builddir)/src/include
all-lib: $(NAME)
diff --git a/src/interfaces/libpq/Makefile b/src/interfaces/libpq/Makefile
index 5a899d27894..6f62ef1dc2b 100644
--- a/src/interfaces/libpq/Makefile
+++ b/src/interfaces/libpq/Makefile
@@ -5,7 +5,7 @@
# Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
-# $PostgreSQL: pgsql/src/interfaces/libpq/Makefile,v 1.170 2008/12/02 10:39:30 mha Exp $
+# $PostgreSQL: pgsql/src/interfaces/libpq/Makefile,v 1.171 2008/12/07 08:36:22 petere Exp $
#
#-------------------------------------------------------------------------
@@ -44,7 +44,7 @@ ifeq ($(PORTNAME), win32)
OBJS += win32.o pgsleep.o libpqrc.o
libpqrc.o: libpq.rc
- windres -i $< -o $@
+ $(WINDRES) -i $< -o $@
ifeq ($(enable_thread_safety), yes)
OBJS += pthread-win32.o
diff --git a/src/makefiles/Makefile.win32 b/src/makefiles/Makefile.win32
index f42ae8e41a8..75619c7e466 100644
--- a/src/makefiles/Makefile.win32
+++ b/src/makefiles/Makefile.win32
@@ -1,10 +1,8 @@
-# $PostgreSQL: pgsql/src/makefiles/Makefile.win32,v 1.11 2007/08/21 13:32:33 mha Exp $
+# $PostgreSQL: pgsql/src/makefiles/Makefile.win32,v 1.12 2008/12/07 08:36:22 petere Exp $
# Use replacement include files for those missing on Win32
override CPPFLAGS+="-I$(top_srcdir)/src/include/port/win32"
-DLLTOOL= dlltool
-DLLWRAP= dllwrap
ifdef PGXS
BE_DLLLIBS= -L$(libdir) -lpostgres
else
@@ -51,3 +49,22 @@ endif
ifndef MAKE_DLL
MAKE_DLL = true
endif
+
+
+# Build rules to add versioninfo resources to win32 binaries
+
+WIN32RES += win32ver.o
+ifeq ($(PGFILESHLIB),1)
+PGFTYPE = VFT_DLL
+else
+PGFTYPE = VFT_APP
+endif
+ifneq (,$(PGAPPICON))
+PGICOSTR = $(subst /,\/,IDI_ICON ICON \"$(top_builddir)/src/port/$(PGAPPICON).ico\")
+endif
+
+win32ver.rc: $(top_srcdir)/src/port/win32ver.rc
+ sed -e 's;FILEDESC;$(PGFILEDESC);' -e 's;VFT_APP;$(PGFTYPE);' -e 's;_ICO_;$(PGICOSTR);' -e 's;\(VERSION.*\),0 *$$;\1,'`date '+%y%j' | sed 's/^0*//'`';' $< >$@
+
+win32ver.o: win32ver.rc
+ $(WINDRES) -i $< -o $@ --include-dir=$(top_builddir)/src/include