diff options
author | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2018-02-27 14:34:02 -0600 |
---|---|---|
committer | A. Wilcox <AWilcox@Wilcox-Tech.com> | 2018-02-27 14:34:02 -0600 |
commit | 7553795ec2d735c01dbdde129a65b7f45d5aa999 (patch) | |
tree | b3970009a8246b0c17a105fe6b10c8077fc2b763 /harmony/pcre | |
parent | e2b01859c88d221992403d1293d42da33002be4d (diff) | |
download | packages-7553795ec2d735c01dbdde129a65b7f45d5aa999.tar.gz packages-7553795ec2d735c01dbdde129a65b7f45d5aa999.tar.bz2 packages-7553795ec2d735c01dbdde129a65b7f45d5aa999.tar.xz packages-7553795ec2d735c01dbdde129a65b7f45d5aa999.zip |
Add harmony/ repo for packages still being discussed
See https://wiki.adelielinux.org/wiki/Project:Harmony
Diffstat (limited to 'harmony/pcre')
-rw-r--r-- | harmony/pcre/APKBUILD | 90 |
1 files changed, 90 insertions, 0 deletions
diff --git a/harmony/pcre/APKBUILD b/harmony/pcre/APKBUILD new file mode 100644 index 000000000..43ac2a9d6 --- /dev/null +++ b/harmony/pcre/APKBUILD @@ -0,0 +1,90 @@ +# Contributor: Sergei Lukin <sergej.lukin@gmail.com> +# Maintainer: Natanael Copa <ncopa@alpinelinux.org> +pkgname=pcre +pkgver=8.41 +pkgrel=1 +pkgdesc="Perl-compatible regular expression library" +url="http://pcre.sourceforge.net" +arch="all" +license="BSD" +depends= +makedepends="" +checkdepends="paxmark" +subpackages="$pkgname-dev $pkgname-doc $pkgname-tools + libpcrecpp libpcre16 libpcre32" +source="ftp://ftp.csx.cam.ac.uk/pub/software/programming/$pkgname/$pkgname-$pkgver.tar.bz2 + " + +# secfixes: +# 8.40-r2: +# - CVE-2017-7186 +# 7.8-r0: +# - CVE-2017-11164 + +builddir="$srcdir/$pkgname-$pkgver" + +build() { + cd "$builddir" + ([ "$CARCH" = "s390x" ] || [ "$CARCH" = "ppc64" ]) && _enable_jit="" || _enable_jit="--enable-jit" + ./configure \ + --build=$CBUILD \ + --host=$CHOST \ + --prefix=/usr \ + $_enable_jit \ + --enable-utf8 \ + --enable-unicode-properties \ + --enable-pcre8 \ + --enable-pcre16 \ + --enable-pcre32 \ + --with-match-limit-recursion=8192 \ + --htmldir=/usr/share/doc/$pkgname-$pkgver/html \ + --docdir=/usr/share/doc/$pkgname-$pkgver + + make +} + +package() { + cd "$builddir" + make DESTDIR="$pkgdir" install +} + +check() { + cd "$builddir" + + # paxmark tests requiring JIT + for fn in pcre_jit_test pcretest; do + ./$fn &>/dev/null < /dev/null || true + [ -x .libs/lt-$fn ] && paxmark -m .libs/lt-$fn + done + + # skip locale specific tests + sed -i -e 's/do3=yes//g' RunTest + + make check +} + +libpcrecpp() { + pkgdesc="C++ bindings for PCRE" + mkdir -p "$subpkgdir"/usr/lib + mv "$pkgdir"/usr/lib/libpcrecpp.so* "$subpkgdir"/usr/lib/ +} + +libpcre16() { + pkgdesc="PCRE with 16 bit character support" + mkdir -p "$subpkgdir"/usr/lib + mv "$pkgdir"/usr/lib/libpcre16.so* "$subpkgdir"/usr/lib/ +} + +libpcre32() { + pkgdesc="PCRE with 32 bit character support" + mkdir -p "$subpkgdir"/usr/lib + mv "$pkgdir"/usr/lib/libpcre32.so* "$subpkgdir"/usr/lib/ +} + +tools() { + pkgdesc="Auxiliary utilities for PCRE" + mkdir -p "$subpkgdir"/usr/ + mv "$pkgdir"/usr/bin "$subpkgdir"/usr/ +} + +sha512sums="cc9cdbeb98c010fe4f093a019bebfb91965dae4c6a48f8e49c38ec8df7d9da7f0d32c12fc58f22c51f1c2f010e72b65bcbf8bbf180060e93edf464fa9a7c3551 pcre-8.41.tar.bz2" |