Closed Bug 23759 Opened 26 years ago Closed 17 years ago

add "-z text" to DSO_LDOPTS for solaris/workshop

Categories

(SeaMonkey :: Build Config, defect, P3)

Sun
Solaris

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: dmosedale, Assigned: khl)

References

Details

By default, the solaris linker is willing to link non-PIC code into shared libraries. If someone has their LD_LIBRARY_PATH set in an unusual way, this can cause errors that are subtle and difficult to track down. Adding "-z text" to DSO_LDOPTS on solaris will instead cause the linker to abort if it stumbles across non-PIC code while linking a shared library.
This seems to cause problems with gcc. Under investigation.
Status: NEW → ASSIGNED
This currently breaks gcc builds, so it's not yet checked in. Here's a link to the libraries and linker documentation for Solaris: http://docs.sun.com:80/ab2/coll.45.4/LLM/
Turns out that gcc builds didn't have the -fPIC flag set when using gcc as the assembler, and the machines that we were using had libg++ only installed statically. So plenty of non-PIC code was getting included, including the xptcall assembly. I'm gonna post a patch to configure.in that will both add "-z text" and fix the assembler problem to mozilla-unix for comment, probably tommorrow.
Oh yeah, we were also using -G instead of -shared in the DSO_LDFLAGS on gcc as well. My patch will get that too.
Blocks: 13202
In order to make this easier to get into the tree piecemeal, I've split this out into three separate bugs. This bug is now for WorkShop builds only, bug 35419 is for gcc builds, and bug 35418 is a prerequisite to the gcc fix.
Summary: add "-z text" to DSO_LDOPTS for solaris → add "-z text" to DSO_LDOPTS for solaris/workshop
mass re-assign of all bugs where i was listed as the qa contact
QA Contact: cyeh → chofmann
Reassigning Solaris-specific bugs to richb.
Assignee: dmose → rich.burridge
Status: ASSIGNED → NEW
[richb - 6/1/00] Reassigning bug to Sherry Shen.
Assignee: rich.burridge → sherry.shen
Wrong bug. Sorry Sherry. Reassigning back to me.
Assignee: sherry.shen → rich.burridge
Status: NEW → ASSIGNED
Reassigning to Ed to do with as he wants.
Assignee: rich.burridge → edburns
Status: ASSIGNED → NEW
I'll ask our RE person to look at this.
Status: NEW → ASSIGNED
Hi Kevin, This one looks pretty easy. Please comment. Thanks, Ed
Assignee: edburns → khl
Status: ASSIGNED → NEW
Switching to using -shared instead of -G (bug 35419) apparently enabled -z text as well. This is causing problems on a couple of our tinderboxes. Bismark (solaris/x86/egcs 1.03) & speedracer (solaris/sparc/gcc 2.95.3) are complaining that 'relocations against non-writable, allocatable sections remain' when attempting to link at least libmoz_libart_lgpl.so & libgklayout.so . For now, I'm going to attempt to use '-z textwarn' with -shared so that the tree will build again.
Product: Browser → Seamonkey
Gin, is this bug still valid? Can I assign this to you?
Not required. Usually LD_LIBRARY_PATH should not be set in building time or running time. IMHO: User should take care of LD_LIBRARY_PATH by themselves. Otherwise the build result is crappy anyway.
Status: NEW → RESOLVED
Closed: 17 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.