Skip to content

Commit 6fabec2

Browse files
committed
Fix compilation on Cygwin.
1 parent cef0652 commit 6fabec2

File tree

7 files changed

+12
-13
lines changed

7 files changed

+12
-13
lines changed

src/include/port/cygwin.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
/* $Header: /cvsroot/pgsql/src/include/port/cygwin.h,v 1.2 2003/04/18 01:03:42 momjian Exp $ */
2-
3-
#include <port/win32defs.h>
1+
/* $Header: /cvsroot/pgsql/src/include/port/cygwin.h,v 1.3 2003/05/22 17:20:28 petere Exp $ */
42

53
#define HAS_TEST_AND_SET
64
typedef unsigned char slock_t;

src/include/utils/elog.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
88
* Portions Copyright (c) 1994, Regents of the University of California
99
*
10-
* $Id: elog.h,v 1.42 2003/05/15 16:35:29 momjian Exp $
10+
* $Id: elog.h,v 1.43 2003/05/22 17:20:43 petere Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -264,7 +264,7 @@ typedef struct ErrorContextCallback
264264
void *arg;
265265
} ErrorContextCallback;
266266

267-
extern ErrorContextCallback *error_context_stack;
267+
extern DLLIMPORT ErrorContextCallback *error_context_stack;
268268

269269

270270
/* GUC-configurable parameters */

src/interfaces/ecpg/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,15 @@ include $(top_builddir)/src/Makefile.global
44

55
all install installdirs uninstall dep depend distprep:
66
$(MAKE) -C include $@
7-
$(MAKE) -C ecpglib $@
87
$(MAKE) -C pgtypeslib $@
8+
$(MAKE) -C ecpglib $@
99
$(MAKE) -C compatlib $@
1010
$(MAKE) -C preproc $@
1111

1212
clean distclean maintainer-clean:
1313
-$(MAKE) -C include $@
14-
-$(MAKE) -C ecpglib $@
1514
-$(MAKE) -C pgtypeslib $@
15+
-$(MAKE) -C ecpglib $@
1616
-$(MAKE) -C compatlib $@
1717
-$(MAKE) -C preproc $@
1818
-$(MAKE) -C test clean

src/interfaces/ecpg/compatlib/Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
#
55
# Copyright (c) 1994, Regents of the University of California
66
#
7-
# $Header: /cvsroot/pgsql/src/interfaces/ecpg/compatlib/Makefile,v 1.3 2003/04/16 05:23:55 tgl Exp $
7+
# $Header: /cvsroot/pgsql/src/interfaces/ecpg/compatlib/Makefile,v 1.4 2003/05/22 17:20:44 petere Exp $
88
#
99
#-------------------------------------------------------------------------
1010

@@ -17,6 +17,7 @@ SO_MAJOR_VERSION= 1
1717
SO_MINOR_VERSION= 0.0
1818

1919
override CPPFLAGS := -I$(top_srcdir)/src/interfaces/ecpg/include -I$(top_srcdir)/src/include/utils $(CPPFLAGS)
20+
SHLIB_LINK = -L../pgtypeslib -lpgtypes
2021

2122
OBJS= informix.o
2223

src/interfaces/ecpg/compatlib/informix.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ deccopy(Numeric *src, Numeric *target)
5555
}
5656

5757
static char *
58-
strndup(char *str, int len)
58+
strndup(const char *str, size_t len)
5959
{
6060
int real_len = strlen(str);
6161
int use_len = (real_len > len) ? len : real_len;

src/interfaces/ecpg/ecpglib/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
#
55
# Copyright (c) 1994, Regents of the University of California
66
#
7-
# $Header: /cvsroot/pgsql/src/interfaces/ecpg/ecpglib/Makefile,v 1.2 2003/04/08 17:09:01 tgl Exp $
7+
# $Header: /cvsroot/pgsql/src/interfaces/ecpg/ecpglib/Makefile,v 1.3 2003/05/22 17:20:44 petere Exp $
88
#
99
#-------------------------------------------------------------------------
1010

@@ -21,7 +21,7 @@ override CPPFLAGS := -I$(top_srcdir)/src/interfaces/ecpg/include -I$(libpq_srcdi
2121
OBJS= execute.o typename.o descriptor.o data.o error.o prepare.o memory.o \
2222
connect.o misc.o
2323

24-
SHLIB_LINK= $(libpq)
24+
SHLIB_LINK = -L../pgtypeslib -lpgtypes $(libpq)
2525

2626
all: all-lib
2727

src/makefiles/Makefile.cygwin

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $Header: /cvsroot/pgsql/src/makefiles/Makefile.cygwin,v 1.1 2003/03/21 17:18:34 petere Exp $
1+
# $Header: /cvsroot/pgsql/src/makefiles/Makefile.cygwin,v 1.2 2003/05/22 17:20:44 petere Exp $
22
DLLTOOL= dlltool
33
DLLWRAP= dllwrap
44
BE_DLLLIBS= -L$(top_builddir)/src/backend -lpostgres
@@ -23,7 +23,7 @@ override CPPFLAGS+= -DBUILDING_DLL
2323
endif
2424
endif
2525

26-
ifneq (,$(findstring ecpg/lib,$(subdir)))
26+
ifneq (,$(findstring ecpg/ecpglib,$(subdir)))
2727
override CPPFLAGS+= -DBUILDING_DLL
2828
endif
2929

0 commit comments

Comments
 (0)