http://bugs.winehq.org/show_bug.cgi?id=15878
--- Comment #15 from Edward d'Auvergne true.bugman@gmail.com 2008-11-03 16:20:09 --- Could the problem be that the Windows DLL loader searches the path of the binary for the libraries as a last resort (they are located in C:\Program Files\Gimp-2.0\bin if installed in the default location), whereas the Wine DLL loader does not?
This is a bit hard to test out, as getting wine to compile on a 64-bit system is a nightmare. From first looks, the calls to the fixup_imports() function in dlls/ntdll/loader.c doesn't seem to be right or at least it doesn't seem to be exactly as described at http://msdn.microsoft.com/en-us/magazine/cc301727.aspx. I would guess that following the exact order in this documentation doesn't matter too much. Or maybe this documentation of the loader from Win2000 is a bit old. Anyway, should there be a LdrpCheckForLoadedDll or LdrCheckForLoadedDll function used here to resolve this path issue? Or does fixup_imports() do this work?