Closed tsutsui closed 2 years ago
gcc issule is handled in #10.
mtree failure is also reproducible:
optiplex-% /home/tsutsui/netbsd-src/obj.luna88k/tooldir.NetBSD-9.2-x86_64/bin/nbmake-luna88k makesetfiles
# create set lists
cd /home/tsutsui/netbsd-src/distrib/sets && DESTDIR=/home/tsutsui/netbsd-src/obj.luna88k/destdir.luna88k MACHINE=luna88k MACHINE_ARCH=m88k CKSUM=/home/tsutsui/netbsd-src/obj.luna88k/tooldir.NetBSD-9.2-x86_64/bin/nbcksum MAKE=/home/tsutsui/netbsd-src/obj.luna88k/tooldir.NetBSD-9.2-x86_64/bin/nbmake MTREE=/home/tsutsui/netbsd-src/obj.luna88k/tooldir.NetBSD-9.2-x86_64/bin/nbmtree MKTEMP=/home/tsutsui/netbsd-src/obj.luna88k/tooldir.NetBSD-9.2-x86_64/bin/nbmktemp PAX=/home/tsutsui/netbsd-src/obj.luna88k/tooldir.NetBSD-9.2-x86_64/bin/nbpax HOST_SH=sh sh ./maketars -S -d /home/tsutsui/netbsd-src/obj.luna88k/destdir.luna88k -M /home/tsutsui/netbsd-src/obj.luna88k/destdir.luna88k/METALOG -N /home/tsutsui/netbsd-src/etc -t /home/tsutsui/netbsd-src/obj.luna88k/releasedir/luna88k/binary/sets
[1] Done (cat ${etcdir}/mtree/NetBSD.dist; echo "/unset... |
Segmentation fault (core dumped) ${MTREE} -C -k all -N ${etcdir} >${SDIR}/metalog
maketars: mtree parse of /home/tsutsui/netbsd-src/obj.luna88k/destdir.luna88k/METALOG failed
gdb shows:
Reading symbols from ../../tools/mtree/obj.luna88k.NetBSD-9.2-x86_64/mtree...
(No debugging symbols found in ../../tools/mtree/obj.luna88k.NetBSD-9.2-x86_64/mtree)
[New process 1]
Core was generated by `nbmtree'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 0x00007b5673367101 in strlen () from /usr/lib/libc.so.12
(gdb) bt
#0 0x00007b5673367101 in strlen () from /usr/lib/libc.so.12
#1 0x00007b56733484dc in __vfprintf_unlocked_l (
fp=fp@entry=0x610978 <__sF+152>, loc=0x7b56735bf380 <_lc_global_locale>,
fmt0=fmt0@entry=0x40d38a "uname=%s ", ap=ap@entry=0x7f7fff5fc4c8)
at /usr/src/lib/libc/stdio/vfwprintf.c:1373
#2 0x00007b5673349dbe in vfprintf (fp=0x610978 <__sF+152>,
fmt0=0x40d38a "uname=%s ", ap=ap@entry=0x7f7fff5fc4c8)
at /usr/src/lib/libc/stdio/vfwprintf.c:555
#3 0x00007b5673343f7f in printf (fmt=<optimized out>)
at /usr/src/lib/libc/stdio/printf.c:59
#4 0x000000000040665c in dump_nodes ()
#5 0x00000000004053e9 in main ()
(gdb)
mtree with -g shows:
(gdb) bt
#0 0x0000759c25f67101 in strlen () from /usr/lib/libc.so.12
#1 0x0000759c25f484dc in __vfprintf_unlocked_l (
fp=fp@entry=0x610978 <__sF+152>, loc=0x759c261bf380 <_lc_global_locale>,
fmt0=fmt0@entry=0x40d38a "uname=%s ", ap=ap@entry=0x7f7fff406a68)
at /usr/src/lib/libc/stdio/vfwprintf.c:1373
#2 0x0000759c25f49dbe in vfprintf (fp=0x610978 <__sF+152>,
fmt0=fmt0@entry=0x40d38a "uname=%s ", ap=ap@entry=0x7f7fff406a68)
at /usr/src/lib/libc/stdio/vfwprintf.c:555
#3 0x0000759c25f43f7f in printf (fmt=fmt@entry=0x40d38a "uname=%s ")
at /usr/src/lib/libc/stdio/printf.c:59
#4 0x0000000000406650 in dump_nodes (dir=dir@entry=0x40d2fc "",
root=<optimized out>, pathlast=pathlast@entry=0)
at /home/tsutsui/netbsd-src/tools/mtree/../../usr.sbin/mtree/spec.c:335
#5 0x00000000004053e9 in main (argc=<optimized out>, argv=<optimized out>)
at /home/tsutsui/netbsd-src/tools/mtree/../../usr.sbin/mtree/mtree.c:211
(gdb)
Umm. name
is corruptted?
mtree SEGV has been fixed by pulling src/tools/compat fixes: https://github.com/tsutsui/netbsd-src/commit/c7584f01a4c190c9032497a173e183bca6335f63
https://twitter.com/isaki68k/status/1554098908288192515 https://twitter.com/isaki68k/status/1554099334492196864
Currently tested only on NetBSD/i386 9.2 host.