Subject: toolchain/26515: libgcc.map in wrong directory
To: None <gnats-bugs@gnats.NetBSD.org>
From: None <Christoph_Egger@gmx.de>
List: netbsd-bugs
Date: 08/02/2004 11:09:05
>Number: 26515
>Category: toolchain
>Synopsis: libgcc.map in wrong directory
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: toolchain-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Mon Aug 02 13:34:00 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator: Christoph Egger
>Release: NetBSD 2.0_BETA
>Organization:
>Environment:
System: NetBSD phoenix.eggernet.de 2.0_BETA NetBSD 2.0_BETA (GENERIC) #0: Sat Jul 31 14:12:00 CEST 2004 root@phoenix.eggernet.de:/usr/objdir.sparc64/sys/arch/sparc64/compile/GENERIC sparc64
Architecture: sparc64
Machine: sparc64
>Description:
compiling the netbsd-2-0 fails with the command
./build.sh -O /usr/objdir.sparc64 -T /usr/toolchain/tooldir.NetBSD-2.0B-sparc64 -U distribution
/usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/sparc64--netbsd-gcc -O2 -Werror -I/usr/src-2.0/gnu/lib/libgcc3/libgcc
_s -I/usr/src-2.0/gnu/usr.bin/gcc3/arch/sparc64 -DIN_GCC -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -I/us
r/src-2.0/gnu/dist/gcc/gcc -I/usr/src-2.0/gnu/dist/gcc/gcc/. -I/usr/src-2.0/gnu/dist/gcc/gcc/config -I/usr/src-2.0/gnu/d
ist/gcc/gcc/../include -I. -I/usr/src-2.0/gnu/dist/gcc/gcc/cp -I/usr/src-2.0/gnu/lib/libstdc++-v3/arch/sparc64 -I. -no
stdinc -isystem /usr/objdir.sparc64/destdir.sparc64/usr/include -c -fPIC -DPIC -fexceptions -o unwind-sjlj.so /usr/src-2
.0/gnu/dist/gcc/gcc/unwind-sjlj.c
# build libgcc_s/libgcc_s_pic.a
rm -f libgcc_s_pic.a
/usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/sparc64--netbsd-ar cq libgcc_s_pic.a `NM=/usr/toolchain/tooldir.NetBSD-2.
0B-sparc64/bin/sparc64--netbsd-nm NM=/usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/sparc64--netbsd-nm MKTEMP=/usr/toolc
hain/tooldir.NetBSD-2.0B-sparc64/bin/nbmktemp /usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/nblorder _muldi3.so _negdi2
.so _lshrdi3.so _ashldi3.so _ashrdi3.so _ffsdi2.so _clz.so _cmpdi2.so _ucmpdi2.so _floatdidf.so _floatdisf.so _fixunsdfs
i.so _fixunssfsi.so _fixunsdfdi.so _fixdfdi.so _fixunssfdi.so _fixsfdi.so _fixxfdi.so _fixunsxfdi.so _floatdixf.so _fixu
nsxfsi.so _fixtfdi.so _fixunstfdi.so _floatditf.so _clear_cache.so _trampoline.so __main.so _exit.so _absvsi2.so _absvdi
2.so _addvsi3.so _addvdi3.so _subvsi3.so _subvdi3.so _mulvsi3.so _mulvdi3.so _negvsi2.so _negvdi2.so _ctors.so _divdi3.s
o _moddi3.so _udivdi3.so _umoddi3.so _udiv_w_sdiv.so _udivmoddi4.so unwind-dw2.so unwind-dw2-fde.so unwind-sjlj.so unwin
d-c.so | /usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/nbtsort -q`
[1] Segmentation fault (core dumped) sort +1 ${R} -o ...
/usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/sparc64--netbsd-ranlib libgcc_s_pic.a
{ /usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/sparc64--netbsd-nm -pg _muldi3.so _negdi2.so _lshrdi3.so _ashldi3.so _
ashrdi3.so _ffsdi2.so _clz.so _cmpdi2.so _ucmpdi2.so _floatdidf.so _floatdisf.so _fixunsdfsi.so _fixunssfsi.so _fixunsdf
di.so _fixdfdi.so _fixunssfdi.so _fixsfdi.so _fixxfdi.so _fixunsxfdi.so _floatdixf.so _fixunsxfsi.so _fixtfdi.so _fixuns
tfdi.so _floatditf.so _clear_cache.so _trampoline.so __main.so _exit.so _absvsi2.so _absvdi2.so _addvsi3.so _addvdi3.so
_subvsi3.so _subvdi3.so _mulvsi3.so _mulvdi3.so _negvsi2.so _negvdi2.so _ctors.so _divdi3.so _moddi3.so _udivdi3.so _umo
ddi3.so _udiv_w_sdiv.so _udivmoddi4.so unwind-dw2.so unwind-dw2-fde.so unwind-sjlj.so unwind-c.so; echo %%; cat /usr/s
rc-2.0/gnu/dist/gcc/gcc/libgcc-std.ver | sed -e "/^[ ]*#/d" -e 's/^%\(if\|else\|elif\|endif\|define\)/#\1/' | /usr/t
oolchain/tooldir.NetBSD-2.0B-sparc64/bin/sparc64--netbsd-gcc -O2 -DIN_GCC -W -Wall -Wwrite-strings -Wstrict-prototype
s -Wmissing-prototypes -isystem ./include -g -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -I. -I. -I/usr/
src-2.0/gnu/dist/gcc/gcc -I/usr/src-2.0/gnu/dist/gcc/gcc/. -I/usr/src-2.0/gnu/dist/gcc/gcc/config -I/usr/src-2.0/gnu/di
st/gcc/gcc/../include -E -xassembler-with-cpp -; } | awk -f /usr/src-2.0/gnu/dist/gcc/gcc/mkmap-symver.awk > /usr/src-2
.0/gnu/lib/libgcc3/libgcc_s/libgcc.map.tmp
mv /usr/src-2.0/gnu/lib/libgcc3/libgcc_s/libgcc.map.tmp /usr/src-2.0/gnu/lib/libgcc3/libgcc_s/libgcc.map
# build libgcc_s/libgcc_s.so.1.0
rm -f libgcc_s.so.1.0
/usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/sparc64--netbsd-gcc -Wl,-nostdlib -B/usr/objdir.sparc64/destdir.sparc64/u
sr/lib/ -B/usr/objdir.sparc64/destdir.sparc64/usr/lib/ -Wl,-rpath-link,/usr/objdir.sparc64/destdir.sparc64/lib:/usr/ob
jdir.sparc64/destdir.sparc64/usr/lib -L/usr/objdir.sparc64/destdir.sparc64/lib -Wl,-x -shared -Wl,-soname,libgcc_s.so.
1 -nodefaultlibs -Wl,--version-script=libgcc.map -o libgcc_s.so.1.0 -Wl,--whole-archive libgcc_s_pic.a -Wl,--no-whol
e-archive -L/usr/objdir.sparc64/destdir.sparc64/usr/lib
/usr/toolchain/tooldir.NetBSD-2.0B-sparc64/lib/gcc-lib/sparc64--netbsd/3.3.3/../../../../sparc64--netbsd/bin/ld: cannot
open linker script file libgcc.map: No such file or directory
collect2: ld returned 1 exit status
*** Failed target: libgcc_s.so.1.0
*** Failed command: /usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/sparc64--netbsd-gcc -Wl,-nostdlib -B/usr/objdir.sparc
64/destdir.sparc64/usr/lib/ -B/usr/objdir.sparc64/destdir.sparc64/usr/lib/ -Wl,-rpath-link,/usr/objdir.sparc64/destdir.s
parc64/lib:/usr/objdir.sparc64/destdir.sparc64/usr/lib -L/usr/objdir.sparc64/destdir.sparc64/lib -Wl,-x -shared -Wl,-son
ame,libgcc_s.so.1 -nodefaultlibs -Wl,--version-script=libgcc.map -o libgcc_s.so.1.0 -Wl,--whole-archive libgcc_s_pic.a -
Wl,--no-whole-archive -L/usr/objdir.sparc64/destdir.sparc64/usr/lib
*** Error code 1
Stop.
nbmake: stopped in /usr/src-2.0/gnu/lib/libgcc3/libgcc_s
*** Failed target: dependall
*** Failed command: cd /usr/src-2.0/gnu/lib/libgcc3/libgcc_s; /usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/nbmake real
all
*** Error code 1
Stop.
nbmake: stopped in /usr/src-2.0/gnu/lib/libgcc3/libgcc_s
*** Failed target: dependall-libgcc_s
*** Failed command: targ=dependall;dir=libgcc_s; case "$dir" in /*) echo "$targ ===> $dir"; cd "$dir"; /usr/toolchain/to
oldir.NetBSD-2.0B-sparc64/bin/nbmake "_THISDIR_=$dir/" $targ; ;; *) echo "$targ ===> $dir"; cd "/usr/src-2.0/gnu/lib/lib
gcc3/$dir"; /usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/nbmake "_THISDIR_=$dir/" $targ; ;; esac
*** Error code 1
Stop.
nbmake: stopped in /usr/src-2.0/gnu/lib/libgcc3
*** Failed target: do-gnu-lib-libgcc3
*** Failed command: (cd /usr/src-2.0/gnu/lib/libgcc3 && /usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/nbmake dependall)
*** Error code 1
Stop.
nbmake: stopped in /usr/src-2.0
*** Failed target: build
*** Failed command: (cd /usr/src-2.0 && /usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/nbmake do-gnu-lib-libgcc3)
*** Error code 1
Stop.
nbmake: stopped in /usr/src-2.0
*** Failed target: distribution
*** Failed command: (cd /usr/src-2.0 && /usr/toolchain/tooldir.NetBSD-2.0B-sparc64/bin/nbmake NOPOSTINSTALL=1 build)
*** Error code 1
Stop.
nbmake: stopped in /usr/src-2.0
ERROR: Failed to make distribution
*** BUILD ABORTED ***
>How-To-Repeat:
Build a native distribution on a Sun Ultra1:
mkdir /usr/objdir.sparc64
mkdir /usr/toolchain
cd /usr/src-2.0 (or whatever your directory with the netbsd-2-0 tree is)
./build.sh -O /usr/objdir.sparc64 tools
mv /usr/objdir.sparc64/tooldir.NetBSD-2.0B-sparc64 /usr/toolchain
./build.sh -O /usr/objdir.sparc64 -T /usr/toolchain/tooldir.NetBSD-2.0B-sparc64 -U distribution
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted: