GNOME Bugzilla – Bug 724890
GI shlib resolution on W32 is basically non-existent
Last modified: 2015-02-07 16:52:33 UTC
GI just adds '.dll' to library name and calls it a day. There's a comment about how this function might work, i've used it to implement something better. This requires a compiler that supports -print-search-dirs argument (i.e. gcc) and a dlltool.
Created attachment 269918 [details] [review] Fix shlib resolution on W32
Review of attachment 269918 [details] [review]: Cool, this looks like it was quite nontrivial to implement. Thanks for the patch! I just cleaned it up to make the pep8 checks happy.
Hi, Unfortunately I am going to have to reopen this bug as this seems that it is very likely going to break to MSVC builds of building the introspection files. Please let me know whether I should post patches in this bug (as it would serve the same purpose, if doable), or should I open another bug. With blessings, thank you!
Created attachment 270093 [details] [review] Make shlib resolution on Windows also work with Visual C++ builds Hi, This patch fixes the build of introspection files with Visual C++ builds, with the shlib resolution functionality for Windows also provided for the Visual C++ builds. Basically what happens there is that Visual C++/Windows SDK ships with a dumpbin utility where one can use it with dumpbin -symbols something.lib, and it will return some info about something.lib, including the DLL that the .lib file is linked to, and the paths where the linker looks for the .lib file(s) is determined by the LIB environment variable. This means that shlib resolution would also be supported with Visual C++ builds as well. --- Hi LRN, can you please check whether this patch does not break for you on the GCC/MinGW side? --- Hi Colin, As it seems that we have better support for Windows for g-i, can we also commit Dieter's patch at bug 620566 comment 5 ("Make g-ir-annotiotion-tool, g-ir-doc-tool and g-ir-scanner 'relocatable' at runtime") in too, as that patch would be really helpful for Windows builds of g-i, whether one that is built with MinGW/GCC or Visual C++? Sorry to bug you on this... With blessings, thank you!
Yeah, this works for me. As for relocatability, there's also bug 724885
(In reply to comment #4) > As it seems that we have better support for Windows for g-i, can we also commit > Dieter's patch at bug 620566 comment 5 ("Make g-ir-annotiotion-tool, > g-ir-doc-tool and g-ir-scanner 'relocatable' at runtime") in too, as that patch > would be really helpful for Windows builds of g-i, whether one that is built > with MinGW/GCC or Visual C++? Sorry to bug you on this... BTW, I don't consider myself the sole maintainer here - anyone who feels qualified to review should go ahead and review! So Chun-Wei or LRN, if either of you wanted to approve Dieter's patch, please go ahead. I obviously would still want to be involved for core things like changes to the typelib format, but for Windows builds - please let's have it be a cooperative and equal effort!
Review of attachment 270093 [details] [review]: Hello, Thanks for the feedback, since things seem alright, I am pushing the patch anyways, as f3128da2. I will close this bug at this point. With blessings, thank you!
[Mass-moving gobject-introspection tickets to its own Bugzilla product - see bug 708029. Mass-filter your bugmail for this message: introspection20150207 ]