Subject: Building tools with build.sh
To: None <tech-toolchain@netbsd.org>
From: =?ISO-8859-1?Q?St=E9phane?= Witzmann <stephane.witzmann@gmail.com>
List: tech-toolchain
Date: 08/15/2006 21:44:15
(NOTE: I already posted something like this on netbsd-help)

Hello

I have been unable to build the tools with build.sh for a while. It fails as
shown below. I am using a 3.0 userland with an almost-current kernel.
I also tried building the tools for 4_BETA using a 4_BETA sandbox (last
binary snapshot), same error.

Please help/fix !

Stéphane



---------------------

#!/bin/sh
export DESTARCH=i386
export DESTDIR=/home/durandil/NetBSD/head/cross/
./build.sh -u -m $DESTARCH -D $DESTDIR/dest/ -O $DESTDIR/obj/ -T
$DESTDIR/tools/ tools

(...)

/bin/sh /home/durandil/NetBSD/head/src/tools/binutils/../../gnu/dist/binutils/ld/../mkinstalldirs /home/durandil/NetBSD/head/cross//tools/i386--netbsdelf/lib/ldscripts
for f in ldscripts/*;
do  /home/durandil/NetBSD/head/cross//tools/bin/nbinstall -c -p -r -m 644
$f /home/durandil/NetBSD/head/cross//tools/i386--netbsdelf/lib/$f ;  done
Making install-info in po
NOT
REBUILDING /home/durandil/NetBSD/head/src/tools/binutils/../../gnu/dist/binutils/ld/ldver.texi
NOT REBUILDING ld.info
/bin/sh /home/durandil/NetBSD/head/src/tools/binutils/../../gnu/dist/binutils/ld/../mkinstalldirs /home/durandil/NetBSD/head/cross//tools/info
 install-info
--info-dir=/home/durandil/NetBSD/head/cross//tools/info /home/durandil/NetBSD/head/cross//tools/info/ld.info
install-info: No such file or directory
for /home/durandil/NetBSD/head/cross//tools/info/ld.info
dependall ===> gcc
nbgmake[1]: Entering directory
`/home/durandil/NetBSD/head/cross/obj/tools/gcc/build/libiberty'
nbgmake[2]: Entering directory
`/home/durandil/NetBSD/head/cross/obj/tools/gcc/build/libiberty/testsuite'
nbgmake[2]: Nothing to be done for `all'.
nbgmake[2]: Leaving directory
`/home/durandil/NetBSD/head/cross/obj/tools/gcc/build/libiberty/testsuite'
nbgmake[1]: Leaving directory
`/home/durandil/NetBSD/head/cross/obj/tools/gcc/build/libiberty'
nbgmake[1]: Entering directory
`/home/durandil/NetBSD/head/cross/obj/tools/gcc/build/build-i386-unknown-netbsdelf3.99.20/libiberty'
nbgmake[2]: Entering directory
`/home/durandil/NetBSD/head/cross/obj/tools/gcc/build/build-i386-unknown-netbsdelf3.99.20/libiberty/testsuite'
nbgmake[2]: Nothing to be done for `all'.
nbgmake[2]: Leaving directory
`/home/durandil/NetBSD/head/cross/obj/tools/gcc/build/build-i386-unknown-netbsdelf3.99.20/libiberty/testsuite'
nbgmake[1]: Leaving directory
`/home/durandil/NetBSD/head/cross/obj/tools/gcc/build/build-i386-unknown-netbsdelf3.99.20/libiberty'
nbgmake[1]: Entering directory
`/home/durandil/NetBSD/head/cross/obj/tools/gcc/build/build-i386-unknown-netbsdelf3.99.20/fixincludes'
nbgmake[1]: Nothing to be done for `all'.
nbgmake[1]: Leaving directory
`/home/durandil/NetBSD/head/cross/obj/tools/gcc/build/build-i386-unknown-netbsdelf3.99.20/fixincludes'
nbgmake[1]: Entering directory
`/home/durandil/NetBSD/head/cross/obj/tools/gcc/build/libcpp'
echo "#define LOCALEDIR
\"/home/durandil/NetBSD/head/cross//tools/share/locale\"" > localedir.new
/home/durandil/NetBSD/head/src/tools/gcc/../../gnu/dist/gcc4/libcpp/../move-if-change
localedir.new localedir.h
nbgmake[1]:
execvp: /home/durandil/NetBSD/head/src/tools/gcc/../../gnu/dist/gcc4/libcpp/../move-if-change:
Permission denied
nbgmake[1]: *** [localedir.hs] Error 127
nbgmake[1]: Leaving directory
`/home/durandil/NetBSD/head/cross/obj/tools/gcc/build/libcpp'
nbgmake: *** [all-libcpp] Error 2

*** Failed target:  .build_done
*** Failed command: (cd build && /usr/bin/env -i CC=cc CFLAGS=-O CPPFLAGS=
CXX=c++ CXXFLAGS=-O
INSTALL=/home/durandil/NetBSD/head/cross//tools/bin/nbinstall\ -c\ -p\ -r
LDFLAGS= AR=ar RANLIB=ranlib
LEX=/home/durandil/NetBSD/head/cross//tools/bin/nblex
MAKE=/home/durandil/NetBSD/head/cross//tools/bin/nbgmake
PATH="/home/durandil/NetBSD/head/cross//tools/bin:$PATH"
YACC=/home/durandil/NetBSD/head/cross//tools/bin/nbyacc MACHINE=
MAKEINFO=/home/durandil/NetBSD/head/cross//tools/bin/nbmakeinfo LIBGCC=
LIBGCC1= LIBGCC1_TEST= LIBGCC2= INSTALL_LIBGCC= EXTRA_PARTS=
CPPFLAGS=-DNETBSD_TOOLS AR=ar RANLIB=ranlib BISON=true DESTDIR=
INSTALL=/home/durandil/NetBSD/head/cross//tools/bin/nbinstall\ -c\ -p\
-r /home/durandil/NetBSD/head/cross//tools/bin/nbgmake -e MACHINE=
MAKEINFO=/home/durandil/NetBSD/head/cross//tools/bin/nbmakeinfo LIBGCC=
LIBGCC1= LIBGCC1_TEST= LIBGCC2= INSTALL_LIBGCC= EXTRA_PARTS=
CPPFLAGS=-DNETBSD_TOOLS AR=ar RANLIB=ranlib BISON=true DESTDIR=
INSTALL=/home/durandil/NetBSD/head/cross//tools/bin/nbinstall\ -c\ -p\ -r
all-gcc)
*** Error code 2

Stop.
nbmake: stopped in /home/durandil/NetBSD/head/src/tools/gcc

*** Failed target:  dependall
*** Failed command:
cd /home/durandil/NetBSD/head/src/tools/gcc; /home/durandil/NetBSD/head/cross//tools/bin/nbmake
realall
*** Error code 1

Stop.
nbmake: stopped in /home/durandil/NetBSD/head/src/tools/gcc

*** Failed target:  dependall-gcc
*** Failed command: _makedirtarget() { dir="$1"; shift; target="$1"; shift;
case "${dir}" in /*) this="${dir}/"; real="${dir}" ;; .) this="";
real="/home/durandil/NetBSD/head/src/tools" ;; *) this="${dir}/";
real="/home/durandil/NetBSD/head/src/tools/${dir}" ;; esac;
show=${this:-.}; echo "${target} ===> ${show%/}${1:+ (with: $@)}"; cd
"${real}" && /home/durandil/NetBSD/head/cross//tools/bin/nbmake
_THISDIR_="${this}" "$@" ${target}; }; _makedirtarget gcc dependall
*** Error code 1

Stop.
nbmake: stopped in /home/durandil/NetBSD/head/src/tools

ERROR: Failed to make dependall tools
*** BUILD ABORTED ***