aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc G. Fournier <scrappy@hub.org>1998-02-03 01:25:47 +0000
committerMarc G. Fournier <scrappy@hub.org>1998-02-03 01:25:47 +0000
commiteb348bf41cb231d1f808a91f3367bfbb96af27d5 (patch)
treedbfebed4867d8999c1736b64094509e750d08839
parentfe3737f6f9c9380a84d6b3c98de0f208f1a82c36 (diff)
downloadpostgresql-eb348bf41cb231d1f808a91f3367bfbb96af27d5.tar.gz
postgresql-eb348bf41cb231d1f808a91f3367bfbb96af27d5.zip
Clean up the alpha port, remove the backend/port/alpha subdirectory
structure, and move the init_address_fixup() code directly into backend/main/main.c with appropriate #ifdefs around it...
-rw-r--r--src/backend/main/main.c29
-rw-r--r--src/backend/port/alpha/Makefile34
-rw-r--r--src/backend/port/alpha/port-protos.h19
-rw-r--r--src/backend/port/alpha/port.c37
-rw-r--r--src/backend/port/hpux/Makefile34
-rw-r--r--src/backend/port/hpux/port.c32
-rw-r--r--src/backend/port/ultrix4/port.c26
7 files changed, 25 insertions, 186 deletions
diff --git a/src/backend/main/main.c b/src/backend/main/main.c
index 2777ff061db..8cfce24e1ad 100644
--- a/src/backend/main/main.c
+++ b/src/backend/main/main.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/main/main.c,v 1.11 1997/12/19 02:05:42 scrappy Exp $
+ * $Header: /cvsroot/pgsql/src/backend/main/main.c,v 1.12 1998/02/03 01:25:23 scrappy Exp $
*
*-------------------------------------------------------------------------
*/
@@ -38,9 +38,18 @@ main(int argc, char *argv[])
{
int len;
+#if defined(alpha)
+# ifdef NOFIXADE
+ int buffer[] = {SSIN_UACPROC, UAC_SIGBUS};
+# endif /* NOFIXADE */
+# ifdef NOPRINTADE
+ int buffer[] = {SSIN_UACPROC, UAC_NOPRINT};
+# endif /* NOPRINTADE */
+#endif
+
#ifdef USE_LOCALE
setlocale(LC_CTYPE, ""); /* take locale information from an
- * environment */
+ * environment */
setlocale(LC_COLLATE, "");
setlocale(LC_MONETARY, "");
#endif
@@ -50,8 +59,20 @@ main(int argc, char *argv[])
* Must be first so that the bootstrap code calls it, too. (Only
* needed on some RISC architectures.)
*/
- init_address_fixup();
-#endif /* NOFIXADE || NOPRINTADE */
+
+#if defined(ultrix4)
+ syscall(SYS_sysmips, MIPS_FIXADE, 0, NULL, NULL, NULL);
+#endif
+
+#if defined(alpha)
+ if (setsysinfo(SSI_NVPAIRS, buffer, 1, (caddr_t) NULL,
+ (unsigned long) NULL) < 0)
+ {
+ elog(NOTICE, "setsysinfo failed: %d\n", errno);
+ }
+#endif
+
+#endif /* NOFIXADE || NOPRINTADE */
/*
* use one executable for both postgres and postmaster, invoke one or
diff --git a/src/backend/port/alpha/Makefile b/src/backend/port/alpha/Makefile
deleted file mode 100644
index bc98146f882..00000000000
--- a/src/backend/port/alpha/Makefile
+++ /dev/null
@@ -1,34 +0,0 @@
-#-------------------------------------------------------------------------
-#
-# Makefile--
-# Makefile for port/alpha
-#
-# IDENTIFICATION
-# $Header: /cvsroot/pgsql/src/backend/port/alpha/Attic/Makefile,v 1.3 1997/12/20 00:25:13 scrappy Exp $
-#
-#-------------------------------------------------------------------------
-
-SRCDIR = ../../..
-include ../../../Makefile.global
-
-INCLUDE_OPT = -I../..
-
-CFLAGS+=$(INCLUDE_OPT)
-
-OBJS = port.o
-
-all: SUBSYS.o
-
-SUBSYS.o: $(OBJS)
- $(LD) -r -o SUBSYS.o $(OBJS)
-
-depend dep:
- $(CC) -MM $(INCLUDE_OPT) *.c >depend
-
-clean:
- rm -f SUBSYS.o $(OBJS)
-
-ifeq (depend,$(wildcard depend))
-include depend
-endif
-
diff --git a/src/backend/port/alpha/port-protos.h b/src/backend/port/alpha/port-protos.h
deleted file mode 100644
index 51d3bddd702..00000000000
--- a/src/backend/port/alpha/port-protos.h
+++ /dev/null
@@ -1,19 +0,0 @@
-/*-------------------------------------------------------------------------
- *
- * port-protos.h--
- * prototypes for OSF/1-specific routines
- *
- *
- * Copyright (c) 1994, Regents of the University of California
- *
- * $Id: port-protos.h,v 1.4 1998/02/02 03:49:07 scrappy Exp $
- *
- *-------------------------------------------------------------------------
- */
-
-#ifndef PORT_PROTOS_H
-#define PORT_PROTOS_H
-
-extern void init_address_fixup(void);
-
-#endif /* PORT_PROTOS_H */
diff --git a/src/backend/port/alpha/port.c b/src/backend/port/alpha/port.c
deleted file mode 100644
index e01ca93dc82..00000000000
--- a/src/backend/port/alpha/port.c
+++ /dev/null
@@ -1,37 +0,0 @@
-/*-------------------------------------------------------------------------
- *
- * port.c--
- * OSF/1-specific routines
- *
- * Copyright (c) 1994, Regents of the University of California
- *
- *
- * IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/port/alpha/Attic/port.c,v 1.3 1997/09/08 02:25:50 momjian Exp $
- *
- *-------------------------------------------------------------------------
- */
-#include <sys/types.h>
-#include <sys/sysinfo.h>
-#include <sys/proc.h>
-#include "c.h"
-#include "utils/elog.h"
-
-void
-init_address_fixup()
-{
-#ifdef NOFIXADE
- int buffer[] = {SSIN_UACPROC, UAC_SIGBUS};
-
-#endif /* NOFIXADE */
-#ifdef NOPRINTADE
- int buffer[] = {SSIN_UACPROC, UAC_NOPRINT};
-
-#endif /* NOPRINTADE */
-
- if (setsysinfo(SSI_NVPAIRS, buffer, 1, (caddr_t) NULL,
- (unsigned long) NULL) < 0)
- {
- elog(NOTICE, "setsysinfo failed: %d\n", errno);
- }
-}
diff --git a/src/backend/port/hpux/Makefile b/src/backend/port/hpux/Makefile
deleted file mode 100644
index 8bc1a1e3079..00000000000
--- a/src/backend/port/hpux/Makefile
+++ /dev/null
@@ -1,34 +0,0 @@
-#-------------------------------------------------------------------------
-#
-# Makefile--
-# Makefile for port/hpux
-#
-# IDENTIFICATION
-# $Header: /cvsroot/pgsql/src/backend/port/hpux/Attic/Makefile,v 1.3 1997/12/20 00:25:34 scrappy Exp $
-#
-#-------------------------------------------------------------------------
-
-SRCDIR = ../../..
-include ../../../Makefile.global
-
-INCLUDE_OPT = -I../..
-
-CFLAGS+=$(INCLUDE_OPT)
-
-OBJS = port.o dynloader.o tas.o
-
-all: SUBSYS.o
-
-SUBSYS.o: $(OBJS)
- $(LD) -r -o SUBSYS.o $(OBJS)
-
-depend dep:
- $(CC) -MM $(INCLUDE_OPT) *.c >depend
-
-clean:
- rm -f SUBSYS.o $(OBJS)
-
-ifeq (depend,$(wildcard depend))
-include depend
-endif
-
diff --git a/src/backend/port/hpux/port.c b/src/backend/port/hpux/port.c
deleted file mode 100644
index 1c82a099995..00000000000
--- a/src/backend/port/hpux/port.c
+++ /dev/null
@@ -1,32 +0,0 @@
-/*-------------------------------------------------------------------------
- *
- * port.c--
- * port-specific routines for HP-UX
- *
- * Copyright (c) 1994, Regents of the University of California
- *
- *
- * IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/port/hpux/Attic/port.c,v 1.4 1997/12/19 02:45:44 scrappy Exp $
- *
- * NOTES
- * For the most part, this file gets around some non-POSIX calls
- * in POSTGRES.
- *
- *-------------------------------------------------------------------------
- */
-#include <unistd.h> /* for rand()/srand() prototypes */
-#include <math.h> /* for pow() prototype */
-#include <sys/syscall.h> /* for syscall #defines */
-
-#include "c.h"
-
-void
-init_address_fixup()
-{
-
- /*
- * On PA-RISC, unaligned access fixup is handled by the compiler, not
- * by the kernel.
- */
-}
diff --git a/src/backend/port/ultrix4/port.c b/src/backend/port/ultrix4/port.c
deleted file mode 100644
index b009073f788..00000000000
--- a/src/backend/port/ultrix4/port.c
+++ /dev/null
@@ -1,26 +0,0 @@
-/*-------------------------------------------------------------------------
- *
- * port.c--
- * Ultrix-specific routines
- *
- * Copyright (c) 1994, Regents of the University of California
- *
- *
- * IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/port/ultrix4/Attic/port.c,v 1.3 1997/09/07 04:47:27 momjian Exp $
- *
- *-------------------------------------------------------------------------
- */
-#include <sys/syscall.h>
-#include <sys/sysmips.h>
-
-#include "c.h"
-#include "port-protos.h"
-
-void
-init_address_fixup()
-{
-#ifdef NOFIXADE
- syscall(SYS_sysmips, MIPS_FIXADE, 0, NULL, NULL, NULL);
-#endif /* NOFIXADE */
-}