aboutsummaryrefslogtreecommitdiffstats
path: root/community/pdns/APKBUILD
diff options
context:
space:
mode:
authorJakub Jirutka <jakub@jirutka.cz>2017-02-12 18:12:58 +0100
committerJakub Jirutka <jakub@jirutka.cz>2017-02-12 18:13:47 +0100
commit298d05c9edc9896f45f0db53bbdd4c447af16527 (patch)
tree082fd00e843ee48989a866ec7b48555c847f3015 /community/pdns/APKBUILD
parent1ecef86503193de23a98887ba97b85f1a1507789 (diff)
downloadaports-298d05c9edc9896f45f0db53bbdd4c447af16527.tar.gz
aports-298d05c9edc9896f45f0db53bbdd4c447af16527.tar.bz2
aports-298d05c9edc9896f45f0db53bbdd4c447af16527.tar.xz
community/pdns: improve abuild
Diffstat (limited to 'community/pdns/APKBUILD')
-rw-r--r--community/pdns/APKBUILD40
1 files changed, 11 insertions, 29 deletions
diff --git a/community/pdns/APKBUILD b/community/pdns/APKBUILD
index 40ee6945b1..0b36adedda 100644
--- a/community/pdns/APKBUILD
+++ b/community/pdns/APKBUILD
@@ -13,36 +13,23 @@ depends=""
depends_dev=""
makedepends="$depends_dev boost-dev lua-dev openldap-dev mariadb-dev
postgresql-dev sqlite-dev"
-install="$pkgname.pre-install $pkgname.post-deinstall"
+install="$pkgname.pre-install"
subpackages="$pkgname-doc
$pkgname-backend-bind:backend_bind
$pkgname-backend-ldap:backend_ldap
$pkgname-backend-mysql:backend_mysql
$pkgname-backend-pgsql:backend_pgsql
$pkgname-backend-pipe:backend_pipe
- $pkgname-backend-sqlite3:backend_sqlite3
- "
+ $pkgname-backend-sqlite3:backend_sqlite3"
pkgusers="pdns"
pkggroups="pdns"
source="http://downloads.powerdns.com/releases/pdns-$pkgver.tar.bz2
pdns.initd
- pdns.conf
- "
-
-_builddir="$srcdir/$pkgname-$pkgver"
-
-prepare() {
- local i
- cd "$_builddir"
- for i in $source; do
- case $i in
- *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
- esac
- done
-}
+ pdns.conf"
+builddir="$srcdir/$pkgname-$pkgver"
build() {
- cd "$_builddir"
+ cd "$builddir"
./configure --prefix=/usr \
--sysconfdir=/etc/$pkgname \
--mandir=/usr/share/man \
@@ -57,7 +44,8 @@ build() {
}
package() {
- cd "$_builddir"
+ cd "$builddir"
+
make DESTDIR="$pkgdir" install || return 1
install -m755 -D "$srcdir"/$pkgname.initd \
@@ -69,22 +57,16 @@ package() {
}
backend_bind() { _mv_backend bind; }
-backend_ldap() { _mv_backend ldap openldap; }
-backend_mysql() { _mv_backend gmysql mysql; }
-backend_pgsql() { _mv_backend gpgsql postgresql; }
+backend_ldap() { _mv_backend ldap; }
+backend_mysql() { _mv_backend gmysql; }
+backend_pgsql() { _mv_backend gpgsql; }
backend_pipe() { _mv_backend pipe; }
backend_sqlite3() { _mv_backend gsqlite3 sqlite; }
_mv_backend() {
local backend=$1
pkgdesc="${backend} backend module for PowerDNS"
- depends="$pkgname"
-
- # backend dependencies
- if [ -n "${2-}" ]; then
- depends="${2-}"
- fi
- depends="${depends} ${pkgname}"
+ depends="$pkgname ${2:-}"
mkdir -p "$subpkgdir"/usr/lib/pdns/pdns || return 1
mv "$pkgdir"/usr/lib/pdns/pdns/lib${backend}backend.so \