diff options
author | Fabian Affolter <fabian@affolter-engineering.ch> | 2013-10-30 09:54:33 +0000 |
---|---|---|
committer | Fabian Affolter <fabian@affolter-engineering.ch> | 2014-05-14 17:28:51 +0000 |
commit | 7493941bd47706dc771711e6347cbd5050eca64d (patch) | |
tree | f6033d90d3851c9a74ee222e89eb6c503a55c0cd | |
parent | aed6c05351c8db85bc758a62e9fd162591899c03 (diff) | |
download | abuild-7493941bd47706dc771711e6347cbd5050eca64d.tar.bz2 abuild-7493941bd47706dc771711e6347cbd5050eca64d.tar.xz |
sync with template built by newapkbuild
-rw-r--r-- | sample.APKBUILD | 36 |
1 files changed, 24 insertions, 12 deletions
diff --git a/sample.APKBUILD b/sample.APKBUILD index 342a28e..fc7393a 100644 --- a/sample.APKBUILD +++ b/sample.APKBUILD @@ -7,38 +7,50 @@ # Maintainer: Your Name <youremail@domain.com> pkgname=NAME pkgver=VERSION -pkgrel=0 pkgdesc="" url="" arch="all" -license="GPL" -depends= -depends_dev= +license="" +depends="" +depends_dev="" makedepends="$depends_dev" -install= +install="$pkgname.pre-install $pkgname.post-install" subpackages="$pkgname-dev $pkgname-doc" -source="http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.gz" - +source="http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.gz + # remove the 2 lines below (and this) if there is no init.d script + # $pkgname.initd + # $pkgname.confd + " _builddir="$srcdir"/$pkgname-$pkgver - prepare() { + local i cd "$_builddir" - # apply patches here + for i in $source; do + case $i in + *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; + esac + done } build() { cd "$_builddir" - ./configure --prefix=/usr \ + ./configure \ + --build=$CBUILD \ + --host=$CHOST \ + --prefix=/usr \ --sysconfdir=/etc \ --mandir=/usr/share/man \ - --infodir=/usr/share/info + --infodir=/usr/share/info \ + --localstatedir=/var \ + || return 1 make || return 1 } package() { cd "$_builddir" - make DESTDIR="$pkgdir" install + make DESTDIR="$pkgdir" install || return 1 + rm -f "$pkgdir"/usr/lib/*.la # remove the 2 lines below (and this) if there is no init.d script # install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname |