00001
00013 #ifndef _DLFCN_H_
00014 #define _DLFCN_H_
00015
00016
00017
00018 #include <windows.h>
00019
00020
00021
00022 #define RTLD_LAZY 0x1
00023 #define RTLD_NOW 0x2
00024 #define RTLD_LOCAL 0x4
00025 #define RTLD_GLOBAL 0x8
00026 #define RTLD_NOLOAD 0x10
00027 #define RTLD_NODELETE 0x80
00028
00029 #define RTLD_NEXT ((void *) -1)
00030 #define RTLD_DEFAULT ((void *) -2)
00031
00032
00033 #define dlopen(path, mode) ((void *)LoadLibrary(path))
00034 #define dlsym(handle, symbol) ((void *)GetProcAddress((HINSTANCE)handle, symbol))
00035 #define dlerror() "DLL error"
00036 #define dlclose(handle) FreeLibrary((HINSTANCE)handle)
00037
00038
00039 #endif
00040