mirror of
https://github.com/postgres/postgres.git
synced 2025-04-21 12:05:57 +03:00
Add a MIPS/NetBSD port...
This commit is contained in:
parent
b7559f94cd
commit
81cda65f74
@ -58,17 +58,26 @@ BSD44_derived_dlerror(void)
|
|||||||
void *
|
void *
|
||||||
BSD44_derived_dlopen(char *file, int num)
|
BSD44_derived_dlopen(char *file, int num)
|
||||||
{
|
{
|
||||||
|
#ifdef __mips__
|
||||||
|
(void) sprintf(error_message, "dlopen (%s) not supported", file);
|
||||||
|
return NULL;
|
||||||
|
#else
|
||||||
void *vp;
|
void *vp;
|
||||||
|
|
||||||
if ((vp = dlopen(file, num)) == (void *) NULL) {
|
if ((vp = dlopen(file, num)) == (void *) NULL) {
|
||||||
(void) sprintf(error_message, "dlopen (%s) failed", file);
|
(void) sprintf(error_message, "dlopen (%s) failed", file);
|
||||||
}
|
}
|
||||||
return(vp);
|
return(vp);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void *
|
void *
|
||||||
BSD44_derived_dlsym(void *handle, char *name)
|
BSD44_derived_dlsym(void *handle, char *name)
|
||||||
{
|
{
|
||||||
|
#ifdef __mips__
|
||||||
|
(void) sprintf(error_message, "dlsym (%s) failed", name);
|
||||||
|
return NULL;
|
||||||
|
#else
|
||||||
void *vp;
|
void *vp;
|
||||||
char buf[BUFSIZ];
|
char buf[BUFSIZ];
|
||||||
|
|
||||||
@ -80,10 +89,13 @@ BSD44_derived_dlsym(void *handle, char *name)
|
|||||||
(void) sprintf(error_message, "dlsym (%s) failed", name);
|
(void) sprintf(error_message, "dlsym (%s) failed", name);
|
||||||
}
|
}
|
||||||
return(vp);
|
return(vp);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
BSD44_derived_dlclose(void *handle)
|
BSD44_derived_dlclose(void *handle)
|
||||||
{
|
{
|
||||||
|
#ifndef __mips__
|
||||||
dlclose(handle);
|
dlclose(handle);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: ipc.h,v 1.2 1996/10/02 20:40:17 scrappy Exp $
|
* $Id: ipc.h,v 1.3 1996/10/11 03:56:27 scrappy Exp $
|
||||||
*
|
*
|
||||||
* NOTES
|
* NOTES
|
||||||
* This file is very architecture-specific. This stuff should actually
|
* This file is very architecture-specific. This stuff should actually
|
||||||
@ -29,6 +29,9 @@
|
|||||||
* Many architectures have support for user-level spinlocks (i.e., an
|
* Many architectures have support for user-level spinlocks (i.e., an
|
||||||
* atomic test-and-set instruction). However, we have only written
|
* atomic test-and-set instruction). However, we have only written
|
||||||
* spinlock code for the architectures listed.
|
* spinlock code for the architectures listed.
|
||||||
|
* NB: for operating systems like NetBSD (covered by BSD44_derived),
|
||||||
|
* we may in fact have different architectures, thus make the tests
|
||||||
|
* based on portnames somewhat misleading.
|
||||||
*/
|
*/
|
||||||
#if defined(PORTNAME_aix) || \
|
#if defined(PORTNAME_aix) || \
|
||||||
defined(PORTNAME_alpha) || \
|
defined(PORTNAME_alpha) || \
|
||||||
@ -45,6 +48,10 @@
|
|||||||
#define HAS_TEST_AND_SET
|
#define HAS_TEST_AND_SET
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined(PORTNAME_BSD44_derived) && defined(__mips__)
|
||||||
|
#undef HAS_TEST_AND_SET
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(HAS_TEST_AND_SET)
|
#if defined(HAS_TEST_AND_SET)
|
||||||
|
|
||||||
#if defined(PORTNAME_aix)
|
#if defined(PORTNAME_aix)
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
#
|
#
|
||||||
# Copyright (c) 1994-5, Regents of the University of California
|
# Copyright (c) 1994-5, Regents of the University of California
|
||||||
#
|
#
|
||||||
# $Id: postgres.mk.BSD44_derived,v 1.2 1996/07/25 07:28:12 scrappy Exp $
|
# $Id: postgres.mk.BSD44_derived,v 1.3 1996/10/11 03:56:41 scrappy Exp $
|
||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
ifndef MK_PORT
|
ifndef MK_PORT
|
||||||
@ -29,7 +29,11 @@ LDADD+= -L/usr/local/lib -lfl
|
|||||||
#
|
#
|
||||||
CFLAGS_SL = -fpic -DPIC
|
CFLAGS_SL = -fpic -DPIC
|
||||||
|
|
||||||
|
ifeq ($(HOSTTYPE), mips)
|
||||||
|
#SLSUFF= .so
|
||||||
|
else
|
||||||
SLSUFF= .so
|
SLSUFF= .so
|
||||||
|
endif
|
||||||
|
|
||||||
%.so: %.o
|
%.so: %.o
|
||||||
$(LD) -x -r -o $(objdir)/$(<F).obj $(objdir)/$(<F)
|
$(LD) -x -r -o $(objdir)/$(<F).obj $(objdir)/$(<F)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user