Comment 2 for bug 61104

Revision history for this message
FredBezies (fredbezies-deactivatedaccount) wrote : Re: Build process of firefox trunk is broken using gcc 4.1.1 with some "undefined reference"

Tried again with the newer version of gcc (gcc version 4.1.2 20060920 (prerelease) (Ubuntu 4.1.1-13ubuntu3))

I remove static build options (ie : no more --disable-shared - enable-static options), and it is still crashing, again related to undefined references. Sooner than before.

Here is the end of the build process, before crashing :

rm -f libxpconnect.so
c++ -fno-rtti -fno-exceptions -Wall -Wconversion -Wpointer-arith -Wcast-align -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy -Wno-non-virtual-dtor -Wno-long-long -fshort-wchar -pthread -pipe -DNDEBUG -DTRIMMED -O3 -pipe -w -fno-strict-aliasing -fPIC -shared -Wl,-z,defs -Wl,-h,libxpconnect.so -o libxpconnect.so nsScriptError.o nsXPConnect.o xpccallcontext.o xpccomponents.o xpccontext.o xpcconvert.o xpcdebug.o xpcexception.o xpcjsid.o xpcjsruntime.o xpclog.o xpcmaps.o xpcmodule.o xpcruntimesvc.o xpcstack.o xpcstring.o xpcthreadcontext.o xpcthrower.o xpcwrappedjs.o xpcvariant.o xpcwrappedjsclass.o xpcwrappednative.o xpcwrappednativeinfo.o xpcwrappednativejsops.o xpcwrappednativeproto.o xpcwrappednativescope.o XPCNativeWrapper.o -lpthread -Wl,--whole-archive ../loader/libjsloader_s.a -Wl,--no-whole-archive -L../../../../dist/bin -lxpcom -lxpcom_core -L../../../../dist/bin -L../../../../dist/lib -lplds4 -lplc4 -lnspr4 -lpthread -ldl -L../../../../dist/bin -lmozjs -Wl,--version-script -Wl,../../../../build/unix/gnu-ld-scripts/components-version-script -Wl,-Bsymbolic -ldl -lm
nsXPConnect.o:(.data.rel.ro._ZTV11nsXPConnect[vtable for nsXPConnect]+0xc4): référence indéfinie vers « nsSupportsWeakReference::GetWeakReference(nsIWeakReference**) »
xpcruntimesvc.o:(.data.rel.ro._ZTV22nsJSRuntimeServiceImpl[vtable for nsJSRuntimeServiceImpl]+0x38): référence indéfinie vers « nsSupportsWeakReference::GetWeakReference(nsIWeakReference**) »
xpcthreadcontext.o:(.data.rel.ro._ZTV29nsXPCThreadJSContextStackImpl[vtable for nsXPCThreadJSContextStackImpl]+0x48): référence indéfinie vers « nsSupportsWeakReference::GetWeakReference(nsIWeakReference**) »
xpcwrappedjs.o: In function `nsXPCWrappedJS::GetWeakReference(nsIWeakReference**)':
xpcwrappedjs.cpp:(.text+0x22a): référence indéfinie vers « nsSupportsWeakReference::GetWeakReference(nsIWeakReference**) »
collect2: ld returned 1 exit status
make[5]: *** [libxpconnect.so] Erreur 1
make[5]: quittant le répertoire « /home/fred/logs/mozilla/js/src/xpconnect/src »
make[4]: *** [libs] Erreur 2
make[4]: quittant le répertoire « /home/fred/logs/mozilla/js/src/xpconnect »
make[3]: *** [libs_tier_gecko] Erreur 2
make[3]: quittant le répertoire « /home/fred/logs/mozilla »
make[2]: *** [tier_gecko] Erreur 2
make[2]: quittant le répertoire « /home/fred/logs/mozilla »
make[1]: *** [default] Erreur 2

I think that the important part is :

"xpcthreadcontext.o:(.data.rel.ro._ZTV29nsXPCThreadJSContextStackImpl[vtable for nsXPCThreadJSContextStackImpl]+0x48): référence indéfinie vers « nsSupportsWeakReference::GetWeakReference(nsIWeakReference**) »
xpcwrappedjs.o: In function `nsXPCWrappedJS::GetWeakReference(nsIWeakReference**)':
xpcwrappedjs.cpp:(.text+0x22a): référence indéfinie vers « nsSupportsWeakReference::GetWeakReference(nsIWeakReference**) »
collect2: ld returned 1 exit status"

Of course, build process with same source code is ok with gcc 4.0.

It would a real pain-in-the-*** if I have to install gcc 4.0 to build a trunk based firefox under edgy eft. Sorry for not being more helpful.