Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit9c0afea

Browse files
author
Bryan Henderson
committed
More stuff to make it compile on various ports.
1 parenta38365e commit9c0afea

File tree

15 files changed

+112
-71
lines changed

15 files changed

+112
-71
lines changed

‎src/Makefile.global

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
#
88
#
99
# IDENTIFICATION
10-
# $Header: /cvsroot/pgsql/src/Attic/Makefile.global,v 1.74 1996/11/23 09:50:34 bryanh Exp $
10+
# $Header: /cvsroot/pgsql/src/Attic/Makefile.global,v 1.75 1996/11/27 08:13:44 bryanh Exp $
1111
#
1212
# NOTES
1313
# Essentially all Postgres make files include this file and use the
@@ -606,7 +606,7 @@ ifeq ($(PORTNAME), sparc_solaris)
606606
# cc won't work!
607607
CC= gcc
608608

609-
LDADD_BE= -ll -ldl
609+
LDADD_BE= -lsocket -lnsl -ll -ldl
610610

611611
# RANLIB is not used on solaris
612612
RANLIB= touch

‎src/backend/libpq/hba.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/libpq/hba.c,v 1.12 1996/11/16 08:09:16 bryanh Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/libpq/hba.c,v 1.13 1996/11/27 08:15:16 bryanh Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -27,6 +27,7 @@
2727
#include<libpq/libpq.h>
2828
#include<libpq/pqcomm.h>
2929
#include<libpq/hba.h>
30+
#include<port-protos.h>/* For inet_aton() */
3031

3132

3233
#defineCONF_FILE "pg_hba.conf"

‎src/backend/port/sparc_solaris/port-protos.h

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,16 @@
66
*
77
* Copyright (c) 1994, Regents of the University of California
88
*
9-
* $Id: port-protos.h,v 1.1.1.1 1996/07/09 06:21:45 scrappy Exp $
9+
* $Id: port-protos.h,v 1.2 1996/11/27 08:15:23 bryanh Exp $
1010
*
1111
*-------------------------------------------------------------------------
1212
*/
1313
#ifndefPORT_PROTOS_H
1414
#definePORT_PROTOS_H
1515

1616
#include<dlfcn.h>
17+
18+
#include"config.h"/* For MAXPATHLEN */
1719
#include"fmgr.h"/* for func_ptr */
1820
#include"utils/dynamic_loader.h"
1921

@@ -35,4 +37,11 @@
3537
externlongrandom(void);
3638
externvoidsrandom(intseed);
3739

40+
/* inet_aton.c in backend/port directory */
41+
externintinet_aton(constchar*cp,structin_addr*addr);
42+
43+
/* In system library, but can't find prototype in system library .h files */
44+
externintgethostname(char*name,intnamelen);
45+
46+
3847
#endif/* PORT_PROTOS_H */

‎src/backend/port/sparc_solaris/port.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,17 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/port/sparc_solaris/Attic/port.c,v 1.2 1996/11/06 06:48:35 scrappy Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/port/sparc_solaris/Attic/port.c,v 1.3 1996/11/27 08:15:25 bryanh Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
1414
#include<math.h>/* for pow() prototype */
1515
#include<stdlib.h>
1616

1717
#include<errno.h>
18+
19+
#include"postgres.h"
20+
#include"port-protos.h"
1821
#include"rusagestub.h"
1922

2023
long

‎src/backend/port/ultrix4/port-protos.h

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,20 @@
66
*
77
* Copyright (c) 1994, Regents of the University of California
88
*
9-
* $Id: port-protos.h,v 1.2 1996/11/26 03:18:58 bryanh Exp $
9+
* $Id: port-protos.h,v 1.3 1996/11/27 08:15:30 bryanh Exp $
1010
*
1111
*-------------------------------------------------------------------------
1212
*/
1313
#ifndefPORT_PORTOS_H
1414
#definePORT_PORTOS_H
1515

16+
/*
17+
* Externals in libc that need prototypes (or at least declarations)
18+
*/
19+
20+
externchar*ecvt(double,int,int*,int*);
21+
externchar*fcvt(double,int,int*,int*);
22+
1623
/* dynloader.c */
1724
/*
1825
* New dynamic loader.

‎src/backend/postmaster/postmaster.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
*
1111
*
1212
* IDENTIFICATION
13-
* $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.26 1996/11/24 04:07:00 bryanh Exp $
13+
* $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.27 1996/11/27 08:15:36 bryanh Exp $
1414
*
1515
* NOTES
1616
*
@@ -80,6 +80,7 @@
8080
#include"utils/mcxt.h"
8181
#include"storage/proc.h"
8282
#include"utils/elog.h"
83+
#include"port-protos.h"/* For gethostname() */
8384

8485
#if defined(DBX_VERSION)
8586
# defineFORK() (0)

