On Wed, Apr 18, 2012 at 8:56 PM, Srinivas Cherukumilli <
vasu_c@...> wrote:
> Hi,
>
> We are running into issues trying to load dll's into a program that has been compiled with Visual Studio. We invariably get the "Invalid access to memory location" error while trying to load the dll. It appears that the dll created using mingw gcc-4.2.1 is not relocatable. btw, we are using MSVCR90 and not MSVCRT and this shows up on Windows XP but not Windows 7.
>
> Followed the instructions mentioned from this article:
>
http://mirrors.zoreil.com/webclub.kcom.ne.jp/ma/colinp/win32/dll/make.html>
Based on colinp in the URL I'm guessing this is old stuff.
> gcc -mdll -o junk.tmp -Wl,--base-file,base.tmp bar.o
> del junk.tmp
> dlltool --dllname bar.dll --base-file base.tmp --output-exp temp.exp --def
> bar.def
> del base.tmp
> gcc -mdll -o bar.dll bar.o -Wl,temp.exp
> del temp.exp
>
You can simply use
gcc -shared -o bar.dll bar.o --out-implib libbar.dll.a
gcc -Wl,--relocatable -shared -o bar.dll bar.o --out-implib libbar.dll.a
> This did not help us either.
>
Hopefully the above should.
> Would appreciate any suggestions that helps resolve this issue.
>
Let us know if we helped.
--
Earnie
--
https://sites.google.com/site/earnieboyd------------------------------------------------------------------------------
For Developers, A Lot Can Happen In A Second.
Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
http://p.sf.net/sfu/Boundary-d2dvs2_______________________________________________
MinGW-users mailing list
MinGW-users@...
This list observes the Etiquette found at
http://www.mingw.org/Mailing_Lists.
We ask that you be polite and do the same. Disregard for the list etiquette may cause your account to be moderated.
_______________________________________________
You may change your MinGW Account Options or unsubscribe at:
https://lists.sourceforge.net/lists/listinfo/mingw-usersAlso: mailto:
mingw-users-request@...?subject=unsubscribe