Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 17 Jul 2003 07:56:58 +1000
From:      Peter Jeremy <peter.jeremy@alcatel.com.au>
To:        freebsd-alpha@freebsd.org
Subject:   Problem building Mozilla
Message-ID:  <20030716215658.GA43409@gsmx07.alcatel.com.au>

next in thread | raw e-mail | index | archive | help
My attempts to build Mozilla on a quad-CPU AS4100 running a
locally-built copy of 5.1-RELEASE consistently fail, ending:

gmake[3]: Entering directory `/usr/ports/www/mozilla/work/mozilla/embedding/browser/gtk/tests'
TestGtkEmbed.cpp
c++ -o TestGtkEmbed.o -c -DOSTYPE=\"FreeBSD5\" -DOSARCH=\"FreeBSD\"  -I../../../../dist/include/xpcom -I../../../../dist/include/string -I../../../../dist/include/dom -I../../../../dist/include/gtkembedmoz -I../../../../dist/include -I/usr/ports/www/mozilla/work/mozilla/dist/include/nspr  -I/usr/local/include -I/usr/local/include -I/usr/local/include  -I/usr/X11R6/include   -fPIC  -I/usr/X11R6/include  -I/usr/X11R6/include -fno-rtti -fno-exceptions -Wall -Wconversion -Wpointer-arith -Wcast-align -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy -Wno-long-long -O -pipe -mcpu=ev56 -mieee -fshort-wchar -pipe  -DNDEBUG -DTRIMMED -I/usr/X11R6/include/gtk12 -I/usr/local/include/glib12 -I/usr/local/include -I/usr/X11R6/include   -I/usr/X11R6/include  -I/usr/X11R6/include -DMOZILLA_CLIENT -include ../../../../mozilla-config.h TestGtkEmbed.cpp
c++  -I/usr/X11R6/include  -I/usr/X11R6/include -fno-rtti -fno-exceptions -Wall -Wconversion -Wpointer-arith -Wcast-align -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy -Wno-long-long -O -pipe -mcpu=ev56 -mieee -fshort-wchar -pipe  -DNDEBUG -DTRIMMED -I/usr/X11R6/include/gtk12 -I/usr/local/include/glib12 -I/usr/local/include -I/usr/X11R6/include  -o TestGtkEmbed TestGtkEmbed.o   -L../../../../dist/bin -L../../../../dist/lib -lgtkembedmoz -lgtksuperwin  -lm  -L../../../../dist/bin -lmozjs -L../../../../dist/bin -lxpcom -L../../../../dist/bin -L/usr/ports/www/mozilla/work/mozilla/dist/lib -lplds4 -lplc4 -lnspr4 -pthread  -L/usr/X11R6/lib -L/usr/X11R6/lib -lgtk12 -lgdk12 -L/usr/local/lib -Wl,-E -lgmodule12 -lglib12 -lintl -lXi -lXext -lX11 -lm    
strip TestGtkEmbed
../../../../config/nsinstall -R -m 755 TestGtkEmbed ../../../../dist/bin
gmake[3]: Leaving directory `/usr/ports/www/mozilla/work/mozilla/embedding/browser/gtk/tests'
gmake[2]: Leaving directory `/usr/ports/www/mozilla/work/mozilla/embedding/browser/gtk'
gmake[1]: Leaving directory `/usr/ports/www/mozilla/work/mozilla'
/usr/bin/sed -e "s|%%PREFIX%%|/usr/X11R6|g" -e "s|%%MOZILLA%%|mozilla|g"  /usr/ports/www/mozilla/files/mozilla.sh >/usr/ports/www/mozilla/work/mozilla/mozilla
(cd /usr/ports/www/mozilla/work/mozilla/dist/bin;  /usr/bin/env LD_LIBRARY_PATH=. MOZILLA_FIVE_HOME=. ./regxpcom;  /usr/bin/env LD_LIBRARY_PATH=. MOZILLA_FIVE_HOME=. ./regchrome;  /usr/bin/touch ./chrome/user-skins.rdf ./chrome/user-locales.rdf)
Segmentation fault
*** Error code 139

