GetModuleFileName mysteries

Alexandre Julliard julliard at winehq.org
Wed Dec 31 18:40:31 CST 2003


Boaz Harrosh <boaz at hishome.net> writes:

> Until recently 95% of the work was done on wine. WineLib was a side effect.
> Look what happens, if I have a "-wrap" application (C++) I need to
> place a link to it in WINEDLLPATH to even load. and also to all it's
> supporting DLLs (I know I have 36 of them). If any one is working on
> it, built in search should support both explicit Path loading, and
> executable directory. Same as native, Just that the PATH and
> system-folder changes to WINEDLLPATH. Once the built-in is found it's
> PATH should be recorded and later served on requests like
> GetModuleFileName and others.

It's not that easy, because system dlls have to be loaded from the
system directory, so you need GetModuleFileName to return that. It's
only for dlls loaded with a explicit path that you can try to return
the actual path to the .so file. Also with dlls loaded directly by the
Unix loader (which you probably need in C++) you don't have access to
the original path at all.

> And Alexandre welcome back. I hope you had a good time and a well
> deserved rest. It was kind of gloomy around here with out you.

Thanks; I certainly enjoyed spending two weeks without touching a
computer. I should do that more often <g>

-- 
Alexandre Julliard
julliard at winehq.com



More information about the wine-devel mailing list