On 03/20/2016 12:56 AM, fredvs wrote: > Re-hello (and last for tonight). > > Yep, yep, yep. > > Replacing all GetProcedureAdress() with dlsym() > > DOES THE TRICK ! ;-)
Uhm, are you sure about this? I always thought GetProcedureAddress simply calls through to dlsym. If one works and the other doesn't, this needs some more investigation I think? Also, in you last example, quoted here: -------------------------------------- Now with DynLibs: procedure loadmylib(lib : pchar); var ap1: pointer; hn : integer; ' begin /// with dynlibs hn := dynlibs.loadlibrary(Pchar(lib)); if hn <> 0 then writeln('loadlibrary() is OK') else writeln('loadlibrary() is NOT OK') ; ap1 := getprocedureaddress(hn, Pchar('mp4ff_open_read'); ****INDICATED POSITION**** if ap1 <> nil then writeln('getprocedureaddress() is OK') else writeln('getprocedureaddress() is NOT OK') ; end; -------------------------------------- Could you add a "writeln(dlerror());" ate the "****INDICATED POSITION****"? Just curious about what is going on here... PS: Why do you use "hn: Integer" instead of "hn: TLibHandle"? I don't know if it can be assumed that this handle will always be an integer (think, for example, pointer)? Just a thought. -- Ewald _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal