aboutsummaryrefslogtreecommitdiffstats
path: root/main/json-c
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2017-06-15 20:04:06 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2017-06-15 20:04:06 +0000
commit95a6aa527d50a397ef8c826000c80188a21482bf (patch)
tree6e540c09c1c5e4e21de0a03fa4a4ed009107e5f6 /main/json-c
parent80029b29454d18f4bc0e6db839c7ad972d5a1419 (diff)
downloadaports-95a6aa527d50a397ef8c826000c80188a21482bf.tar.bz2
aports-95a6aa527d50a397ef8c826000c80188a21482bf.tar.xz
main/json-c: build static library
fixes #7424
Diffstat (limited to 'main/json-c')
-rw-r--r--main/json-c/APKBUILD25
1 files changed, 13 insertions, 12 deletions
diff --git a/main/json-c/APKBUILD b/main/json-c/APKBUILD
index 6fca893ca5..467ad6790f 100644
--- a/main/json-c/APKBUILD
+++ b/main/json-c/APKBUILD
@@ -1,7 +1,7 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=json-c
pkgver=0.12.1
-pkgrel=0
+pkgrel=1
pkgdesc="A JSON implementation in C"
url="https://github.com/json-c/json-c/wiki"
arch="all"
@@ -10,40 +10,41 @@ depends=""
depends_dev=""
makedepends="$depends_dev autoconf automake libtool"
install=""
-subpackages="$pkgname-dev"
+subpackages="$pkgname-static $pkgname-dev"
source="https://s3.amazonaws.com/${pkgname}_releases/releases/$pkgname-${pkgver}.tar.gz
"
-_builddir="$srcdir"/json-c-$pkgver
+builddir="$srcdir"/json-c-$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
+ cd "$builddir"
+ default_prepare
autoreconf -f -v -i
}
build() {
- cd "$_builddir"
+ cd "$builddir"
./configure --prefix=/usr \
--sysconfdir=/etc \
--mandir=/usr/share/man \
--infodir=/usr/share/info \
--localstatedir=/var \
- --disable-static \
--enable-shared \
|| return 1
make -j1 || return 1
}
package() {
- cd "$_builddir"
+ cd "$builddir"
make -j1 DESTDIR="$pkgdir" install || return 1
}
+static() {
+ pkgdesc="Static json-c library"
+ mkdir -p "$subpkgdir"/usr/lib
+ mv "$pkgdir"/usr/lib/*.a "$subpkgdir"/usr/lib/
+}
+
md5sums="55f7853f7d8cf664554ce3fa71bf1c7d json-c-0.12.1.tar.gz"
sha256sums="2a136451a7932d80b7d197b10441e26e39428d67b1443ec43bbba824705e1123 json-c-0.12.1.tar.gz"
sha512sums="038676a0ce815e5174161fbd4339524feadc294d517f732fb408ad6aa7c4906423451c13386107569d9f24746a1a101564ca511e92e8276c5bf5b8c022ca42ed json-c-0.12.1.tar.gz"