mirror of
https://git.postgresql.org/git/postgresql.git
synced 2025-02-17 19:30:00 +08:00
The attached patch enables the contrib subtree to build cleanly under
Cygwin with the possible exception of mSQL-interface. Since I don't have mSQL installed, I skipped this tool. Except for dealing with a missing getopt.h (oid2name) and HUGE (seg), the bulk of the patch uses the standard PostgreSQL approach to deal with Windows DLL issues. I tested the build aspect of this patch under Cygwin and Linux without any ill affects. Note that I did not actually attempt to test the code for functionality. The procedure to apply the patch is as follows: $ # save the attachment as /tmp/contrib.patch $ # change directory to the top of the PostgreSQL source tree $ patch -p0 </tmp/contrib.patch Jason
This commit is contained in:
parent
22dc12b8c3
commit
558fae16e3
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/array/Attic/Makefile,v 1.14 2001/02/20 19:20:26 petere Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/array/Attic/Makefile,v 1.15 2001/06/18 21:38:01 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/array
|
||||
@ -11,6 +11,7 @@ SONAME := $(NAME)$(DLSUFFIX)
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override CFLAGS += $(CFLAGS_SL)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
all: $(SONAME) $(NAME).sql
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/cube/Makefile,v 1.3 2001/02/20 19:20:27 petere Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/cube/Makefile,v 1.4 2001/06/18 21:38:01 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/cube
|
||||
@ -15,6 +15,7 @@ SO_MAJOR_VERSION= 1
|
||||
SO_MINOR_VERSION= 0
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
OBJS= cube.o cubeparse.o cubescan.o buffer.o
|
||||
|
||||
|
@ -12,6 +12,7 @@ override CFLAGS += -I$(srcdir)
|
||||
override CFLAGS += -I$(include_srcdir)
|
||||
override CFLAGS += -I$(libpq_srcdir)
|
||||
override CFLAGS += $(CFLAGS_SL)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
OBJS = $(NAME).o
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/earthdistance/Makefile,v 1.9 2001/05/30 12:58:45 momjian Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/earthdistance/Makefile,v 1.10 2001/06/18 21:38:01 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/earthdistance
|
||||
@ -11,6 +11,7 @@ SONAME := $(NAME)$(DLSUFFIX)
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override CFLAGS += $(CFLAGS_SL)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
all: $(SONAME) $(NAME).sql
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/fulltextindex/Attic/Makefile,v 1.9 2001/02/20 19:20:27 petere Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/fulltextindex/Attic/Makefile,v 1.10 2001/06/18 21:38:01 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/fulltextindex
|
||||
@ -11,6 +11,7 @@ SONAME := $(NAME)$(DLSUFFIX)
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override CFLAGS += $(CFLAGS_SL)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
all: $(SONAME) $(NAME).sql
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
# $Header: /cvsroot/pgsql/contrib/intarray/Makefile,v 1.6 2001/05/31 19:25:27 tgl Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/intarray/Makefile,v 1.7 2001/06/18 21:38:01 momjian Exp $
|
||||
|
||||
subdir = contrib/intarray
|
||||
top_builddir = ../..
|
||||
@ -13,6 +13,7 @@ SO_MAJOR_VERSION= 1
|
||||
SO_MINOR_VERSION= 0
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
OBJS= _int.o
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/isbn_issn/Attic/Makefile,v 1.9 2001/02/20 19:20:27 petere Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/isbn_issn/Attic/Makefile,v 1.10 2001/06/18 21:38:01 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/isbn_issn
|
||||
@ -11,6 +11,7 @@ SONAME := $(NAME)$(DLSUFFIX)
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override CFLAGS += $(CFLAGS_SL)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
all: $(SONAME) $(NAME).sql
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/lo/Makefile,v 1.9 2001/02/20 19:20:27 petere Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/lo/Makefile,v 1.10 2001/06/18 21:38:01 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/lo
|
||||
@ -14,6 +14,7 @@ MODS = $(NAME)$(DLSUFFIX)
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override CFLAGS += $(CFLAGS_SL)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
ifdef REFINT_VERBOSE
|
||||
override CPPFLAGS+= -DREFINT_VERBOSE
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/miscutil/Attic/Makefile,v 1.14 2001/02/20 19:20:27 petere Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/miscutil/Attic/Makefile,v 1.15 2001/06/18 21:38:01 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/miscutil
|
||||
@ -11,6 +11,7 @@ SONAME := $(NAME)$(DLSUFFIX)
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override CFLAGS += $(CFLAGS_SL)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
all: $(SONAME) $(NAME).sql
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/noupdate/Attic/Makefile,v 1.7 2001/02/20 19:20:27 petere Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/noupdate/Attic/Makefile,v 1.8 2001/06/18 21:38:02 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/noupdate
|
||||
@ -11,6 +11,7 @@ SONAME := $(NAME)$(DLSUFFIX)
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override CFLAGS += $(CFLAGS_SL)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
all: $(SONAME) $(NAME).sql
|
||||
|
||||
|
@ -9,6 +9,7 @@
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
#include <string.h>
|
||||
#include <getopt.h>
|
||||
|
||||
#include "libpq-fe.h"
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/pgcrypto/Makefile,v 1.3 2001/02/20 15:34:14 momjian Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/pgcrypto/Makefile,v 1.4 2001/06/18 21:38:02 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/pgcrypto
|
||||
@ -43,6 +43,7 @@ SO_MAJOR_VERSION = 0
|
||||
SO_MINOR_VERSION = 1
|
||||
|
||||
override CPPFLAGS += $(CRYPTO_CFLAGS) -I$(srcdir)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
all: all-lib $(NAME).sql
|
||||
|
||||
|
@ -16,6 +16,7 @@ SCRIPTS = InitRservTest
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override CFLAGS += $(CFLAGS_SL)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
|
||||
all: $(SQLS) $(TCLS) $(PERLS) $(SCRIPTS) $(SONAME)
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/seg/Makefile,v 1.3 2001/02/20 19:20:28 petere Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/seg/Makefile,v 1.4 2001/06/18 21:38:02 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/seg
|
||||
@ -15,6 +15,7 @@ SO_MAJOR_VERSION= 1
|
||||
SO_MINOR_VERSION= 0
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
OBJS= seg.o segparse.o segscan.o buffer.o
|
||||
|
||||
|
@ -11,6 +11,10 @@
|
||||
#include "postgres.h"
|
||||
#include "utils/elog.h"
|
||||
|
||||
#ifdef __CYGWIN__
|
||||
#define HUGE HUGE_VAL
|
||||
#endif /* __CYGWIN__ */
|
||||
|
||||
#undef yylex /* falure to redefine yylex will result in calling the */
|
||||
#define yylex seg_yylex /* wrong scanner when running inside postgres backend */
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/soundex/Attic/Makefile,v 1.9 2000/10/20 21:03:28 petere Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/soundex/Attic/Makefile,v 1.10 2001/06/18 21:38:02 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/soundex
|
||||
@ -11,6 +11,7 @@ SONAME := $(NAME)$(DLSUFFIX)
|
||||
|
||||
override CPPFLAGS += -I$(srcdir)
|
||||
override CFLAGS += $(CFLAGS_SL)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
all: $(SONAME) $(NAME).sql
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/string/Attic/Makefile,v 1.14 2001/02/20 19:20:28 petere Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/string/Attic/Makefile,v 1.15 2001/06/18 21:38:02 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/string
|
||||
@ -11,6 +11,7 @@ SONAME := $(NAME)$(DLSUFFIX)
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override CFLAGS += $(CFLAGS_SL)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
all: $(SONAME) $(NAME).sql
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# $Header: /cvsroot/pgsql/contrib/userlock/Attic/Makefile,v 1.14 2001/02/20 19:20:28 petere Exp $
|
||||
# $Header: /cvsroot/pgsql/contrib/userlock/Attic/Makefile,v 1.15 2001/06/18 21:38:02 momjian Exp $
|
||||
#
|
||||
|
||||
subdir = contrib/userlock
|
||||
@ -11,6 +11,7 @@ SONAME := $(NAME)$(DLSUFFIX)
|
||||
|
||||
override CPPFLAGS := -I$(srcdir) $(CPPFLAGS)
|
||||
override CFLAGS += $(CFLAGS_SL)
|
||||
override DLLLIBS := $(BE_DLLLIBS) $(DLLLIBS)
|
||||
|
||||
all: $(SONAME) $(NAME).sql
|
||||
|
||||
|
@ -12,7 +12,7 @@
|
||||
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: miscadmin.h,v 1.86 2001/06/13 21:44:41 tgl Exp $
|
||||
* $Id: miscadmin.h,v 1.87 2001/06/18 21:38:02 momjian Exp $
|
||||
*
|
||||
* NOTES
|
||||
* some of the information in this file should be moved to
|
||||
@ -115,7 +115,7 @@ extern int PostmasterMain(int argc, char *argv[]);
|
||||
extern bool Noversion;
|
||||
extern char *DataDir;
|
||||
|
||||
extern int MyProcPid;
|
||||
extern DLLIMPORT int MyProcPid;
|
||||
extern struct Port *MyProcPort;
|
||||
extern long MyCancelKey;
|
||||
|
||||
@ -126,7 +126,7 @@ extern char OutputFileName[];
|
||||
*
|
||||
* extern BackendId MyBackendId;
|
||||
*/
|
||||
extern Oid MyDatabaseId;
|
||||
extern DLLIMPORT Oid MyDatabaseId;
|
||||
|
||||
extern bool IsUnderPostmaster;
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: shmem.h,v 1.28 2001/03/22 04:01:09 momjian Exp $
|
||||
* $Id: shmem.h,v 1.29 2001/06/18 21:38:02 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -36,7 +36,7 @@ typedef unsigned long SHMEM_OFFSET;
|
||||
* The macros in this header file can only cope with offsets into this
|
||||
* shared memory region!
|
||||
*/
|
||||
extern SHMEM_OFFSET ShmemBase;
|
||||
extern DLLIMPORT SHMEM_OFFSET ShmemBase;
|
||||
|
||||
|
||||
/* coerce an offset into a pointer in this process's address space */
|
||||
|
@ -8,7 +8,7 @@
|
||||
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: tqual.h,v 1.30 2001/01/24 19:43:29 momjian Exp $
|
||||
* $Id: tqual.h,v 1.31 2001/06/18 21:38:02 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -36,7 +36,7 @@ typedef SnapshotData *Snapshot;
|
||||
|
||||
extern Snapshot SnapshotDirty;
|
||||
extern Snapshot QuerySnapshot;
|
||||
extern Snapshot SerializableSnapshot;
|
||||
extern DLLIMPORT Snapshot SerializableSnapshot;
|
||||
|
||||
extern bool ReferentialIntegritySnapshotOverride;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user