From 223f413e31d3112f7c6909bed75d82f7a1a9b8e4 Mon Sep 17 00:00:00 2001 From: Ivan Mahonin Date: Sep 29 2016 15:29:48 +0000 Subject: fix bugs --- diff --git a/docker-builder-data/build/script/common/manager.sh b/docker-builder-data/build/script/common/manager.sh index 8ca4fe3..bb57a10 100755 --- a/docker-builder-data/build/script/common/manager.sh +++ b/docker-builder-data/build/script/common/manager.sh @@ -85,7 +85,7 @@ copy() { return 1 fi if [ "$(ls -A $1)" ]; then - if ! cp -rlf $1/* "$2/"; then + if ! cp -rlfP $1/* "$2/"; then return 1 fi fi @@ -435,8 +435,11 @@ clean_all_unpack() { } clean() { - clean_all_unpack $1 - clean_all_install $1 + message "$1 clean all" + if [ ! -z "$DRY_RUN" ]; then + return 0 + fi + rm -rf "$PACKET_DIR/$1" } ############# @@ -515,7 +518,12 @@ with_deps() { shell() { set_environment_vars $1 cd $PACKET_DIR/$1 - /bin/bash -i + set -- "${@:2}" + if [ -z "$@" ]; then + /bin/bash -i + else + "$@" + fi } dry_run() { diff --git a/docker-builder-i386/run.sh b/docker-builder-i386/run.sh index 0e2e135..38a4f90 100755 --- a/docker-builder-i386/run.sh +++ b/docker-builder-i386/run.sh @@ -26,5 +26,5 @@ docker run -it \ -v "$SCRIPT_BUILD_DIR:/build/script" \ -e PLATFORM=linux-i386 \ my/builder-i386 \ - /build/script/common/manager.sh "$@" + setarch i686 /build/script/common/manager.sh "$@"