‎src/backend/storage/ipc/shmem.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/storage/ipc/shmem.c,v 1.7 1996/11/2707:20:07 vadim Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/storage/ipc/shmem.c,v 1.8 1996/11/2708:15:44 bryanh Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -59,7 +59,7 @@
5959
*/
6060
#include<stdio.h>
6161
#include<string.h>
62-
#include<sys/ipc.h>
62+
6363
#include"postgres.h"
6464
#include"storage/ipc.h"
6565
#include"storage/shmem.h"

‎src/backend/utils/adt/numutils.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
*
1111
*
1212
* IDENTIFICATION
13-
* $Header: /cvsroot/pgsql/src/backend/utils/adt/numutils.c,v 1.6 1996/11/06 10:30:58 scrappy Exp $
13+
* $Header: /cvsroot/pgsql/src/backend/utils/adt/numutils.c,v 1.7 1996/11/27 08:15:54 bryanh Exp $
1414
*
1515
*-------------------------------------------------------------------------
1616
*/
@@ -24,6 +24,7 @@
2424
#else
2525
# include<string.h>
2626
#endif
27+
#include<port-protos.h>/* ecvt(), fcvt() */
2728

2829
int32
2930
pg_atoi(char*s,intsize,intc)

‎src/backend/utils/cache/relcache.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.5 1996/11/10 03:03:26 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.6 1996/11/27 08:16:01 bryanh Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -32,6 +32,7 @@
3232
#include<stdio.h>/* for sprintf() */
3333
#include<errno.h>
3434
#include<sys/file.h>
35+
#include<fcntl.h>
3536
#include<string.h>
3637

3738
#include"postgres.h"

‎src/backend/utils/fmgr/dfmgr.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/utils/fmgr/dfmgr.c,v 1.3 1996/11/24 04:44:14 bryanh Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/utils/fmgr/dfmgr.c,v 1.4 1996/11/27 08:16:07 bryanh Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -18,6 +18,7 @@
1818

1919
#include"postgres.h"
2020

21+
#include"config.h"/* for MAXPATHLEN */
2122
#include"fmgr.h"/* generated by Gen_fmgrtab.sh */
2223
#include"utils/dynamic_loader.h"
2324
#include"utils/elog.h"

‎src/bin/initdb/initdb.sh

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
#
2727
#
2828
# IDENTIFICATION
29-
# $Header: /cvsroot/pgsql/src/bin/initdb/Attic/initdb.sh,v 1.17 1996/11/26 08:12:39 bryanh Exp $
29+
# $Header: /cvsroot/pgsql/src/bin/initdb/Attic/initdb.sh,v 1.18 1996/11/27 08:16:16 bryanh Exp $
3030
#
3131
#-------------------------------------------------------------------------
3232

@@ -51,9 +51,11 @@ CMDNAME=`basename $0`
5151
# The 2>/dev/null is to swallow the "postconfig: not found" message if there
5252
# is no postconfig.
5353

54-
postconfig_result="$(sh -c postconfig2>/dev/null)"
54+
postconfig_result=`sh -c postconfig2>/dev/null`
5555
if [!-z$postconfig_result ];then
56-
export$postconfig_result
56+
set -a# Make the following variable assignment exported to environment
57+
eval$postconfig_result
58+
set +a# back to normal
5759
fi
5860

5961
# Set defaults:
@@ -131,8 +133,8 @@ if [ -z $PGLIB ]; then
131133
echo"Postgres (the PGLIB directory). You must identify the PGLIB"
132134
echo"directory either with a --pglib invocation option, or by"
133135
echo"setting the PGLIB environment variable, or by having a program"
134-
echo"called 'postconfig' in your search path thatsets the PGLIB"
135-
echo"environment variable."
136+
echo"called 'postconfig' in your search path thatoutputs an asignment"
137+
echo"for PGLIB."
136138
exit 20
137139
fi
138140

‎src/include/config.h

Lines changed: 55 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,14 @@
1717

1818
#defineHAVE_MEMMOVE
1919

20-
#if defined(sequent)
20+
#if defined(aix)
21+
# defineCLASS_CONFLICT
22+
# define DISABLE_XOPEN_NLS
23+
# defineNEED_ISINF
2124
# defineNEED_UNION_SEMUN
25+
# define NEED_SYS_SELECT_H
26+
# defineHAVE_TZSET
27+
# defineHAVE_ANSI_CPP
2228
#endif
2329

2430
#if defined(alpha)
@@ -30,18 +36,54 @@
3036
# defineNEED_UNION_SEMUN
3137
#endif
3238

