From 624b5cc6c6995bc168237f32dbd614811973d028 Mon Sep 17 00:00:00 2001 From: Stephan Raue Date: Sat, 17 Jul 2010 05:03:24 +0200 Subject: [PATCH] config/path: set variable for target binarys dir Signed-off-by: Stephan Raue --- config/path | 2 ++ packages/image/install | 42 +++++++++++++++++++++--------------------- 2 files changed, 23 insertions(+), 21 deletions(-) diff --git a/config/path b/config/path index 793636b19c..2def1e25af 100644 --- a/config/path +++ b/config/path @@ -34,9 +34,11 @@ SCRIPTS=scripts PACKAGES=packages SOURCES=sources BUILD_BASE=build +TARGET=target BUILD=$BUILD_BASE.OpenELEC-$PROJECT.$TARGET_ARCH.$OPENELEC_VERSION [ -n "$TARGET_PLATFORM" ] && BUILD=$BUILD.$TARGET_PLATFORM PKG_BUILD=$BUILD/$1\[-_][0-9]* +TARGET_IMG=$ROOT/$TARGET STAMPS_NOARCH=.stamps STAMPS=$BUILD/.stamps DOCS=DOCS diff --git a/packages/image/install b/packages/image/install index 4f477c8bab..7c80ec3133 100755 --- a/packages/image/install +++ b/packages/image/install @@ -116,15 +116,15 @@ case "$2" in $STRIP --strip-debug $MOD done - mkdir -p $ROOT/target - rm -rf $ROOT/target/OpenELEC-$TARGET_VERSION.kernel - cp -PR $BUILD/linux-*/arch/x86/boot/bzImage $ROOT/target/OpenELEC-$TARGET_VERSION.kernel + mkdir -p $TARGET_IMG + rm -rf $TARGET_IMG/OpenELEC-$TARGET_VERSION.kernel + cp -PR $BUILD/linux-*/arch/x86/boot/bzImage $TARGET_IMG/OpenELEC-$TARGET_VERSION.kernel - echo "rm -rf $ROOT/target/OpenELEC-$TARGET_VERSION.system" >> $FAKEROOT_SCRIPT - echo "$ROOT/$TOOLCHAIN/bin/mksquashfs $INSTALL $ROOT/target/OpenELEC-$TARGET_VERSION.system -noappend -comp lzma" >> $FAKEROOT_SCRIPT -# echo "$ROOT/$TOOLCHAIN/bin/mksquashfs $INSTALL $ROOT/target/OpenELEC-$TARGET_VERSION.system -noappend" >> $FAKEROOT_SCRIPT + echo "rm -rf $TARGET_IMG/OpenELEC-$TARGET_VERSION.system" >> $FAKEROOT_SCRIPT + echo "$ROOT/$TOOLCHAIN/bin/mksquashfs $INSTALL $TARGET_IMG/OpenELEC-$TARGET_VERSION.system -noappend -comp lzma" >> $FAKEROOT_SCRIPT +# echo "$ROOT/$TOOLCHAIN/bin/mksquashfs $INSTALL $TARGET_IMG/OpenELEC-$TARGET_VERSION.system -noappend" >> $FAKEROOT_SCRIPT $ROOT/$TOOLCHAIN/bin/fakeroot -- $FAKEROOT_SCRIPT - chmod 0644 $ROOT/target/OpenELEC-$TARGET_VERSION.system + chmod 0644 $TARGET_IMG/OpenELEC-$TARGET_VERSION.system rm -rf $FAKEROOT_SCRIPT ;; @@ -144,34 +144,34 @@ case "$2" in cp $ROOT/licenses/* $BUILD/$2/OpenELEC-$TARGET_VERSION/licenses mkdir -p $BUILD/$2/OpenELEC-$TARGET_VERSION/target - cp $ROOT/target/OpenELEC-$TARGET_VERSION.system $BUILD/$2/OpenELEC-$TARGET_VERSION/target/SYSTEM - cp $ROOT/target/OpenELEC-$TARGET_VERSION.kernel $BUILD/$2/OpenELEC-$TARGET_VERSION/target/KERNEL + cp $TARGET_IMG/OpenELEC-$TARGET_VERSION.system $BUILD/$2/OpenELEC-$TARGET_VERSION/target/SYSTEM + cp $TARGET_IMG/OpenELEC-$TARGET_VERSION.kernel $BUILD/$2/OpenELEC-$TARGET_VERSION/target/KERNEL # create release directory - mkdir -p $ROOT/target + mkdir -p $TARGET_IMG # remove an previous created release tarball - rm -rf $ROOT/target/OpenELEC-$TARGET_VERSION.tar.bz2 - tar cjf $ROOT/target/OpenELEC-$TARGET_VERSION.tar.bz2 -C $BUILD/$2 OpenELEC-$TARGET_VERSION + rm -rf $TARGET_IMG/OpenELEC-$TARGET_VERSION.tar.bz2 + tar cjf $TARGET_IMG/OpenELEC-$TARGET_VERSION.tar.bz2 -C $BUILD/$2 OpenELEC-$TARGET_VERSION ;; qemu) $SCRIPTS/install image system - mkdir -p $ROOT/target - rm -rf $ROOT/target/OpenELEC-$TARGET_VERSION-qemu.flash - qemu-img create -f raw $ROOT/target/OpenELEC-$TARGET_VERSION-qemu.flash 128M - /sbin/mkfs.ext3 -L OpenELEC -F $ROOT/target/OpenELEC-$TARGET_VERSION-qemu.flash + mkdir -p $TARGET_IMG + rm -rf $TARGET_IMG/OpenELEC-$TARGET_VERSION-qemu.flash + qemu-img create -f raw $TARGET_IMG/OpenELEC-$TARGET_VERSION-qemu.flash 128M + /sbin/mkfs.ext3 -L OpenELEC -F $TARGET_IMG/OpenELEC-$TARGET_VERSION-qemu.flash mkdir -p $ROOT/.tmp - sudo mount -o loop $ROOT/target/OpenELEC-$TARGET_VERSION-qemu.flash $ROOT/.tmp - cp -R $ROOT/target/OpenELEC-$TARGET_VERSION.system $ROOT/.tmp/openelec.system + sudo mount -o loop $TARGET_IMG/OpenELEC-$TARGET_VERSION-qemu.flash $ROOT/.tmp + cp -R $TARGET_IMG/OpenELEC-$TARGET_VERSION.system $ROOT/.tmp/openelec.system sudo umount $ROOT/.tmp - rm -rf $ROOT/target/OpenELEC-$TARGET_VERSION-qemu.store - qemu-img create -f raw $ROOT/target/OpenELEC-$TARGET_VERSION-qemu.store 40M - /sbin/mkfs.ext3 -L OpenELEC -F $ROOT/target/OpenELEC-$TARGET_VERSION-qemu.store + rm -rf $TARGET_IMG/OpenELEC-$TARGET_VERSION-qemu.store + qemu-img create -f raw $TARGET_IMG/OpenELEC-$TARGET_VERSION-qemu.store 40M + /sbin/mkfs.ext3 -L OpenELEC -F $TARGET_IMG/OpenELEC-$TARGET_VERSION-qemu.store ;;