mirror of https://github.com/postgres/postgres
Remove dead ports
Remove the following ports: - dgux - nextstep - sunos4 - svr4 - ultrix4 - univel These are obsolete and not worth rescuing. In most cases, there is circumstantial evidence that they wouldn't work anymore anyway.
This commit is contained in:
parent
4266509c57
commit
f2f9439fbf
|
@ -2194,7 +2194,6 @@ case $host_os in
|
|||
cygwin*) template=cygwin ;;
|
||||
darwin*) template=darwin ;;
|
||||
dragonfly*) template=netbsd ;;
|
||||
dgux*) template=dgux ;;
|
||||
freebsd*) template=freebsd ;;
|
||||
hpux*) template=hpux ;;
|
||||
irix*) template=irix ;;
|
||||
|
@ -2202,19 +2201,11 @@ dragonfly*) template=netbsd ;;
|
|||
template=linux ;;
|
||||
mingw*) template=win32 ;;
|
||||
netbsd*) template=netbsd ;;
|
||||
nextstep*) template=nextstep ;;
|
||||
openbsd*) template=openbsd ;;
|
||||
osf*) template=osf ;;
|
||||
sco*) template=sco ;;
|
||||
solaris*) template=solaris ;;
|
||||
sunos*) template=sunos4 ;;
|
||||
sysv4.2*)
|
||||
case $host_vendor in
|
||||
univel) template=univel ;;
|
||||
esac ;;
|
||||
sysv4*) template=svr4 ;;
|
||||
sysv5*) template=unixware ;;
|
||||
ultrix*) template=ultrix4 ;;
|
||||
esac
|
||||
|
||||
if test x"$template" = x"" ; then
|
||||
|
|
|
@ -59,7 +59,6 @@ case $host_os in
|
|||
cygwin*) template=cygwin ;;
|
||||
darwin*) template=darwin ;;
|
||||
dragonfly*) template=netbsd ;;
|
||||
dgux*) template=dgux ;;
|
||||
freebsd*) template=freebsd ;;
|
||||
hpux*) template=hpux ;;
|
||||
irix*) template=irix ;;
|
||||
|
@ -67,19 +66,11 @@ dragonfly*) template=netbsd ;;
|
|||
template=linux ;;
|
||||
mingw*) template=win32 ;;
|
||||
netbsd*) template=netbsd ;;
|
||||
nextstep*) template=nextstep ;;
|
||||
openbsd*) template=openbsd ;;
|
||||
osf*) template=osf ;;
|
||||
sco*) template=sco ;;
|
||||
solaris*) template=solaris ;;
|
||||
sunos*) template=sunos4 ;;
|
||||
sysv4.2*)
|
||||
case $host_vendor in
|
||||
univel) template=univel ;;
|
||||
esac ;;
|
||||
sysv4*) template=svr4 ;;
|
||||
sysv5*) template=unixware ;;
|
||||
ultrix*) template=ultrix4 ;;
|
||||
esac
|
||||
|
||||
if test x"$template" = x"" ; then
|
||||
|
|
|
@ -1682,9 +1682,9 @@ libpq.so.2.1: cannot open shared object file: No such file or directory
|
|||
<indexterm>
|
||||
<primary>ldconfig</primary>
|
||||
</indexterm>
|
||||
If you are on <systemitem class="osname">BSD/OS</>, <systemitem
|
||||
class="osname">Linux</>, or <systemitem class="osname">SunOS 4</>
|
||||
and you have root access you can run:
|
||||
If you are on <systemitem class="osname">BSD/OS</>
|
||||
or <systemitem class="osname">Linux</>, and you have root access you can
|
||||
run:
|
||||
<programlisting>
|
||||
/sbin/ldconfig /usr/local/pgsql/lib
|
||||
</programlisting>
|
||||
|
|
|
@ -268,10 +268,6 @@ ifeq ($(PORTNAME), solaris)
|
|||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(PORTNAME), sunos4)
|
||||
LINK.shared = $(LD) -assert pure-text -Bdynamic
|
||||
endif
|
||||
|
||||
ifeq ($(PORTNAME), osf)
|
||||
LINK.shared = $(LD) -shared -expect_unresolved '*'
|
||||
endif
|
||||
|
@ -288,14 +284,6 @@ ifeq ($(PORTNAME), sco)
|
|||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(PORTNAME), svr4)
|
||||
LINK.shared = $(LD) -G
|
||||
endif
|
||||
|
||||
ifeq ($(PORTNAME), univel)
|
||||
LINK.shared = $(LD) -G -z text
|
||||
endif
|
||||
|
||||
ifeq ($(PORTNAME), unixware)
|
||||
ifeq ($(GCC), yes)
|
||||
LINK.shared = $(CC) -shared
|
||||
|
|
|
@ -224,10 +224,6 @@ startup_hacks(const char *progname)
|
|||
*/
|
||||
#ifdef NOFIXADE
|
||||
|
||||
#if defined(ultrix4)
|
||||
syscall(SYS_sysmips, MIPS_FIXADE, 0, NULL, NULL, NULL);
|
||||
#endif
|
||||
|
||||
#if defined(__alpha) /* no __alpha__ ? */
|
||||
{
|
||||
int buffer[] = {SSIN_UACPROC, UAC_SIGBUS | UAC_NOPRINT};
|
||||
|
|
|
@ -1,6 +0,0 @@
|
|||
/* Dummy file used for nothing at this point
|
||||
*
|
||||
* see dgux.h
|
||||
*
|
||||
* src/backend/port/dynloader/dgux.c
|
||||
*/
|
|
@ -1,44 +0,0 @@
|
|||
/*-------------------------------------------------------------------------
|
||||
*
|
||||
* dgux.h
|
||||
*
|
||||
* Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* src/backend/port/dynloader/dgux.h
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
#ifndef PORT_PROTOS_H
|
||||
#define PORT_PROTOS_H
|
||||
|
||||
#include <dlfcn.h>
|
||||
#include "utils/dynamic_loader.h" /* pgrminclude ignore */
|
||||
|
||||
/*
|
||||
* Dynamic Loader on DG/UX.
|
||||
*
|
||||
* this dynamic loader uses the system dynamic loading interface for shared
|
||||
* libraries (ie. dlopen/dlsym/dlclose). The user must specify a shared
|
||||
* library as the file to be dynamically loaded.
|
||||
*/
|
||||
|
||||
/*
|
||||
* In some older systems, the RTLD_NOW flag isn't defined and the mode
|
||||
* argument to dlopen must always be 1. The RTLD_GLOBAL flag is wanted
|
||||
* if available, but it doesn't exist everywhere.
|
||||
* If it doesn't exist, set it to 0 so it has no effect.
|
||||
*/
|
||||
#ifndef RTLD_NOW
|
||||
#define RTLD_NOW 1
|
||||
#endif
|
||||
#ifndef RTLD_GLOBAL
|
||||
#define RTLD_GLOBAL 0
|
||||
#endif
|
||||
|
||||
#define pg_dlopen(f) dlopen((f), RTLD_NOW | RTLD_GLOBAL)
|
||||
#define pg_dlsym dlsym
|
||||
#define pg_dlclose dlclose
|
||||
#define pg_dlerror dlerror
|
||||
|
||||
#endif /* PORT_PROTOS_H */
|
|
@ -18,7 +18,7 @@
|
|||
#include "utils/dynamic_loader.h" /* pgrminclude ignore */
|
||||
|
||||
/*
|
||||
* Dynamic Loader on SunOS 4.
|
||||
* Dynamic Loader on Irix.
|
||||
*
|
||||
* this dynamic loader uses the system dynamic loading interface for shared
|
||||
* libraries (ie. dlopen/dlsym/dlclose). The user must specify a shared
|
||||
|
|
|
@ -1,84 +0,0 @@
|
|||
/* src/backend/port/dynloader/nextstep.c */
|
||||
|
||||
#include "postgres.h"
|
||||
|
||||
#include "mach-o/rld.h"
|
||||
#include "streams/streams.h"
|
||||
|
||||
static char *lastError = NULL;
|
||||
|
||||
static NXStream *
|
||||
OpenError()
|
||||
{
|
||||
return NXOpenMemory(NULL, 0, NX_WRITEONLY);
|
||||
}
|
||||
|
||||
static void
|
||||
CloseError(NXStream * s)
|
||||
{
|
||||
if (s)
|
||||
NXCloseMemory(s, NX_FREEBUFFER);
|
||||
}
|
||||
|
||||
static void
|
||||
TransferError(NXStream * s)
|
||||
{
|
||||
char *buffer;
|
||||
int len,
|
||||
maxlen;
|
||||
|
||||
if (lastError)
|
||||
free(lastError);
|
||||
NXGetMemoryBuffer(s, &buffer, &len, &maxlen);
|
||||
lastError = malloc(len + 1);
|
||||
strcpy(lastError, buffer);
|
||||
}
|
||||
|
||||
void *
|
||||
next_dlopen(char *name)
|
||||
{
|
||||
int rld_success;
|
||||
NXStream *errorStream;
|
||||
char *result = NULL;
|
||||
char **p;
|
||||
|
||||
errorStream = OpenError();
|
||||
p = calloc(2, sizeof(void *));
|
||||
p[0] = name;
|
||||
rld_success = rld_load(errorStream, NULL, p, NULL);
|
||||
free(p);
|
||||
|
||||
if (!rld_success)
|
||||
{
|
||||
TransferError(errorStream);
|
||||
result = (char *) 1;
|
||||
}
|
||||
CloseError(errorStream);
|
||||
return result;
|
||||
}
|
||||
|
||||
int
|
||||
next_dlclose(void *handle)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
void *
|
||||
next_dlsym(void *handle, char *symbol)
|
||||
{
|
||||
NXStream *errorStream = OpenError();
|
||||
char symbuf[1024];
|
||||
unsigned long symref = 0;
|
||||
|
||||
snprintf(symbuf, sizeof(symbuf), "_%s", symbol);
|
||||
if (!rld_lookup(errorStream, symbuf, &symref))
|
||||
TransferError(errorStream);
|
||||
CloseError(errorStream);
|
||||
return (void *) symref;
|
||||
}
|
||||
|
||||
char *
|
||||
next_dlerror(void)
|
||||
{
|
||||
return lastError;
|
||||
}
|
|
@ -1,26 +0,0 @@
|
|||
/*-------------------------------------------------------------------------
|
||||
*
|
||||
* port_protos.h
|
||||
* port-specific prototypes for NeXT
|
||||
*
|
||||
* src/backend/port/dynloader/nextstep.h
|
||||
*/
|
||||
|
||||
#ifndef PORT_PROTOS_H
|
||||
#define PORT_PROTOS_H
|
||||
|
||||
#include "utils/dynamic_loader.h" /* pgrminclude ignore */
|
||||
|
||||
void *next_dlopen(char *name);
|
||||
int next_dlclose(void *handle);
|
||||
void *next_dlsym(void *handle, char *symbol);
|
||||
char *next_dlerror(void);
|
||||
|
||||
#define pg_dlopen(f) next_dlopen
|
||||
#define pg_dlsym next_dlsym
|
||||
#define pg_dlclose next_dlclose
|
||||
#define pg_dlerror next_dlerror
|
||||
|
||||
/* port.c */
|
||||
|
||||
#endif /* PORT_PROTOS_H */
|
|
@ -1,7 +0,0 @@
|
|||
/*
|
||||
* src/backend/port/dynloader/sunos4.c
|
||||
*
|
||||
* Dummy file used for nothing at this point
|
||||
*
|
||||
* see sunos4.h
|
||||
*/
|
|
@ -1,46 +0,0 @@
|
|||
/*-------------------------------------------------------------------------
|
||||
*
|
||||
* sunos4.h
|
||||
* port-specific prototypes for SunOS 4
|
||||
*
|
||||
*
|
||||
* Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* src/backend/port/dynloader/sunos4.h
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
#ifndef PORT_PROTOS_H
|
||||
#define PORT_PROTOS_H
|
||||
|
||||
#include <dlfcn.h>
|
||||
#include "utils/dynamic_loader.h" /* pgrminclude ignore */
|
||||
|
||||
/*
|
||||
* Dynamic Loader on SunOS 4.
|
||||
*
|
||||
* this dynamic loader uses the system dynamic loading interface for shared
|
||||
* libraries (ie. dlopen/dlsym/dlclose). The user must specify a shared
|
||||
* library as the file to be dynamically loaded.
|
||||
*/
|
||||
|
||||
/*
|
||||
* In some older systems, the RTLD_NOW flag isn't defined and the mode
|
||||
* argument to dlopen must always be 1. The RTLD_GLOBAL flag is wanted
|
||||
* if available, but it doesn't exist everywhere.
|
||||
* If it doesn't exist, set it to 0 so it has no effect.
|
||||
*/
|
||||
#ifndef RTLD_NOW
|
||||
#define RTLD_NOW 1
|
||||
#endif
|
||||
#ifndef RTLD_GLOBAL
|
||||
#define RTLD_GLOBAL 0
|
||||
#endif
|
||||
|
||||
#define pg_dlopen(f) dlopen((f), RTLD_NOW | RTLD_GLOBAL)
|
||||
#define pg_dlsym dlsym
|
||||
#define pg_dlclose dlclose
|
||||
#define pg_dlerror dlerror
|
||||
|
||||
#endif /* PORT_PROTOS_H */
|
|
@ -1,7 +0,0 @@
|
|||
/*
|
||||
* src/backend/port/dynloader/svr4.c
|
||||
*
|
||||
* Dummy file used for nothing at this point
|
||||
*
|
||||
* see svr4.h
|
||||
*/
|
|
@ -1,46 +0,0 @@
|
|||
/*-------------------------------------------------------------------------
|
||||
*
|
||||
* svr4.h
|
||||
* port-specific prototypes for Intel x86/Intel SVR4
|
||||
*
|
||||
*
|
||||
* Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* src/backend/port/dynloader/svr4.h
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
#ifndef PORT_PROTOS_H
|
||||
#define PORT_PROTOS_H
|
||||
|
||||
#include <dlfcn.h>
|
||||
#include "utils/dynamic_loader.h" /* pgrminclude ignore */
|
||||
|
||||
/*
|
||||
* Dynamic Loader on Intel x86/Intel SVR4.
|
||||
*
|
||||
* this dynamic loader uses the system dynamic loading interface for shared
|
||||
* libraries (ie. dlopen/dlsym/dlclose). The user must specify a shared
|
||||
* library as the file to be dynamically loaded.
|
||||
*/
|
||||
|
||||
/*
|
||||
* In some older systems, the RTLD_NOW flag isn't defined and the mode
|
||||
* argument to dlopen must always be 1. The RTLD_GLOBAL flag is wanted
|
||||
* if available, but it doesn't exist everywhere.
|
||||
* If it doesn't exist, set it to 0 so it has no effect.
|
||||
*/
|
||||
#ifndef RTLD_NOW
|
||||
#define RTLD_NOW 1
|
||||
#endif
|
||||
#ifndef RTLD_GLOBAL
|
||||
#define RTLD_GLOBAL 0
|
||||
#endif
|
||||
|
||||
#define pg_dlopen(f) dlopen((f), RTLD_NOW | RTLD_GLOBAL)
|
||||
#define pg_dlsym dlsym
|
||||
#define pg_dlclose dlclose
|
||||
#define pg_dlerror dlerror
|
||||
|
||||
#endif /* PORT_PROTOS_H */
|
|
@ -1,67 +0,0 @@
|
|||
/*-------------------------------------------------------------------------
|
||||
*
|
||||
* ultrix4.c
|
||||
* This dynamic loader uses Andrew Yu's libdl-1.0 package for Ultrix 4.x.
|
||||
*
|
||||
* Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* src/backend/port/dynloader/ultrix4.c
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
#include "postgres.h"
|
||||
|
||||
#include "dl.h"
|
||||
#include "utils/dynamic_loader.h"
|
||||
|
||||
extern char my_exec_path[];
|
||||
|
||||
void *
|
||||
pg_dlopen(char *filename)
|
||||
{
|
||||
static int dl_initialized = 0;
|
||||
void *handle;
|
||||
|
||||
/*
|
||||
* initializes the dynamic loader with the executable's pathname. (only
|
||||
* needs to do this the first time pg_dlopen is called.)
|
||||
*/
|
||||
if (!dl_initialized)
|
||||
{
|
||||
if (!dl_init(my_exec_path))
|
||||
return NULL;
|
||||
|
||||
/*
|
||||
* if there are undefined symbols, we want dl to search from the
|
||||
* following libraries also.
|
||||
*/
|
||||
dl_setLibraries("/usr/lib/libm_G0.a:/usr/lib/libc_G0.a");
|
||||
dl_initialized = 1;
|
||||
}
|
||||
|
||||
/*
|
||||
* open the file. We do the symbol resolution right away so that we will
|
||||
* know if there are undefined symbols. (This is in fact the same
|
||||
* semantics as "ld -A". ie. you cannot have undefined symbols.
|
||||
*/
|
||||
if ((handle = dl_open(filename, DL_NOW)) == NULL)
|
||||
{
|
||||
int count;
|
||||
char **list = dl_undefinedSymbols(&count);
|
||||
|
||||
/* list the undefined symbols, if any */
|
||||
if (count)
|
||||
{
|
||||
while (*list)
|
||||
{
|
||||
elog(WARNING, "\"%s\" is undefined", *list);
|
||||
list++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return (void *) handle;
|
||||
}
|
|
@ -1,109 +0,0 @@
|
|||
/*-------------------------------------------------------------------------
|
||||
*
|
||||
* dl.h
|
||||
*
|
||||
*
|
||||
*
|
||||
* Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* src/backend/port/dynloader/ultrix4.h
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
/*
|
||||
* Ultrix 4.x Dynamic Loader Library Version 1.0
|
||||
*
|
||||
* dl.h
|
||||
* header file for the Dynamic Loader Library
|
||||
*/
|
||||
#ifndef _DL_HEADER_
|
||||
#define _DL_HEADER_
|
||||
|
||||
#include <stdio.h>
|
||||
#include "filehdr.h"
|
||||
#include "syms.h"
|
||||
#include "ldfcn.h"
|
||||
#include "reloc.h"
|
||||
#include "scnhdr.h"
|
||||
|
||||
|
||||
typedef long CoreAddr;
|
||||
|
||||
|
||||
typedef struct ScnInfo
|
||||
{
|
||||
CoreAddr addr; /* starting address of the section */
|
||||
SCNHDR hdr; /* section header */
|
||||
RELOC *relocEntries; /* relocation entries */
|
||||
} ScnInfo;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
DL_NEEDRELOC, /* still need relocation */
|
||||
DL_RELOCATED, /* no relocation necessary */
|
||||
DL_INPROG /* relocation in progress */
|
||||
} dlRStatus;
|
||||
|
||||
typedef struct JmpTbl
|
||||
{
|
||||
char *block; /* the jump table memory block */
|
||||
struct JmpTbl *next; /* next block */
|
||||
} JmpTbl;
|
||||
|
||||
typedef struct dlFile
|
||||
{
|
||||
char *filename; /* file name of the object file */
|
||||
|
||||
int textSize; /* used by mprotect */
|
||||
CoreAddr textAddress; /* start addr of text section */
|
||||
long textVaddr; /* vaddr of text section in obj file */
|
||||
CoreAddr rdataAddress; /* start addr of rdata section */
|
||||
long rdataVaddr; /* vaddr of text section in obj file */
|
||||
CoreAddr dataAddress; /* start addr of data section */
|
||||
long dataVaddr; /* vaddr of text section in obj file */
|
||||
CoreAddr bssAddress; /* start addr of bss section */
|
||||
long bssVaddr; /* vaddr of text section in obj file */
|
||||
|
||||
int nsect; /* number of sections */
|
||||
ScnInfo *sect; /* details of each section (array) */
|
||||
|
||||
int issExtMax; /* size of string space */
|
||||
char *extss; /* extern sym string space (in core) */
|
||||
int iextMax; /* maximum number of Symbols */
|
||||
pEXTR extsyms; /* extern syms */
|
||||
|
||||
dlRStatus relocStatus; /* what relocation needed? */
|
||||
int needReloc;
|
||||
|
||||
JmpTbl *jmptable; /* the jump table for R_JMPADDR */
|
||||
|
||||
struct dlFile *next; /* next member of the archive */
|
||||
} dlFile;
|
||||
|
||||
typedef struct dlSymbol
|
||||
{
|
||||
char *name; /* name of the symbol */
|
||||
long addr; /* address of the symbol */
|
||||
dlFile *objFile; /* from which file */
|
||||
} dlSymbol;
|
||||
|
||||
/*
|
||||
* prototypes for the dl* interface
|
||||
*/
|
||||
extern void *dl_open( /* char *filename, int mode */ );
|
||||
extern void *dl_sym( /* void *handle, char *name */ );
|
||||
extern void dl_close( /* void *handle */ );
|
||||
extern char *dl_error( /* void */ );
|
||||
|
||||
#define DL_LAZY 0 /* lazy resolution */
|
||||
#define DL_NOW 1 /* immediate resolution */
|
||||
|
||||
/*
|
||||
* Miscellaneous utility routines:
|
||||
*/
|
||||
extern char **dl_undefinedSymbols( /* int *count */ );
|
||||
extern void dl_printAllSymbols( /* void *handle */ );
|
||||
extern void dl_setLibraries( /* char *libs */ );
|
||||
|
||||
#endif /* _DL_HEADER_ */
|
|
@ -1,7 +0,0 @@
|
|||
/*
|
||||
* src/backend/port/dynloader/univel.c
|
||||
*
|
||||
* Dummy file used for nothing at this point
|
||||
*
|
||||
* see univel.h
|
||||
*/
|
|
@ -1,49 +0,0 @@
|
|||
/*
|
||||
* src/backend/port/dynloader/univel.h
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*
|
||||
* univel.h
|
||||
* port-specific prototypes for Intel x86/UNIXWARE
|
||||
*
|
||||
*
|
||||
* Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* univel.h,v 1.2 1995/03/17 06:40:18 andrew Exp
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
#ifndef PORT_PROTOS_H
|
||||
#define PORT_PROTOS_H
|
||||
|
||||
#include <dlfcn.h>
|
||||
#include "utils/dynamic_loader.h" /* pgrminclude ignore */
|
||||
|
||||
/*
|
||||
* Dynamic Loader on Intel x86/Intel SVR4.
|
||||
*
|
||||
* this dynamic loader uses the system dynamic loading interface for shared
|
||||
* libraries (ie. dlopen/dlsym/dlclose). The user must specify a shared
|
||||
* library as the file to be dynamically loaded.
|
||||
*/
|
||||
|
||||
/*
|
||||
* In some older systems, the RTLD_NOW flag isn't defined and the mode
|
||||
* argument to dlopen must always be 1. The RTLD_GLOBAL flag is wanted
|
||||
* if available, but it doesn't exist everywhere.
|
||||
* If it doesn't exist, set it to 0 so it has no effect.
|
||||
*/
|
||||
#ifndef RTLD_NOW
|
||||
#define RTLD_NOW 1
|
||||
#endif
|
||||
#ifndef RTLD_GLOBAL
|
||||
#define RTLD_GLOBAL 0
|
||||
#endif
|
||||
|
||||
#define pg_dlopen(f) dlopen((f), RTLD_NOW | RTLD_GLOBAL)
|
||||
#define pg_dlsym dlsym
|
||||
#define pg_dlclose dlclose
|
||||
#define pg_dlerror dlerror
|
||||
|
||||
#endif /* PORT_PROTOS_H */
|
|
@ -21,7 +21,7 @@
|
|||
#include "utils/dynamic_loader.h" /* pgrminclude ignore */
|
||||
|
||||
/*
|
||||
* Dynamic Loader on Intel x86/Intel SVR4.
|
||||
* Dynamic Loader on UnixWare.
|
||||
*
|
||||
* this dynamic loader uses the system dynamic loading interface for shared
|
||||
* libraries (ie. dlopen/dlsym/dlclose). The user must specify a shared
|
||||
|
|
|
@ -1,17 +0,0 @@
|
|||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# Makefile--
|
||||
# Makefile for port/nextstep
|
||||
#
|
||||
# IDENTIFICATION
|
||||
# src/backend/port/nextstep/Makefile
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
|
||||
subdir = src/backend/port/nextstep
|
||||
top_builddir = ../../../..
|
||||
include $(top_builddir)/src/Makefile.global
|
||||
|
||||
OBJS = port.o
|
||||
|
||||
include $(top_srcdir)/src/backend/common.mk
|
|
@ -1,62 +0,0 @@
|
|||
/*
|
||||
* src/backend/port/nextstep/port.c
|
||||
*/
|
||||
#include "postgres.h"
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
#include "libc.h"
|
||||
#else
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#include <sys/signal.h>
|
||||
|
||||
|
||||
void
|
||||
putenv(char *name)
|
||||
{
|
||||
extern char **environ;
|
||||
static int was_mallocated = 0;
|
||||
int size;
|
||||
|
||||
/* Compute the size of environ array including the final NULL */
|
||||
for (size = 1; environ[size++];)
|
||||
/* nothing */ ;
|
||||
|
||||
if (!was_mallocated)
|
||||
{
|
||||
char **tmp = environ;
|
||||
int i;
|
||||
|
||||
was_mallocated = 1;
|
||||
environ = malloc(size * sizeof(char *));
|
||||
for (i = 0; i < size; i++)
|
||||
environ[i] = tmp[i];
|
||||
}
|
||||
|
||||
environ = realloc(environ, (size + 1) * sizeof(char *));
|
||||
environ[size - 1] = strcpy(malloc(strlen(name) + 1), name);
|
||||
environ[size] = NULL;
|
||||
}
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
int
|
||||
sigaddset(int *set, int signo)
|
||||
{
|
||||
*set |= sigmask(signo);
|
||||
return *set;
|
||||
}
|
||||
|
||||
int
|
||||
sigemptyset(int *set)
|
||||
{
|
||||
return *set = 0;
|
||||
}
|
||||
|
||||
char *
|
||||
getcwd(char *buf, size_t size)
|
||||
{
|
||||
return getwd(buf);
|
||||
}
|
||||
|
||||
#endif
|
|
@ -1,3 +0,0 @@
|
|||
/* src/include/port/dgux.h */
|
||||
|
||||
/* nothing needed */
|
|
@ -1,19 +0,0 @@
|
|||
/* src/include/port/nextstep.h */
|
||||
|
||||
#include "libc.h"
|
||||
#include <sys/ioctl.h>
|
||||
#if defined(__STRICT_ANSI__)
|
||||
#define isascii(c) ((unsigned)(c)<=0177)
|
||||
#endif
|
||||
extern char *strdup(const char *string);
|
||||
|
||||
#ifndef _POSIX_SOURCE
|
||||
typedef unsigned short mode_t;
|
||||
typedef int sigset_t;
|
||||
|
||||
#define SIG_BLOCK 00
|
||||
#define SIG_UNBLOCK 01
|
||||
#define SIG_SETMASK 02
|
||||
#endif
|
||||
|
||||
#define NO_WAITPID
|
|
@ -1,7 +0,0 @@
|
|||
/*
|
||||
* src/include/port/sunos4.h
|
||||
*
|
||||
* sprintf() returns char *, not int, on SunOS 4.1.x */
|
||||
#define SPRINTF_CHAR
|
||||
|
||||
#include <unistd.h>
|
|
@ -1,3 +0,0 @@
|
|||
/* src/include/port/svr4.h */
|
||||
|
||||
/* nothing needed */
|
|
@ -1,57 +0,0 @@
|
|||
/*
|
||||
* src/include/port/ultrix4.h
|
||||
*/
|
||||
#define NOFIXADE
|
||||
#define NEED_STRDUP
|
||||
|
||||
/*
|
||||
* Except for those system calls and library functions that are either
|
||||
* - covered by the C standard library and Posix.1
|
||||
* - or need a declaration to declare parameter or return types,
|
||||
* most Ultrix 4 calls are not declared in the system header files.
|
||||
* The rest of this header is used to remedy this for PostgreSQL to give a
|
||||
* warning-free compilation.
|
||||
*/
|
||||
|
||||
#include <sys/types.h> /* Declare various types, e.g. size_t, fd_set */
|
||||
|
||||
extern int fp_class_d(double);
|
||||
extern long random(void);
|
||||
|
||||
struct rusage;
|
||||
extern int getrusage(int, struct rusage *);
|
||||
|
||||
extern int ioctl(int, unsigned long,...);
|
||||
|
||||
extern int socket(int, int, int);
|
||||
struct sockaddr;
|
||||
extern int connect(int, const struct sockaddr *, int);
|
||||
typedef int ssize_t;
|
||||
extern ssize_t send(int, const void *, size_t, int);
|
||||
extern ssize_t recv(int, void *, size_t, int);
|
||||
extern int setsockopt(int, int, int, const void *, int);
|
||||
extern int bind(int, const struct sockaddr *, int);
|
||||
extern int listen(int, int);
|
||||
extern int accept(int, struct sockaddr *, int *);
|
||||
extern int getsockname(int, struct sockaddr *, int *);
|
||||
extern ssize_t recvfrom(int, void *, size_t, int, struct sockaddr *, int *);
|
||||
extern ssize_t sendto(int, const void *, size_t, int, const struct sockaddr *, int);
|
||||
struct timeval;
|
||||
extern int select(int, fd_set *, fd_set *, fd_set *, struct timeval *);
|
||||
|
||||
extern int gethostname(char *, int);
|
||||
|
||||
extern int getopt(int, char *const *, const char *);
|
||||
extern int putenv(const char *);
|
||||
|
||||
struct itimerval;
|
||||
extern int setitimer(int, const struct itimerval *, struct itimerval *);
|
||||
struct timezone;
|
||||
extern int gettimeofday(struct timeval *, struct timezone *);
|
||||
|
||||
extern int fsync(int);
|
||||
extern int ftruncate(int, off_t);
|
||||
|
||||
extern char *crypt(char *, char *);
|
||||
|
||||
/* End of ultrix4.h */
|
|
@ -1,8 +0,0 @@
|
|||
/*
|
||||
* src/include/port/univel.h
|
||||
*
|
||||
***************************************
|
||||
* Define this if you are compiling with
|
||||
* the native UNIXWARE C compiler.
|
||||
***************************************/
|
||||
#define USE_UNIVEL_CC
|
|
@ -884,19 +884,6 @@ typedef int slock_t;
|
|||
#endif /* _AIX */
|
||||
|
||||
|
||||
#if defined (nextstep) /* Nextstep */
|
||||
#define HAS_TEST_AND_SET
|
||||
|
||||
typedef struct mutex slock_t;
|
||||
|
||||
#define S_LOCK(lock) mutex_lock(lock)
|
||||
#define S_UNLOCK(lock) mutex_unlock(lock)
|
||||
#define S_INIT_LOCK(lock) mutex_init(lock)
|
||||
/* For Mach, we have to delve inside the entrails of `struct mutex'. Ick! */
|
||||
#define S_LOCK_FREE(alock) ((alock)->lock == 0)
|
||||
#endif /* nextstep */
|
||||
|
||||
|
||||
/* These are in s_lock.c */
|
||||
|
||||
|
||||
|
|
|
@ -1,9 +0,0 @@
|
|||
AROPT = crs
|
||||
DLSUFFIX = .so
|
||||
CFLAGS_SL = -fpic
|
||||
|
||||
# Rule for building a shared library from a single .o file
|
||||
%.so: %.o
|
||||
$(CC) $(CFLAGS) $(LDFLAGS) $(LDFLAGS_SL) -shared -o $@ $<
|
||||
|
||||
sqlmansect = 5
|
|
@ -1,12 +0,0 @@
|
|||
AROPT = cr
|
||||
|
||||
DLSUFFIX = .so
|
||||
ifeq ($(GCC), yes)
|
||||
CFLAGS_SL = -fpic
|
||||
else
|
||||
CFLAGS_SL = -PIC
|
||||
endif
|
||||
|
||||
# Rule for building a shared library from a single .o file
|
||||
%.so: %.o
|
||||
$(LD) -assert pure-text -Bdynamic -o $@ $<
|
|
@ -1,15 +0,0 @@
|
|||
# MAKE_EXPORTS is required for svr4 loaders that want a file of
|
||||
# symbol names to tell them what to export/import.
|
||||
#MAKE_EXPORTS= true
|
||||
|
||||
LIBS += -lc /usr/ucblib/libucb.a
|
||||
LDFLAGS += -LD-Blargedynsym
|
||||
|
||||
DLSUFFIX = .so
|
||||
CFLAGS_SL =
|
||||
|
||||
# Rule for building a shared library from a single .o file
|
||||
%.so: %.o
|
||||
$(LD) -G -Bdynamic -o $@ $<
|
||||
|
||||
sqlmansect = 5
|
|
@ -1,11 +0,0 @@
|
|||
# used by initdb
|
||||
SHELL=/bin/sh5
|
||||
AROPT = crs
|
||||
|
||||
DLSUFFIX = .so
|
||||
# "-G 0" works for both DEC cc and GNU cc.
|
||||
CFLAGS_SL = -G 0
|
||||
|
||||
# Rule for building a shared library from a single .c file
|
||||
%.so: %.c
|
||||
$(CC) -c -G 0 $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $(LDFLAGS_SL) -o $@ $<
|
|
@ -1,10 +0,0 @@
|
|||
AROPT = crs
|
||||
export_dynamic = -Wl,-Bexport
|
||||
DLSUFFIX = .so
|
||||
CFLAGS_SL = -K PIC
|
||||
|
||||
# Rule for building a shared library from a single .o file
|
||||
%.so: %.o
|
||||
$(LD) -G -Bdynamic -o $@ $<
|
||||
|
||||
sqlmansect = 5
|
|
@ -1 +0,0 @@
|
|||
# src/template/dgux
|
|
@ -1,5 +0,0 @@
|
|||
# src/template/nextstep
|
||||
|
||||
AROPT=rc
|
||||
SHARED_LIB=
|
||||
DLSUFFIX=.o
|
|
@ -1,7 +0,0 @@
|
|||
if test "$GCC" != yes ; then
|
||||
CC="$CC -Xa" # relaxed ISO C mode
|
||||
CFLAGS="-v -DSUNOS_CC" # -v is like gcc -Wall
|
||||
if test "$enable_debug" != yes; then
|
||||
CFLAGS="$CFLAGS -O" # any optimization breaks debug
|
||||
fi
|
||||
fi
|
|
@ -1,2 +0,0 @@
|
|||
CFLAGS="-v -O -K i486,host,inline,loop_unroll -Dsvr4"
|
||||
LIBS="-lc89"
|
Loading…
Reference in New Issue