Header And Logo

PostgreSQL
| The world's most advanced open source database.

irix.h

Go to the documentation of this file.
00001 /*-------------------------------------------------------------------------
00002  *
00003  * irix.h
00004  *    port-specific prototypes for Irix
00005  *
00006  *
00007  * Portions Copyright (c) 1996-2013, PostgreSQL Global Development Group
00008  * Portions Copyright (c) 1994, Regents of the University of California
00009  *
00010  * src/backend/port/dynloader/irix.h
00011  *
00012  *-------------------------------------------------------------------------
00013  */
00014 #ifndef PORT_PROTOS_H
00015 #define PORT_PROTOS_H
00016 
00017 #include <dlfcn.h>
00018 #include "utils/dynamic_loader.h"       /* pgrminclude ignore */
00019 
00020 /*
00021  * Dynamic Loader on Irix.
00022  *
00023  * this dynamic loader uses the system dynamic loading interface for shared
00024  * libraries (ie. dlopen/dlsym/dlclose). The user must specify a shared
00025  * library as the file to be dynamically loaded.
00026  */
00027 
00028 /*
00029  * In some older systems, the RTLD_NOW flag isn't defined and the mode
00030  * argument to dlopen must always be 1.  The RTLD_GLOBAL flag is wanted
00031  * if available, but it doesn't exist everywhere.
00032  * If it doesn't exist, set it to 0 so it has no effect.
00033  */
00034 #ifndef RTLD_NOW
00035 #define RTLD_NOW 1
00036 #endif
00037 #ifndef RTLD_GLOBAL
00038 #define RTLD_GLOBAL 0
00039 #endif
00040 
00041 #define pg_dlopen(f)    dlopen((f), RTLD_NOW | RTLD_GLOBAL)
00042 #define pg_dlsym        dlsym
00043 #define pg_dlclose      dlclose
00044 #define pg_dlerror      dlerror
00045 
00046 #endif   /* PORT_PROTOS_H */