dlfcnh.inc 1.1 KB

123456789101112131415161718192021222324252627282930313233
  1. Const
  2. RTLD_NEXT = Pointer(-1);
  3. RTLD_DEFAULT = nil;
  4. function dlopen(__file:Pchar; __mode:longint):pointer;cdecl;external dllib name 'dlopen';
  5. function dlclose(__handle:pointer):longint;cdecl;external dllib name 'dlclose';
  6. function dlsym(__handle:pointer; __name:Pchar):pointer;cdecl;external dllib name 'dlsym';
  7. function dlvsym(__handle:pointer; __name:Pchar; __version:Pchar):pointer;cdecl;external dllib name 'dlvsym';
  8. function dlerror:Pchar;cdecl;external clib name 'dlerror';
  9. type
  10. PDl_info = ^Dl_info;
  11. Dl_info = record
  12. dli_fname : Pchar;
  13. dli_fbase : pointer;
  14. dli_sname : Pchar;
  15. dli_saddr : pointer;
  16. end;
  17. function dladdr(__address:pointer; __info:PDl_info):longint;cdecl;external dllib name 'dladdr';
  18. { ---------------------------------------------------------------------
  19. Borland compatibility types
  20. ---------------------------------------------------------------------}
  21. Type
  22. TDLInfo = Dl_info;
  23. PDLInfo = ^TDLInfo;
  24. function dladdr(__address:pointer; var __info: Dl_info):longint;cdecl;external dllib name 'dladdr';