Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/PKGBUILD-split.proto
diff options
context:
space:
mode:
authorAllan McRae <allan@archlinux.org>2009-03-06 18:28:47 +1000
committerAllan McRae <allan@archlinux.org>2009-03-16 09:17:10 +1000
commit7df0d048d1617df2c5472fd2edd6858b3117d52f (patch)
treea839aeb71e81cf25839bf22d7fc8da2d241afaba /PKGBUILD-split.proto
parent9519d22df7cef5b5a48a7d1ebee44a9e935e02b7 (diff)
makepkg: add pkgbase variable
The pkgbase variable is added to improve informational output and source package naming when using split packages. Defaults to ${pkgname[0]} if not set. Also: - move splitpkg detection to after pkgname presence is verified - add "cd" line to package_foo() functions in splitpkg proto Signed-off-by: Allan McRae <allan@archlinux.org>
Diffstat (limited to 'PKGBUILD-split.proto')
-rw-r--r--PKGBUILD-split.proto7
1 files changed, 5 insertions, 2 deletions
diff --git a/PKGBUILD-split.proto b/PKGBUILD-split.proto
index 35fb22b9..0baa4964 100644
--- a/PKGBUILD-split.proto
+++ b/PKGBUILD-split.proto
@@ -5,6 +5,7 @@
# Contributor: Your Name <youremail@domain.com>
pkgname=('pkg1' 'pkg2')
+pkgbase=('pkg')
pkgver=VERSION
pkgrel=1
pkgdesc=""
@@ -20,12 +21,12 @@ replaces=()
backup=()
options=()
install=
-source=($pkgname-$pkgver.tar.gz)
+source=($pkgbase-$pkgver.tar.gz)
noextract=()
md5sums=() #generate with 'makepkg -g'
build() {
- cd "$srcdir/$pkgname-$pkgver"
+ cd "$srcdir/$pkgbase-$pkgver"
./configure --prefix=/usr
make || return 1
}
@@ -44,6 +45,7 @@ package_pkg1() {
options=()
install=
+ cd "$srcdir/$pkgbase-$pkgver"
make DESTDIR="$pkgdir/" install-pkg1
}
@@ -51,5 +53,6 @@ package_pkg2() {
# options and directives overrides
pkgdesc=""
+ cd "$srcdir/$pkgbase-$pkgver"
make DESTDIR="$pkgdir/" install-pkg2
}