tools/winegcc solaris options linker patch

Ben Taylor sol11x86 at comcast.net
Sat May 5 13:33:58 CDT 2007


This patch adds two options to tools/winegcc to allow Solaris linker flags to be 
passed through and recognized.

Prior to this patch, libraries compiled with winegcc (despite overloading every
link related env variable I could think of), had a single RPATH when evaulated
with elfdump (which was the primary library from the compiler).  The effect
was that I was required to set an LD_LIBRARY_PATH prior to running any of
the wine applications, since the RPATH was not fully populated in the libraries.  
Despite the wine executable having the right set of RPATH's, the problem 
on Solaris is that libraries do not inherit the RPATH from a calling binary.

With this patch, and proper configuration of LDFLAGS, I am now able to
build wine on Solaris without having to resort to an LD_LIBRARY_PATH 
when I run wine or other wine related binaries.

The two flags that are added to winegcc.c are:

-R <libdir>

-z <linker flags>

(-z allows me to control the link phase a little better for performance 
reasons).

Thanks to Steleman who quickly recognized the problem, and showed
me how to  look at the problem explicitly, giving me the insight on how
to fix this problem.

Ben
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/octet-stream
Size: 1008 bytes
Desc: not available
Url : http://www.winehq.org/pipermail/wine-patches/attachments/20070505/171b966f/attachment.obj


More information about the wine-patches mailing list