Unix/Linux StaticBuilds are broken

VERIFIED FIXED

Status

()

Firefox
Build Config
VERIFIED FIXED
15 years ago
15 years ago

People

(Reporter: Roland Mainz, Assigned: Brian Ryner (not reading))

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments, 4 obsolete attachments)

(Reporter)

Description

15 years ago
Unix/Linux StaticBuilds (--disable-shared --enable-static) seems to be broken
since a few days (log is from 2003-06-11-08-trunk):
-- snip --
/opt/SUNWspro/bin/CC -o MozillaFirebird-bin -I/usr/openwin/include
-xbuiltin=%all -mt  -DNDEBUG -DTRIMMED -xO2  nsBrowserApp.o nsStaticComponents.o
-xildoff -zlazyload -zcombreloc    -L../../dist/bin -L../../dist/lib
-lxpcom_compat_c -lxpconnect -luconv -lucvmath -li18n -lctl -loji -lipcdc
-lnecko -lnecko2 -lpref -lcaps -lchrome -lrdf -lhtmlpars -lgfxxprint -lgfx_gtk
-limglib2 -lgkplugin -ljsdom -lwidget_gtk -lxremote_client -lgklayout -lmork
-ldocshell -lprofile -lnsprefm -lembedcomponents -lwebbrwsr -leditor -ltxmgr
-lcomposer -laccessibility -lnsappshell -lfileview -lmozfind -lxremoteservice
-lappcomps -ltoolkitcomps -lcookie -lwallet -lwalletviewers -lxmlextras -lp3p
-lautoconfig -ltransformiix -luniversalchardet -ltypeaheadfind -lwebsrvcs
-lpipboot -lpipnss -lpippki -lbrowsercomps -lunicharutil_s -lucvutil_s
-lmozpango -ljsj -lgtksuperwin -lgtkxtbin -lipcdutil_s -lipcdshared_s
-lipcdlock_s -ltransmngrcom_s -ltransmngr_s -lgfxshared_s -lxlibrgb -lxprintutil
-lgkgfx -lxulapp_s ../../dist/lib/libxulapp_s.a -L../../dist/bin -lmozjs
-L../../dist/bin -lxpcom  -lc
-L/shared/bigtmp2/mozilla/nightlybuild_castor_phoenix_nightly_2003-06-11-08-trunk/objdir_static_2003-06-11-08-trunk/dist/lib
-lplds4 -lplc4 -lnspr4 -lpthread -ldl -lrt  -L/usr/local/lib -L/usr/openwin/lib
-R/usr/openwin/lib -lgtk -lgdk -lgmodule -lglib -ldl -lXext -lX11 -lsocket -lnsl
-lm  -lsocket -ldl -lm  -L../../dist/lib/components -L../../dist/lib -lmozpng
-L../../dist/lib -lmozjpeg -L../../dist/lib -lmozz  -L../../dist/bin
-L../../dist/lib ../../dist/lib/libcrmf.a -lsmime3 -lssl3 -lnss3 -lsoftokn3  
-L/usr/openwin/lib -R/usr/openwin/lib -lXt -L/usr/openwin/lib -R/usr/openwin/lib
-lXp -lXext -lX11 -L../../dist/lib -lxpcom_compat    
ld: fatal: library -lxpcom_compat_c: not found
ld: fatal: library -lxpconnect: not found
ld: fatal: library -luconv: not found
ld: fatal: library -lucvmath: not found
ld: fatal: library -li18n: not found
ld: fatal: library -lctl: not found
ld: fatal: library -loji: not found
ld: fatal: library -lipcdc: not found
ld: fatal: library -lnecko: not found
ld: fatal: library -lnecko2: not found
ld: fatal: library -lpref: not found
ld: fatal: library -lcaps: not found
ld: fatal: library -lchrome: not found
ld: fatal: library -lrdf: not found
ld: fatal: library -lhtmlpars: not found
ld: fatal: library -lgfxxprint: not found
ld: fatal: library -lgfx_gtk: not found
ld: fatal: library -limglib2: not found
ld: fatal: library -lgkplugin: not found
ld: fatal: library -ljsdom: not found
ld: fatal: library -lwidget_gtk: not found
ld: fatal: library -lxremote_client: not found
ld: fatal: library -lgklayout: not found
ld: fatal: library -lmork: not found
ld: fatal: library -ldocshell: not found
ld: fatal: library -lprofile: not found
ld: fatal: library -lnsprefm: not found
ld: fatal: library -lembedcomponents: not found
ld: fatal: library -lwebbrwsr: not found
ld: fatal: library -leditor: not found
ld: fatal: library -ltxmgr: not found
ld: fatal: library -lcomposer: not found
ld: fatal: library -laccessibility: not found
ld: fatal: library -lnsappshell: not found
ld: fatal: library -lfileview: not found
ld: fatal: library -lmozfind: not found
ld: fatal: library -lxremoteservice: not found
ld: fatal: library -lappcomps: not found
ld: fatal: library -ltoolkitcomps: not found
ld: fatal: library -lcookie: not found
ld: fatal: library -lwallet: not found
ld: fatal: library -lwalletviewers: not found
ld: fatal: library -lxmlextras: not found
ld: fatal: library -lp3p: not found
ld: fatal: library -lautoconfig: not found
ld: fatal: library -ltransformiix: not found
ld: fatal: library -luniversalchardet: not found
ld: fatal: library -ltypeaheadfind: not found
ld: fatal: library -lwebsrvcs: not found
ld: fatal: library -lpipboot: not found
ld: fatal: library -lpipnss: not found
ld: fatal: library -lpippki: not found
ld: fatal: library -lbrowsercomps: not found
ld: fatal: File processing errors. No output written to MozillaFirebird-bin
gmake[3]: *** [MozillaFirebird-bin] Error 1
gmake[3]: Leaving directory
`/shared/bigtmp2/mozilla/nightlybuild_castor_phoenix_nightly_2003-06-11-08-trunk/objdir_static_2003-06-11-08-trunk/browser/app'
gmake[2]: *** [libs] Error 2
gmake[2]: Leaving directory
`/shared/bigtmp2/mozilla/nightlybuild_castor_phoenix_nightly_2003-06-11-08-trunk/objdir_static_2003-06-11-08-trunk/browser'
gmake[1]: *** [tier_99] Error 2
gmake[1]: Leaving directory
`/shared/bigtmp2/mozilla/nightlybuild_castor_phoenix_nightly_2003-06-11-08-trunk/objdir_static_2003-06-11-08-trunk'
gmake: *** [default] Error 2
-- snip --
(Reporter)

Comment 1

15 years ago
It seems that the *.a archives for the single components reside in
objdir/dist/lib/components/ but are not picked-up anymore:
-- snip --
% objdir_static_2003-06-11-08-trunk% find dist | egrep
"(xpcom_compat_c|xpconnect|uconv)\.a"
dist/lib/components/libxpcom_compat_c.a
dist/lib/components/libxpconnect.a
dist/lib/components/libuconv.a
-- snip --
(Reporter)

Comment 2

15 years ago
Created attachment 125467 [details]
Full build log, gzipped
(Reporter)

Updated

15 years ago
Attachment #125467 - Attachment is patch: false
Attachment #125467 - Attachment mime type: text/plain → application/octet-stream
(Reporter)

Comment 3

15 years ago
It seems the problem is caused by the problem that the
-L../../dist/lib/components comes _AFTER_ the libraries which should be linked.
This will not work for compilers/linkers who enforce linker search path order as
specified in the command line.
(Reporter)

Comment 4

15 years ago
Created attachment 125476 [details]
Modified 2003-06-11-08-trunk mozilla/browser/app/Makefile.in (can't provide CVS diff, network on drugs... ;-( )
(Reporter)

Comment 5

15 years ago
Created attachment 125477 [details]
Modified 2003-06-11-08-trunk mozilla/browser/app/Makefile.in (can't provide CVS diff, network on drugs... ;-( )

Sorry, previous file was the wrong one... ;-(
Attachment #125476 - Attachment is obsolete: true
(Reporter)

Comment 6

15 years ago
Created attachment 125479 [details] [diff] [review]
Patch for 2003-06-11-08-trunk
Attachment #125477 - Attachment is obsolete: true
(Reporter)

Comment 7

15 years ago
Comment on attachment 125479 [details] [diff] [review]
Patch for 2003-06-11-08-trunk

Requesting r= for the hack...
Attachment #125479 - Flags: review?(bryner)
(Assignee)

Comment 8

15 years ago
Comment on attachment 125479 [details] [diff] [review]
Patch for 2003-06-11-08-trunk

I don't really like this fix.  It looks to me like we should add
-L$(DIST)/bin/components to the beginning of STATIC_EXTRA_DSO_LIBS in
static-config.mk, line 41.  Since STATIC_EXTRA_LIBS is intended to be part of
EXTRA_LIBS, it'll always come after STATIC_EXTRA_DSO_LDOPTS, so the -L there
isn't sufficient.
Attachment #125479 - Flags: review?(bryner) → review-
(Reporter)

Comment 9

15 years ago
Brian Ryner wrote:
> (From update of attachment 125479 [details] [diff] [review])
> I don't really like this fix. 

/me ,too - that's why I called it a "hack" in comment #7 ... :)

> It looks to me like we should add
> -L$(DIST)/bin/components to the beginning of STATIC_EXTRA_DSO_LIBS in
> static-config.mk, line 41.  Since STATIC_EXTRA_LIBS is intended to be part of
> EXTRA_LIBS, it'll always come after STATIC_EXTRA_DSO_LDOPTS, so the -L there
> isn't sufficient.

Well, the patch solves the problem and gets the staticbuild back to live.

Do you have a better suggestion what we can do ?
(Assignee)

Comment 10

15 years ago
Yes, I just told you what it was.  Add -L$(DIST)/bin/components to the beginning
of STATIC_EXTRA_DSO_LIBS in static-config.mk, line 41.
(Reporter)

Comment 11

15 years ago
Brian Ryner wrote:
> Yes, I just told you what it was.  Add -L$(DIST)/bin/components to the

Don't you mean -L$(DIST)/lib/components ?

> beginning of STATIC_EXTRA_DSO_LIBS in static-config.mk, line 41.

That does not work, all stuff in STATIC_EXTRA_DSO_LIBS gets a "-l" put in front
of each element:
-- snip --
/opt/SUNWspro/bin/CC -o MozillaFirebird-bin -I/usr/openwin/include
-xbuiltin=%all -mt  -DNDEBUG -DTRIMMED -xO2  nsBrowserApp.o nsStaticComponents.o
-xildoff -zlazyload -zcombreloc    -L../../dist/bin -L../../dist/lib
-l-L../../dist/bin/components -lxpcom_compat_c -lxpconnect -luconv -lucvmath
-li18n -lctl -loji -lipcdc -lnecko -lnecko2 -lpref -lcaps -lchrome -lrdf
-lhtmlpars -lgfxxprint -lgfx_gtk -limglib2 -lgkplugin -ljsdom -lwidget_gtk
-lxremote_client -lgklayout -lmork -ldocshell -lprofile -lnsprefm
-lembedcomponents -lwebbrwsr -leditor -ltxmgr -lcomposer -laccessibility
-lnsappshell -lfileview -lmozfind -lxremoteservice -lappcomps -ltoolkitcomps
-lcookie -lwallet -lwalletviewers -lxmlextras -lp3p -lautoconfig -ltransformiix
-luniversalchardet -ltypeaheadfind -lwebsrvcs -lpipboot -lpipnss -lpippki
-lbrowsercomps -lunicharutil_s -lucvutil_s -lmozpango -ljsj -lgtksuperwin
-lgtkxtbin -lipcdutil_s -lipcdshared_s -lipcdlock_s -ltransmngrcom_s
-ltransmngr_s -lgfxshared_s -lxlibrgb -lxprintutil -lgkgfx -lxulapp_s
../../dist/lib/libxulapp_s.a -L../../dist/bin -lmozjs -L../../dist/bin -lxpcom 
-lc
-L/shared/bigtmp2/mozilla/nightlybuild_castor_phoenix_nightly_2003-06-11-08-trunk/objdir_static_2003-06-11-08-trunk/dist/lib
-lplds4 -lplc4 -lnspr4 -lpthread -ldl -lrt  -L/usr/local/lib -L/usr/openwin/lib
-R/usr/openwin/lib -lgtk -lgdk -lgmodule -lglib -ldl -lXext -lX11 -lsocket -lnsl
-lm  -lsocket -ldl -lm  -L../../dist/lib/components -L../../dist/lib -lmozpng
-L../../dist/lib -lmozjpeg -L../../dist/lib -lmozz  -L../../dist/bin
-L../../dist/lib ../../dist/lib/libcrmf.a -lsmime3 -lssl3 -lnss3 -lsoftokn3  
-L/usr/openwin/lib -R/usr/openwin/lib -lXt -L/usr/openwin/lib -R/usr/openwin/lib
-lXp -lXext -lX11 -L../../dist/lib -lxpcom_compat    
ld: fatal: library -l-L../../dist/bin/components: not found
ld: fatal: library -lxpcom_compat_c: not found
[etc. etc.]
-- snip --
(Reporter)

Comment 12

15 years ago
Created attachment 125625 [details] [diff] [review]
New patch for 2003-06-11-08-trunk
(Reporter)

Updated

15 years ago
Attachment #125479 - Attachment is obsolete: true
(Reporter)

Comment 13

15 years ago
Created attachment 125626 [details] [diff] [review]
New patch for 2003-06-11-08-trunk

(sorry, previous file was the wrong one)
Attachment #125625 - Attachment is obsolete: true
(Reporter)

Comment 14

15 years ago
Comment on attachment 125626 [details] [diff] [review]
New patch for 2003-06-11-08-trunk

Hopefully this one is slighly better... :)
Attachment #125626 - Flags: review?(bryner)
(Reporter)

Comment 15

15 years ago
bryner:
Can you review the patch, please ?
(Assignee)

Comment 16

15 years ago
Ok, thinking about this some more...

I don't believe we should always add -L$(DIST)/lib/components.  We should do it
only when we're actually linking against static components.  I'm a bit
disappointed that there isn't really a good place to insert this in
static-config.mk.  But I think the next best thing is to put it in
browser/app/Makefile.in (and xpfe/bootstrap/Makefile.in) as you'd done before. 
I don't see the need for a separate STATIC_COMPONENTS_LINKER_PATH variable
though, just do:

ifdef BUILD_STATIC_LIBS
EXTRA_DSO_LDOPTS = -L$(DIST)/lib/components
endif

EXTRA_DSO_LDOPTS += \
                  $(EXTRA_DSO_LIBS) \
etc
(Reporter)

Comment 17

15 years ago
Brian Ryner wrote:
> But I think the next best thing is to put it in
> browser/app/Makefile.in (and xpfe/bootstrap/Makefile.in) as you'd done before. 
> I don't see the need for a separate STATIC_COMPONENTS_LINKER_PATH variable
> though, just do:

The idea behind that was to make it clear that there is a special case which is
handeled specially... ;-/

Should I file a new patch or is the current one sufficient for now ?
(Assignee)

Comment 18

15 years ago
Comment on attachment 125479 [details] [diff] [review]
Patch for 2003-06-11-08-trunk

If you want, sure... this patch is fine.
Attachment #125479 - Flags: review- → review+
(Assignee)

Updated

15 years ago
Attachment #125626 - Flags: review?(bryner)
(Reporter)

Comment 19

15 years ago
Brian Ryner wrote:
> (From update of attachment 125479 [details] [diff] [review])
> If you want, sure... this patch is fine.

Thanks! :)

Can you check the patch "in", please ?
(Assignee)

Comment 20

15 years ago
checked in, with the minor change of changing ../../dist/ to $(DIST)/.  Also
ported to xpfe/bootstrap/Makefile.in.
Status: NEW → RESOLVED
Last Resolved: 15 years ago
Resolution: --- → FIXED
verified.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.