On 01-08-17 22:16, Johnson Jones wrote:
nvm, the file exists.  Why it is not being found is unknown.

I did some stuff and it says it is not a valid win32, this is using that gtk3 runtime I linked to... says it's x64 version but probably x86.

Would be nice if the error message printed the full path of what was being loaded so it's quicker to diagnose.

Seems there is a

> ... code ...

which is used, could I just hijack this to set the correct path based on what version it is compiled under? Would be the easiest thing, at least as a temporary workaround.


You renamed the gtk DLL's, i assume you simply renamed them, but to get things working with different names you would need to build GTK from source, and apply the appropriate patches to GTK and its make files.

If you would use a dependency walker on libgtk-3-0.dll you can see that it depends on basically all the other dll's in the directory, and by renaming them they can no longer be found. For libraries that are in both GTK 3 and GTK 2 it might find the libraries distributed with gtksharp but that would also fail because of the version difference.

Printing the full path of the library in the error would only only be possible if we call LoadLibrary with the full path. It's been a while since i implemented the architecture check but if i remember correctly there were some issues with that. Otherwise it might be loaded from one of the other directories LoadLibrary searches, and then the printed path would be wrong, making things even worse.

And yes you could hard code the path that is passed to SetDllDirectory as a work around, but the dll's will need to have there proper names.

--
Mike Wey

Reply via email to