makepkg: check for non-empty pkgbase instead of pkgname

pkgbase is used in the following rm calls, and since pkgname can be
present when pkgbase is not, it is safer to check for pkgbase.

Signed-off-by: Cedric Staniewski <cedric@gmx.ca>
Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
This commit is contained in:
Cedric Staniewski 2009-10-21 16:06:42 +02:00 committed by Dan McGee
parent e09253d15b
commit 335627d72d
1 changed files with 1 additions and 1 deletions

View File

@ -155,7 +155,7 @@ clean_up() {
# If it's a clean exit and -c/--clean has been passed...
msg "$(gettext "Cleaning up...")"
rm -rf "$pkgdir" "$srcdir"
if [ -n "$pkgname" ]; then
if [ -n "$pkgbase" ]; then
# Can't do this unless the BUILDSCRIPT has been sourced.
rm -f "${pkgbase}-${pkgver}-${pkgrel}-${CARCH}-build.log"*
if [ "$PKGFUNC" -eq 1 ]; then