<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<br>
<br>
<div class="moz-cite-prefix">On 11/08/2015 09:03 PM, James McMechan
wrote:<br>
</div>
<blockquote
cite="mid:CAKyyCY7qVsFssSMsyp6VPgcUKgRTnsvWs1zu83XBLtRJjpi=BQ@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>
<div>
<div>Hi everyone,<br>
</div>
It has been a while since I last tested rebuilding in a
chroot, and my build is failing<br>
</div>
I had done what I remembered as my procedure:<br>
</div>
# more/chroot-splice.sh x86_64 /tmp<br>
<div>
<div>then copied it over to my /mnt/build directory and
mounted proc,sys,dev<br>
</div>
<div>and then unpacked aboriginal into it<br>
# tar xf ~mcmechan/Downloads/aboriginal-1.4.3.tar.gz -C
/mnt/build<br>
</div>
<div>when I start up my chroot<br>
# chroot /mnt/build /bin/bash<br>
</div>
<div># cd /aboriginal-1.4.3/<br>
</div>
<div># ./build.sh x86_64<br>
=== Download source code.<br>
wget: bad address '<a moz-do-not-send="true"
href="http://uclibc.org">uclibc.org</a>'z2<br>
wget: bad address '<a moz-do-not-send="true"
href="http://landley.net">landley.net</a>'<br>
</div>
</div>
</div>
</blockquote>
<br>
bad or missing /etc/resolv.conf in the chroot?<br>
<blockquote
cite="mid:CAKyyCY7qVsFssSMsyp6VPgcUKgRTnsvWs1zu83XBLtRJjpi=BQ@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>
<div>Connecting to 127.0.0.1 (<a moz-do-not-send="true"
href="http://127.0.0.1:80">127.0.0.1:80</a>)<br>
wget: server returned error: HTTP/1.0 404 Not Found<br>
Could not download uClibc-0.9.33.2.tar.bz2<br>
<br>
Exiting due to errors (host download )<br>
<br>
real 0m10.098s<br>
user 0m0.000s<br>
sys 0m0.000s<br>
<br>
</div>
<div>#####<br>
</div>
<div>Ok, I have now checked and downloads have not worked for
some time at least back to 1.2.9<br>
<br>
</div>
<div>but if I have copied in the package directory 1.2.9 will
build busybox & toybox<br>
</div>
<div>and 1.4.3 fails with<br>
<br>
=== busybox (host host-tools)<br>
Extracting
'busybox'...........................................................................<br>
Snapshot 'busybox'...<br>
sh: set: -e: invalid option<br>
HOSTCC scripts/basic/fixdep<br>
sh: set: -e: invalid option<br>
HOSTCC scripts/basic/split-include<br>
sh: set: -e: invalid option<br>
HOSTCC scripts/basic/docproc<br>
sh: local: not in a function<br>
sed: : No such file or directory<br>
sed: : No such file or directory<br>
<br>
</div>
<div>Ok that appears to be hush so with<br>
# ln -sf /bin/bash /bin/sh<br>
</div>
<div>I get a little further, the more/chroot-splice.sh should
likely do this and it would be nice if it did not require
the second option, I at least am just wanting a plain chroot
without a mount inside.<br>
</div>
</div>
</div>
</blockquote>
You shouldn't require bash. Maybe hush is not posixy enough? If you
want a small shell I think busybox sh and mksh are currently the
easiest options.<br>
<br>
<blockquote
cite="mid:CAKyyCY7qVsFssSMsyp6VPgcUKgRTnsvWs1zu83XBLtRJjpi=BQ@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>
<div><br>
</div>
<div>so using bash 1.4.3 dies in toybox with:<br>
<br>
Extracting 'toybox'...............<br>
Applying /aboriginal-1.4.3/sources/patches/toybox-grep.patch<br>
patching toys/posix/grep.c<br>
Snapshot 'toybox'...<br>
scripts/genconfig.sh<br>
cc -o kconfig/conf kconfig/conf.c kconfig/zconf.tab.c
-DKBUILD_NO_NLS=1 \<br>
-DPROJECT_NAME=\"ToyBox\"<br>
kconfig/conf -D /dev/null Config.in > /dev/null<br>
scripts/make.sh<br>
scripts/make.sh: line 7: set: pipefail: invalid option name<br>
Generate headers from toys/*/*.c...<br>
generated/newtoys.h Library probe.......<br>
Make generated/config.h from .config.<br>
generated/flags.h generated/globals.h generated/help.h<br>
Compile toybox.scripts/make.sh: line 1: jobs: command not
found<br>
.scripts/make.sh: line 1: jobs: command not found<br>
.scripts/make.sh: line 1: jobs: command not found<br>
<br>
</div>
<div>so should I be looking to turn on pipefail & jobs in
bash or do I need to fix up the build script. 1.2.9 did not
have jobs or pipefail.<br>
</div>
</div>
</div>
</blockquote>
Yes, or use another shell. Disabling random features might not be a
good idea ;)<br>
<br>
Have fun,<br>
<br>
Patrick<br>
</body>
</html>