From d9a687758cc9ca979b9fdff7709f4b6f382be960 Mon Sep 17 00:00:00 2001 From: "monty@mysql.com" <> Date: Sat, 5 Nov 2005 14:10:48 +0200 Subject: [PATCH] Added inclusion of dlfcn.h from old 5.1 tree --- include/my_global.h | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/include/my_global.h b/include/my_global.h index a26c02a687e..55a1b6c2d02 100644 --- a/include/my_global.h +++ b/include/my_global.h @@ -1361,4 +1361,23 @@ do { doubleget_union _tmp; \ #define NO_EMBEDDED_ACCESS_CHECKS #endif +#ifdef HAVE_DLOPEN +#if defined(__WIN__) +#define dlsym(lib, name) GetProcAddress((HMODULE)lib, name) +#define dlopen(libname, unused) LoadLibraryEx(libname, NULL, 0) +#define dlclose(lib) FreeLibrary((HMODULE)lib) +#elif defined(HAVE_DLFCN_H) +#include +#endif +#endif + +/* FreeBSD 2.2.2 does not define RTLD_NOW) */ +#ifndef RTLD_NOW +#define RTLD_NOW 1 +#endif + +#ifndef HAVE_DLERROR +#define dlerror() "" +#endif + #endif /* my_global_h */