view run-from-build.sh @ 783:db06a8c1bfed

Lots of changes to move buildall.sh functionality into build.sh. Upgrade build.sh to be able to create static cross compilers and static native compilers via canadian cross. Teach build stages to use $STAGE_NAME for their output directory (and tarballs, and === notifications). Remove LFS style /tools support (since host-tools.sh performs an equivalent cleaning step and it's a pain to maintain it), add ROOT_NODIRS instead.
author Rob Landley <rob@landley.net>
date Sun, 05 Jul 2009 17:50:44 -0500
parents 6caf372a8b12
children aea72ecff868
line wrap: on
line source

#!/bin/bash

source sources/include.sh || exit 1

read_arch_dir "$1"

SYSDIR="${BUILD}/system-image-$ARCH_NAME"

if [ ! -f "$SYSDIR/run-emulator.sh" ]
then
  [ -z "$FAIL_QUIET" ] && echo "No $SYSDIR/run-emulator.sh" >&2
  exit 1
fi

cd "$SYSDIR" || exit 1

[ -z "$SKIP_HOME" ] && [ -z "$MAKE_HDB" ] && MAKE_HDB="--make-hdb 2048"

# A little paranoia.
[ -f "image-${ARCH}.ext2" ] && fsck.ext2 -y "image-${ARCH}.ext2" </dev/null

# And run it, using the distccd we built (if necessary) and the cross-compiler.

trap "killtree $$" EXIT

./run-emulator.sh $MAKE_HDB --memory 256 --with-distcc \
	"${BUILD}/cross-compiler-${ARCH}"