39+
#if defined(BSD44_derived)|| \
40+
defined(bsdi)
41+
# if defined(bsdi)
42+
# defineSIGJMP_BUF
43+
# endif
44+
# defineUSE_LIMITS_H
45+
# defineUSE_POSIX_TIME
46+
# defineNEED_CBRT
47+
# if defined(PRE_BSDI_2_1)
48+
# defineNEED_UNION_SEMUN
49+
# endif
50+
#endif
51+
3352
#if defined(dgux)
3453
# defineLINUX_ELF
3554
# defineNEED_UNION_SEMUN
3655
# define __USE_POSIX_SIGNALS
3756
# define-DUSE_POSIX_SIGNALS
3857
#endif
3958

40-
#if defined(ultrix4)
41-
# defineNEED_ISINF
59+
#if defined(hpux)
60+
# defineSIGJMP_BUF
4261
# defineUSE_POSIX_TIME
62+
# defineHAVE_TZSET
63+
# defineNEED_CBRT
64+
# defineNEED_RINT
4365
# defineNEED_UNION_SEMUN
44-
# define NEED_STRDUP
66+
#endif
67+
68+
#if defined(i386_solaris)
69+
# defineUSE_POSIX_TIME
70+
# define USE_POSIX_SIGNALS
71+
# defineNEED_ISINF
72+
# define NEED_RUSAGE
73+
# defineNO_EMPTY_STMTS
74+
# defineHAVE_TZSET
75+
# defineNEED_UNION_SEMUN
76+
# define SYSV_DIRENT
77+
#endif
78+
79+
#if defined(irix5)
80+
# defineUSE_POSIX_TIME
81+
# define USE_POSIX_SIGNALS
82+
# defineNEED_ISINF
83+
# define NO_EMPTY_STMTS
84+
# defineNO_VFORK
85+
# defineHAVE_TZSET
86+
# defineSYSV_DIRENT
4587
#endif
4688

4789
#if defined(linux)
@@ -51,28 +93,19 @@
5193
__USE_BSD is set by bsd/signal.h, and __USE_BSD_SIGNAL appears not to
5294
be used.
5395
*/
96+
# defineSIGJMP_BUF
5497
# defineUSE_POSIX_TIME
5598
# defineHAVE_TZSET
5699
# defineNEED_CBRT
57100
#endif
58101

59-
#if defined(hpux)
60-
# defineUSE_POSIX_TIME
61-
# defineHAVE_TZSET
62-
# defineNEED_CBRT
63-
# defineNEED_RINT
64-
# defineNEED_UNION_SEMUN
102+
#if defined(next)
103+
# defineSIGJMP_BUF
104+
# defineNEED_SIG_JMP
65105
#endif
66106

67-
#if defined(i386_solaris)
68-
# defineUSE_POSIX_TIME
69-
# define USE_POSIX_SIGNALS
70-
# defineNEED_ISINF
71-
# define NEED_RUSAGE
72-
# defineNO_EMPTY_STMTS
73-
# defineHAVE_TZSET
107+
#if defined(sequent)
74108
# defineNEED_UNION_SEMUN
75-
# define SYSV_DIRENT
76109
#endif
77110

78111
#if defined(sparc)&& !defined(sparc_solaris)
@@ -103,11 +136,8 @@
103136
# define SYSV_DIRENT
104137
#endif
105138

106-
#if defined(next)
107-
# defineNEED_SIG_JMP
108-
#endif
109-
110139
#if defined(win32)
140+
# defineSIGJMP_BUF
111141
# defineNEED_SIG_JMP
112142
# defineNO_UNISTD_H
113143
# defineUSES_WINSOCK
@@ -118,35 +148,13 @@
118148
# defineNEED_ISINF
119149
#endif/* WIN32 */
120150

121-
#if defined(BSD44_derived)|| \
122-
defined(bsdi)
123-
# defineUSE_LIMITS_H
151+
#if defined(ultrix4)
152+
# defineNEED_ISINF
124153
# define USE_POSIX_TIME
125-
# defineNEED_CBRT
126-
# ifdefPRE_BSDI_2_1
127-
# defineNEED_UNION_SEMUN
128-
# endif
129-
#endif
130-
131-
#if defined(aix)
132-
# defineCLASS_CONFLICT
133-
# define DISABLE_XOPEN_NLS
134-
# defineNEED_ISINF
135154
# defineNEED_UNION_SEMUN
136-
# define NEED_SYS_SELECT_H
137-
# defineHAVE_TZSET
138-
# defineHAVE_ANSI_CPP
155+
# define NEED_STRDUP
139156
#endif
140157

141-
#if defined(irix5)
142-
# defineUSE_POSIX_TIME
143-
# define USE_POSIX_SIGNALS
144-
# defineNEED_ISINF
145-
# define NO_EMPTY_STMTS
146-
# defineNO_VFORK
147-
# defineHAVE_TZSET
148-
# defineSYSV_DIRENT
149-
#endif
150158

151159
/*
152160
* The following is used as the arg list for signal handlers. Any ports

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp