index : devtools32 | |
Archlinux32 fork of devtools | gitolite user |
summaryrefslogtreecommitdiff |
author | Jan Alexander Steffens (heftig) <jan.steffens@gmail.com> | 2011-09-17 15:05:35 +0200 |
---|---|---|
committer | Lukas Fleischer <archlinux@cryptocrack.de> | 2011-10-07 21:53:03 +0200 |
commit | 1df679974786fe4282fd675574d92a464c28f7cb (patch) | |
tree | 8203aba86f5a5c3b068702bce6ee60a4a10673cd /makechrootpkg.in | |
parent | e41deee5e5d471e90b951b1f68db5dc50c343b0c (diff) |
-rw-r--r-- | makechrootpkg.in | 16 |
diff --git a/makechrootpkg.in b/makechrootpkg.in index eb23c61..1bed6b8 100644 --- a/makechrootpkg.in +++ b/makechrootpkg.in @@ -188,6 +188,10 @@ fi [[ -z $MAKEFLAGS ]] && eval $(grep '^MAKEFLAGS=' /etc/makepkg.conf) [[ -z $PACKAGER ]] && eval $(grep '^PACKAGER=' /etc/makepkg.conf) +# Use PKGBUILD directory if PKGDEST or SRCDEST don't exist +[[ -d $PKGDEST ]] || PKGDEST=. +[[ -d $SRCDEST ]] || SRCDEST=. + mkdir -p "$copydir/pkgdest" if ! grep -q 'PKGDEST="/pkgdest"' "$copydir/etc/makepkg.conf"; then echo 'PKGDEST="/pkgdest"' >> "$copydir/etc/makepkg.conf" @@ -270,11 +274,7 @@ if mkarchroot -r "/chrootbuild" "$copydir"; then popd >/dev/null fi - if [[ -d $PKGDEST ]]; then - mv "$pkgfile" "$PKGDEST" - else - mv "$pkgfile" . - fi + mv "$pkgfile" "$PKGDEST" done for l in "$copydir"/build/{namcap,*-{build,check,package,package_*}}.log; do @@ -287,11 +287,7 @@ fi for f in "$copydir"/srcdest/*; do [[ -e $f ]] || continue - if [[ -d $SRCDEST ]]; then - mv "$f" "$SRCDEST" - else - mv "$f" . - fi + mv "$f" "$SRCDEST" done if [[ -e $copydir/build/BUILD_FAILED ]]; then |