source: MondoRescue/branches/3.3/mindi-busybox/qemu_multiarch_testing/hdc.dir/build

Last change on this file was 3621, checked in by Bruno Cornec, 10 years ago

New 3?3 banch for incorporation of latest busybox 1.25. Changing minor version to handle potential incompatibilities.

  • Property svn:executable set to *
File size: 1.6 KB
Line 
1#!/bin/sh
2
3umount /mnt # optional
4
5test -x "bin/busybox-$HOST" && {
6 echo "Found bin/busybox-$HOST, using it"
7 cp -a "bin/busybox-$HOST" bin/busybox
8 bin/busybox --install -s bin/
9 # Supply missing stuff (e.g. bzip2):
10 PATH="$PATH:$PWD/bin"
11 # Override known-buggy host binaries:
12 cp -af bin/od `which od`
13}
14
15(
16 #set -e -x
17 cd busybox
18
19 make defconfig
20 # Want static build
21 sed 's/^.*CONFIG_STATIC.*$/CONFIG_STATIC=y/' -i .config
22 bzip2 </dev/null >/dev/null || {
23 # Drats, newer Aboriginal Linux has no bzip2
24 sed 's/^.*CONFIG_FEATURE_COMPRESS_USAGE.*$/# CONFIG_FEATURE_COMPRESS_USAGE is not set/' -i .config
25 }
26 test x"`uname -m`" = x"mips" && {
27 # Without this, I get MIPS-I binary instead of MIPS32.
28 # No idea what's the difference, but my router wants MIPS32.
29 sed 's/^.*CONFIG_EXTRA_CFLAGS.*$/CONFIG_EXTRA_CFLAGS="-mips32"/' -i .config
30 }
31 # These won't build because of toolchain/libc breakage:
32 sed 's/^.*CONFIG_FEATURE_SYNC_FANCY.*$/# CONFIG_FEATURE_SYNC_FANCY is not set/' -i .config # no syncfs()
33 sed 's/^.*CONFIG_FEATURE_WTMP.*$/# CONFIG_FEATURE_WTMP is not set/' -i .config
34 sed 's/^.*CONFIG_FEATURE_UTMP.*$/# CONFIG_FEATURE_UTMP is not set/' -i .config
35 sed 's/^.*CONFIG_FEATURE_INETD_RPC.*$/# CONFIG_FEATURE_INETD_RPC is not set/' -i .config
36
37 make #V=1 || sh
38 size busybox
39 ./busybox || echo "Exit code: $?"
40 if uuencode TEST </dev/null >/dev/null && bzip2 </dev/null >/dev/null; then
41 bzip2 <busybox | uuencode busybox.bz2
42 else
43 od -v -tx1 <busybox
44 fi
45 #test "x$FTP_PORT" = x ||
46 # ftpput -P "$FTP_PORT" "$FTP_SERVER" strace
47) 2>&1 | tee build.log
48mount -o remount,ro /home
49sync
50sleep 1
Note: See TracBrowser for help on using the repository browser.