diff options
author | Fabian Affolter <fabian@affolter-engineering.ch> | 2013-10-30 09:54:33 +0000 |
---|---|---|
committer | Fabian Affolter <fabian@affolter-engineering.ch> | 2015-08-01 12:49:31 +0200 |
commit | 265e5869b12aceb81b62954e64ca10d4d86190b7 (patch) | |
tree | 4aeeb8b4a02ca3b2803df0c641eb9a526e1ba51d | |
parent | 3020891009a6024b46bc779568644ce16605bda9 (diff) | |
download | abuild-265e5869b12aceb81b62954e64ca10d4d86190b7.tar.bz2 abuild-265e5869b12aceb81b62954e64ca10d4d86190b7.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 |