Compare commits

...

5 Commits
0.9.5 ... 0.9.6

Author SHA1 Message Date
Pierre Schmitz
12eec95ff8 set version in Makefile 2010-05-02 15:46:51 +02:00
Pierre Schmitz
d4f00819ac copy namcap.log to working dir 2010-05-02 15:42:29 +02:00
Pierre Schmitz
4a4455c086 Set target CARCH before sourcing the PKGBUILD
CARCH might be used within the PKGBUILD to select correct sources
2010-05-02 15:23:54 +02:00
Pierre Schmitz
52e140f2fe exit 1 on build failure 2010-05-02 15:16:53 +02:00
Pierre Schmitz
48dead1af7 Force correct remote file permissions 2010-03-31 23:58:59 +02:00
3 changed files with 10 additions and 6 deletions

View File

@@ -1,3 +1,5 @@
V=0.9.6
all:
install:

View File

@@ -96,7 +96,7 @@ for _arch in ${arch[@]}; do
fi
echo -n 'uploading '
rsync -c -h -L --progress $rsyncopts "${pkgfile}" -e ssh $server:staging/$repo || abort
rsync -p --chmod 'ug=rw,o=r' -c -h -L --progress $rsyncopts "${pkgfile}" -e ssh $server:staging/$repo || abort
done
archrelease $repo-${_arch} || abort
done

View File

@@ -147,6 +147,8 @@ if ! grep 'SRCDEST=/srcdest' "$copydir/etc/makepkg.conf" >/dev/null 2>&1; then
echo 'SRCDEST=/srcdest' >> "$copydir/etc/makepkg.conf"
fi
# Set target CARCH as it might be used within the PKGBUILD to select correct sources
CARCH=$(eval $(grep '^CARCH=' "$copydir/etc/makepkg.conf"))
# Copy PKGBUILD and sources
source PKGBUILD
cp PKGBUILD "$copydir/build/"
@@ -196,7 +198,7 @@ cd /build
export HOME=/build
sudo -u nobody makepkg $MAKEPKG_ARGS || touch BUILD_FAILED
[ -f BUILD_FAILED ] && exit 1
which namcap &>/dev/null && namcap /build/PKGBUILD /pkgdest/*.pkg.tar.* > /pkgdest/namcap.log
which namcap &>/dev/null && namcap /build/PKGBUILD /pkgdest/*.pkg.tar.* > /build/namcap.log
exit 0
EOF
) > "$copydir/chrootbuild"
@@ -205,12 +207,11 @@ chmod +x "$copydir/chrootbuild"
if mkarchroot -r "/chrootbuild" "$copydir"; then
for pkgfile in "${copydir}"/pkgdest/*.pkg.tar.*; do
[ -e "$pkgfile" ] || continue
_pkgname=$(basename "$pkgfile")
if [ "$add_to_db" -eq "1" ]; then
[ -d "${copydir}/repo" ] || mkdir -p "${copydir}/repo"
mkdir -p "${copydir}/repo"
pushd "${copydir}/repo" >/dev/null
cp "$pkgfile" .
repo-add repo.db.tar.gz "$_pkgname"
repo-add repo.db.tar.gz "$(basename "$pkgfile")"
popd >/dev/null
fi
@@ -221,7 +222,7 @@ if mkarchroot -r "/chrootbuild" "$copydir"; then
fi
done
for l in "${copydir}"/build/*-{build,package}.log; do
for l in "${copydir}"/build/{namcap,*-{build,package}}.log; do
[ -f "$l" ] && mv "$l" "${WORKDIR}"
done
else
@@ -241,6 +242,7 @@ done
if [ -e "${copydir}/build/BUILD_FAILED" ]; then
echo "Build failed, check $copydir/build"
rm "${copydir}/build/BUILD_FAILED"
exit 1
else
rm -rf "${copydir}"/build/*
fi