2864cd1a359a28d12a067e1f9c64f0520c1795f1
3 SCRIPTDIR
="$(dirname "$0")"
4 [ "${SCRIPTDIR:0:1}" = "/" ] || SCRIPTDIR
="$PWD/$SCRIPTDIR"
5 BASEDIR
="$SCRIPTDIR/.."
7 DIR
="$BASEDIR/tmp/deptest"
8 STAMP_DIR_SUCCESS
="$DIR/stamp-success"
9 STAMP_DIR_FAILED
="$DIR/stamp-failed"
10 BUILD_DIR
="$DIR/build_dir/target"
11 BUILD_DIR_HOST
="$DIR/build_dir/host"
12 STAGING_DIR
="$DIR/staging_dir"
13 STAGING_DIR_HOST
="$DIR/staging_dir_host"
14 STAGING_DIR_HOST_TMPL
="$DIR/staging_dir_host_tmpl"
23 [ -f "$BASEDIR/include/toplevel.mk" ] || \
24 die
"Error: Could not find buildsystem base directory"
25 cd "$BASEDIR" || die
"Failed to enter base directory"
27 mkdir
-p "$STAMP_DIR_SUCCESS" "$STAMP_DIR_FAILED" "$BUILD_DIR" "$BUILD_DIR_HOST" "$LOG_DIR"
29 [ -d "$STAGING_DIR_HOST_TMPL" ] ||
{
30 rm -rf staging_dir
/host
31 make tools
/install V
=99 || die
"make tools/install failed, please check"
32 cp -al staging_dir
/host "$STAGING_DIR_HOST_TMPL"
33 make toolchain
/install V
=99 || die
"make toolchain/install failed, please check"
36 for pkg
in `cat tmp/.packagedeps | grep CONFIG_PACKAGE | grep -v curdir | sed -e 's,.*[/=]\s*,,' | sort -u`; do
38 for conf
in `grep CONFIG_PACKAGE tmp/.packagedeps | grep -E "[ /]$pkg\$" | sed -e 's,package-$(\(CONFIG_PACKAGE_.*\)).*,\1,'`; do
39 grep "$conf=" .config
> /dev
/null
&& SELECTED
=1
41 STAMP_SUCCESS
="$STAMP_DIR_SUCCESS/$pkg"
42 STAMP_FAILED
="$STAMP_DIR_FAILED/$pkg"
44 [ -f "$STAMP_SUCCESS" ] && continue
45 [ -n "$SELECTED" ] ||
{
46 echo "Package $pkg is not selected"
49 echo "Testing package $pkg..."
51 mkdir
-p "$STAGING_DIR"
52 rm -rf "$STAGING_DIR_HOST"
53 cp -al "$STAGING_DIR_HOST_TMPL" "$STAGING_DIR_HOST"
54 make package
/$pkg/compile \
55 BUILD_DIR
="$BUILD_DIR" \
56 BUILD_DIR_HOST
="$BUILD_DIR_HOST" \
57 STAGING_DIR
="$STAGING_DIR" \
58 STAGING_DIR_HOST
="$STAGING_DIR_HOST" \
59 V
=99 >"$LOG_DIR/$(basename $pkg).log" 2>&1
61 touch "$STAMP_SUCCESS"
64 echo "Building package $pkg failed!"
This page took 0.041663 seconds and 3 git commands to generate.