NetBSD Problem Report #56394
From root@starwolf.com Fri Sep 10 00:44:37 2021
Return-Path: <root@starwolf.com>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
by mollari.NetBSD.org (Postfix) with ESMTPS id ADD4F1A9239
for <gnats-bugs@gnats.NetBSD.org>; Fri, 10 Sep 2021 00:44:37 +0000 (UTC)
Message-Id: <20210909232642.B04C5CB@eddie.starwolf.com>
Date: Thu, 9 Sep 2021 16:26:42 -0700 (PDT)
From: greywolf@starwolf.com
Reply-To: greywolf@starwolf.com
To: gnats-bugs@NetBSD.org
Subject: 'build release' misses ld.elf_so but includes ld.elf_so-i386
X-Send-Pr-Version: 3.95
>Number: 56394
>Category: install
>Synopsis: 'build release' fails to include ld.elf_so in base.tar.xz
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: install-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Fri Sep 10 00:45:00 +0000 2021
>Last-Modified: Fri Sep 10 16:35:01 +0000 2021
>Originator: The Grey Wolf
>Release: NetBSD 9.99.88
>Organization:
zero.
>Environment:
System: NetBSD eddie.starwolf.com 9.99.88 NetBSD 9.99.88 (EDDIE) #16: Tue Aug 31 19:14:47 PDT 2021 greywolf@eddie.starwolf.com:/sys/arch/amd64/compile/EDDIE amd64
Architecture: x86_64
Machine: amd64
Envariables-used-at-build:
MACHINE=amd64
MACHINE_ARCH=x86_64
MAKEOBJDIR=/build/amd64/obj
DESTDIR=/build/amd64/build
RELEASEDIR=/build/amd64/release
PATH=/build/amd64/tools/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/X11/bin:/usr/X11/sbin:/usr/src/tools/bin:/root/bin:/holt/greywolf/+sbin:/root/bashmodules
MANPATH=/build/amd64/tools/man:/usr/X11/man:/usr/local/man:/usr/share/man
BSDSRCDIR=/usr/src
BSDOBJDIR=/build/amd64/obj
BUILDROOT=/build
TOOLDIR=/build/amd64/tools
BUILD_MACHINE=amd64
BUILD_ARCH=x86_64
>Description:
When I go to build release using the above variables, everything
builds, but the base.tar.xz set does not include usr/libexec/ld.elf_so.
This causes numerous "not found" errors when I go to run the
dynamically linked binaries in /usr/{,s}bin.
>How-To-Repeat:
set env as above (or comparable) and run:
cd /usr/src;
./build.sh [ -j12 (optional and dependent on # of CPUs) ] \
-a ${MACHINE_ARCH} -m ${MACHINE} \
-D ${DESTDIR} \
-O ${BSDOBJDIR} \
-R ${RELEASEDIR} \
-T ${TOOLDIR} \
release
>Fix:
>Audit-Trail:
From: Paul Goyette <paul@whooppee.com>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: install/56394: 'build release' misses ld.elf_so but includes
ld.elf_so-i386
Date: Thu, 9 Sep 2021 18:55:00 -0700 (PDT)
I did a ``cvs update'' to get most recent sources, and then an update
build, and it seems to have worked just fine and includes both i386
and amd64 versions of ld.elf_so
# tar tzvf base.tar.xz | grep ld.elf_so
-r-xr-xr-x 0 root wheel 140448 Sep 8 14:29 ./libexec/ld.elf_so
-r-xr-xr-x 0 root wheel 135888 Sep 9 18:39 ./libexec/ld.elf_so-i386
lrwxr-xr-x 0 root wheel 0 Sep 8 14:29 ./usr/libexec/ld.elf_so -> /libexec/ld.elf_so
lrwxr-xr-x 0 root wheel 0 Sep 8 14:31 ./usr/libexec/ld.elf_so-i386 -> /libexec/ld.elf_so-i386
I would look for something unusual in the build environment. (I did
look at your ENV setting but did not notice anything odd.)
From: Paul Goyette <paul@whooppee.com>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: install/56394: 'build release' misses ld.elf_so but includes
ld.elf_so-i386
Date: Thu, 9 Sep 2021 20:58:16 -0700 (PDT)
Just to eliminate the ''update build'' aspect, I completely wiped all
of my $DESTDIR $OBJDIR $TOOLDIR $RELEASE directories and ran build.sh
"from scratch".
===> build.sh command: ./build.sh -T /build/netbsd-current/tools/x86_64/amd64 -D /build/netbsd-current/dest/amd64 -O /build/netbsd-current/obj/amd64 -R /build/netbsd-current/release -V RELEASEMACHINEDIR=amd64 -V MKDEBUG=yes -V MKKDEBUG=yes -V MKDEBUGLIB=yes -V KERNEL_DIR=no -U -N0 -m amd64 -j12 release
===> build.sh started: Fri Sep 10 02:36:40 UTC 2021
===> NetBSD version: 9.99.88
===> MACHINE: amd64
===> MACHINE_ARCH: x86_64
===> Build platform: NetBSD 9.99.87 amd64
===> HOST_SH: /bin/sh
===> MAKECONF file: /etc/mk.conf
===> TOOLDIR path: /build/netbsd-current/tools/x86_64/amd64
===> DESTDIR path: /build/netbsd-current/dest/amd64
===> RELEASEDIR path: /build/netbsd-current/release
===> Updated makewrapper: /build/netbsd-current/tools/x86_64/amd64/bin/nbmake-amd64
distribution ===> .
build ===> . (with: NOPOSTINSTALL=1)
Build started at: Fri Sep 10 02:36:41 UTC 2021
...
Successful make release
build.sh ended: Fri Sep 10 03:51:49 UTC 2021
===> .
It successfully built and included in base.tar.xz both the amd64 and
i386 versions of ld.elf.so
# tar tzvf base.tar.xz | grep ld.elf
-r-xr-xr-x 0 root wheel 140448 Sep 9 20:16 ./libexec/ld.elf_so
-r-xr-xr-x 0 root wheel 135888 Sep 9 20:17 ./libexec/ld.elf_so-i386
lrwxr-xr-x 0 root wheel 0 Sep 9 20:16 ./usr/libexec/ld.elf_so -> /libexec/ld.elf_so
lrwxr-xr-x 0 root wheel 0 Sep 9 20:17 ./usr/libexec/ld.elf_so-i386 -> /libexec/ld.elf_so-i386
I would definitely investigate further to see what might be happening
in your local set-up.
FWIW, several other developers have also reported (via IRC) that their
builds have also included all appropriate files.
From: Bch <beceeh@shaw.ca>
To: gnats-bugs@netbsd.org
Cc: brad.harder@gmail.com
Subject: Re: install/56394: 'build release' misses ld.elf_so but includes ld.elf_so-386
Date: Fri, 10 Sep 2021 09:30:55 -0700 (PDT)
I've worked this problem on amd64 and aarch64/evbarm and I believe
its related to MKDYNAMICROOT=no. I talked to greywolf on IRC and
confirmed they have same MKDYNAMICROOT=no build flag. I expected
to be able to fix w/ something like (I know patch below is
arch-specific...)
katy$ cvs diff -u /usr/src/distrib/sets/lists/base/md.amd64
Index: /usr/src/distrib/sets/lists/base/md.amd64
===================================================================
RCS file: /usr/cvsrepo/src/distrib/sets/lists/base/md.amd64,v
retrieving revision 1.285
diff -u -r1.285 md.amd64
--- /usr/src/distrib/sets/lists/base/md.amd64 23 Jun 2021 18:30:32 -0000 1.285
+++ /usr/src/distrib/sets/lists/base/md.amd64 15 Aug 2021 22:03:03 -0000
@@ -15,6 +15,7 @@
./usr/lib/libx86_64.so.0 base-sys-shlib pic
./usr/lib/libx86_64.so.0.0 base-sys-shlib pic
./usr/libexec/ld.elf_so-i386 base-sys-shlib compat,pic
+./usr/libexec/ld.elf_so base-sys-shlib pic,dynamicroot
./usr/lkm/aps.o base-obsolete obsolete
./usr/lkm/compat_linux.o base-obsolete obsolete
./usr/lkm/exec_linux_elf.o base-obsolete obsolete
...but the "dynamicroot" portion of that new entry did not actually
seem to work. I've removed the "dynamicroot" attribute on my local
amd64 installation for now to brute force the flist update, and
builds pass. TBD by expert what is out of alignment -- build
artifacts or flist, how to update flist.
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.46 2020/01/03 16:35:01 leot Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2020
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.