Stop in /usr/ports/www/mozilla.

The failing program is regxpcom and it leaves an empty core file in
/usr/ports/www/mozilla/work/mozilla/dist/bin

Running regxpcom under gdb gives:
# cd /usr/ports/www/mozilla/work/mozilla/dist/bin
# /usr/bin/env LD_LIBRARY_PATH=. MOZILLA_FIVE_HOME=. gdb ./regxpcom
GNU gdb 5.2.1 (FreeBSD)
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "alpha-undermydesk-freebsd"...
(no debugging symbols found)...
(gdb) run
Starting program: /usr/ports/www/mozilla/work/mozilla/xpcom/tools/registry/regxpcom 
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
(no debugging symbols found)...(no debugging symbols found)...
[deleted]
(no debugging symbols found)...
Program received signal SIGSEGV, Segmentation fault.
0x162b0cfdc in Double::toString(double, nsAString&) ()
   from /usr/ports/www/mozilla/work/mozilla/dist/bin/components/libtransformiix.so
(gdb) where
#0  0x162b0cfdc in Double::toString(double, nsAString&) ()
   from /usr/ports/www/mozilla/work/mozilla/dist/bin/components/libtransformiix.so
warning: Hit heuristic-fence-post without finding
warning: enclosing function for address 0x160032600
This warning occurs if you are debugging a function without any symbols
(for example, in a stripped executable).  In that case, you may wish to
increase the size of the search with the `set heuristic-fence-post' command.

Otherwise, you told GDB there was a function where there isn't one, or
(more likely) you have encountered a bug in GDB.
(gdb) info regi
v0             0x0      0
t0             0x162b716a4      5951133348
t1             0x1      1
t2             0x1      1
t3             0x1      1
t4             0x20003a 2097210
t5             0x0      0
t6             0xebc7   60359
t7             0xfffffc0000714000       -4398039089152
s0             0xffff   65535
s1             0x1      1
s2             0x1200e8f80      4832792448
s3             0x1      1
s4             0x16287f210      5948043792
s5             0x1      1
fp             0x11ffedc8       301985224
a0             0x2      2
a1             0x11ffed88       301985160
a2             0x3      3
a3             0x0      0
a4             0x0      0
a5             0x11ffecd8       301984984
t8             0x1e     30
t9             0x1602ed2f8      5908648696
t10            0x8      8
t11            0x107    263
ra             0x162b0cfac      5950721964
t12            0xfffffc00003f2160       -4398042373792
at             0xfffffe0039d8be58       -2198052749736
gp             0x162b92ca8      5951270056
sp             0x11ffed98       301985176
zero           0x0      0
fpcr           0x6800000000000000       7493989779944505344
pc             0x162b0cfdc      5950722012
vfp            0x11ffee58       301985368
(gdb) disas
[deleted]
0x162b0cfd4 <_ZN6Double8toStringEdR9nsAString+2036>:    ldq     t0,-22776(gp)
0x162b0cfd8 <_ZN6Double8toStringEdR9nsAString+2040>:    ldt     $f10,0(t0)
0x162b0cfdc <_ZN6Double8toStringEdR9nsAString+2044>:    ldq     t0,-30760(gp)
0x162b0cfe0 <_ZN6Double8toStringEdR9nsAString+2048>:    stt     $f10,0(t0)
[deleted]

One problem is that $t0 is only aligned to 32-bits whereas ldt needs
64-bit alignment - but this should cause a SIGBUS not SIGSEGV.  I'm
not sure how to get gdb to show the process memory mappings but gdb
has no problem accessing the doubleword at 0($t0).

In any case, uac indicates that unaligned accesses should be fixed
up (and printed) - though nothing is printed.

FWIW, relevant parts of /etc/make.conf are:
CPUTYPE=ev56
CFLAGS= -O -pipe

I'm having another try without the "CPUTYPE=ev56" but it will be
another 6-7 hours before I find if that helps.

Can anyone offer any insights?

Peter



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030716215658.GA43409>