diff options
Diffstat (limited to 'dev-libs/libpcre')
-rw-r--r-- | dev-libs/libpcre/Manifest | 7 | ||||
-rw-r--r-- | dev-libs/libpcre/files/libpcre-8.41-fix-stack-size-detection.patch | 17 | ||||
-rw-r--r-- | dev-libs/libpcre/files/libpcre-8.41-sljit_mips-label-statement-fix.patch | 15 | ||||
-rw-r--r-- | dev-libs/libpcre/libpcre-8.41-r1.ebuild | 100 | ||||
-rw-r--r-- | dev-libs/libpcre/libpcre-8.42.ebuild | 96 | ||||
-rw-r--r-- | dev-libs/libpcre/metadata.xml | 32 |
6 files changed, 267 insertions, 0 deletions
diff --git a/dev-libs/libpcre/Manifest b/dev-libs/libpcre/Manifest new file mode 100644 index 000000000000..29a3a46e2d90 --- /dev/null +++ b/dev-libs/libpcre/Manifest @@ -0,0 +1,7 @@ +AUX libpcre-8.41-fix-stack-size-detection.patch 569 BLAKE2B 68f685ccd9ebe0a256f829ff2086d93041dfc872e301a19a234c8da3b834fb5c0da3b510b0f63fff7fc07c1d6680ebfb964ba3dbf1a58b302abb14a393da36a4 SHA512 ac9f6155d055b25bcde26bf11450cb07618d7194e0a2c28e0c38dca4190b3319fbfdb85c97f01210dc7540a708fd4f8879853350d66ae382b54c4704e2e7028b +AUX libpcre-8.41-sljit_mips-label-statement-fix.patch 584 BLAKE2B 6523a93f78730f1689ddb79631e31e134d6de844dfc4b3e63a15aea4f0737773ff0a8e4fbf3e9e80ea920d1da751ba2165a7b3b459dfbe0d8673c9a9da95f63c SHA512 38f133a539f4e09886084e0ff2d30bf69ceb600095f87f32eae42f8f03ada9c1aae0a1eff6763d473f0edfcef047a0c573859d0ada503419a7d663140a92fbb9 +DIST pcre-8.41.tar.bz2 1561874 BLAKE2B 2a97a859237994137190da00c30ba7c15e8631b82b7f200858cf722f1fdd0405d36c24bb716eb099d8107f2f829a85fd7d3497f36cdac51769636989331e7a79 SHA512 cc9cdbeb98c010fe4f093a019bebfb91965dae4c6a48f8e49c38ec8df7d9da7f0d32c12fc58f22c51f1c2f010e72b65bcbf8bbf180060e93edf464fa9a7c3551 +DIST pcre-8.42.tar.bz2 1570171 BLAKE2B f68bac3cf8ff5a81ccba31fd4d8926e05143a25a756e7daba9793467cec9cd8a4766f394f958ffca088b472463a43a31ea77014f2d4505082c1f366a18f30c7a SHA512 b47b923108f6ee0c31409b79d0888314271b482a22590e164d02f21d2112fba22dd0342c24f9ba0f5fcc5b8c65550bad08c476e30a2fc79b34ecf4601ed82f3d +EBUILD libpcre-8.41-r1.ebuild 2756 BLAKE2B 29cc305f8748feae7cad0fe5e11066a75ae212e441d95492c9e6b5f421a51813c32538b4e84294e4ec47a6fcb1d3281a05eccaad8709d8a5e73a9b0d28363d45 SHA512 fedbec7ca069d47f3cd96ba8a514cbe7af0dccfa30a3044f6de6bc94867072821cbfdfccd89ef458e72a79819bf37f9d26ab8e0f9cb11632f3218becd6c7aceb +EBUILD libpcre-8.42.ebuild 2591 BLAKE2B 59f1cd6f60d2dc16c2c927fdf293ece576124566eaeed7027b66ed3f95ac2136226b1fabef44514468d48edf47f497797c811e4a3f5ceeb7fa9fea969c5f7648 SHA512 e3121271f15390c66401cca2eff0e4ab795d4c99254a96bba1007de519f362f212021d2287ccc0b13c7fed994751a1e31c2681a8e233b2efa3d78dc394ed85a8 +MISC metadata.xml 1112 BLAKE2B 640e6cc2fe53eaa86b6e6cdd72d45398c880a27d027441447b6162c70fa30fafe818cae8c08614333b866cfb1176feae365996386a72200232a738d99b592b83 SHA512 eb7e2db9932c108442e69bd3ddf04d8d753dede44f7453b1fa33730ec9cda89e618f4444a0adf3f9e7d09baf8c97ff19831906ad7148a26674269f1efd427e6b diff --git a/dev-libs/libpcre/files/libpcre-8.41-fix-stack-size-detection.patch b/dev-libs/libpcre/files/libpcre-8.41-fix-stack-size-detection.patch new file mode 100644 index 000000000000..b5392677943d --- /dev/null +++ b/dev-libs/libpcre/files/libpcre-8.41-fix-stack-size-detection.patch @@ -0,0 +1,17 @@ +https://bugs.exim.org/show_bug.cgi?id=2173#c4 + +--- a/pcre_exec.c ++++ b/pcre_exec.c +@@ -509,6 +509,12 @@ + (e.g. stopped by repeated call or recursion limit) + */ + ++#ifdef __GNUC__ ++static int ++match(REGISTER PCRE_PUCHAR eptr, REGISTER const pcre_uchar *ecode, ++ PCRE_PUCHAR mstart, int offset_top, match_data *md, eptrblock *eptrb, ++ unsigned int rdepth) __attribute__((noinline,noclone)); ++#endif + static int + match(REGISTER PCRE_PUCHAR eptr, REGISTER const pcre_uchar *ecode, + PCRE_PUCHAR mstart, int offset_top, match_data *md, eptrblock *eptrb, diff --git a/dev-libs/libpcre/files/libpcre-8.41-sljit_mips-label-statement-fix.patch b/dev-libs/libpcre/files/libpcre-8.41-sljit_mips-label-statement-fix.patch new file mode 100644 index 000000000000..0494ccc25ebc --- /dev/null +++ b/dev-libs/libpcre/files/libpcre-8.41-sljit_mips-label-statement-fix.patch @@ -0,0 +1,15 @@ +diff -Naurp pcre-8.41.orig/sljit/sljitNativeMIPS_common.c pcre-8.41/sljit/sljitNativeMIPS_common.c +--- pcre-8.41.orig/sljit/sljitNativeMIPS_common.c 2017-05-07 11:32:25.000000000 -0400 ++++ pcre-8.41/sljit/sljitNativeMIPS_common.c 2017-07-29 17:50:24.508909742 -0400 +@@ -503,9 +503,11 @@ SLJIT_API_FUNC_ATTRIBUTE sljit_s32 sljit + #ifdef SLJIT_IS_FPU_AVAILABLE + return SLJIT_IS_FPU_AVAILABLE; + #elif defined(__GNUC__) ++ { + sljit_sw fir; + asm ("cfc1 %0, $0" : "=r"(fir)); + return (fir >> 22) & 0x1; ++ } + #else + #error "FIR check is not implemented for this architecture" + #endif diff --git a/dev-libs/libpcre/libpcre-8.41-r1.ebuild b/dev-libs/libpcre/libpcre-8.41-r1.ebuild new file mode 100644 index 000000000000..c2d87d6d28f7 --- /dev/null +++ b/dev-libs/libpcre/libpcre-8.41-r1.ebuild @@ -0,0 +1,100 @@ +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 + +inherit eutils multilib libtool flag-o-matic toolchain-funcs multilib-minimal + +DESCRIPTION="Perl-compatible regular expression library" +HOMEPAGE="http://www.pcre.org/" +MY_P="pcre-${PV/_rc/-RC}" +if [[ ${PV} != *_rc* ]] ; then + # Only the final releases are available here. + SRC_URI="mirror://sourceforge/pcre/${MY_P}.tar.bz2 + ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/${MY_P}.tar.bz2" +else + SRC_URI="ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/Testing/${MY_P}.tar.bz2" +fi + +LICENSE="BSD" +SLOT="3" +KEYWORDS="alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" +IUSE="bzip2 +cxx +jit libedit pcre16 pcre32 +readline +recursion-limit static-libs unicode zlib" +REQUIRED_USE="readline? ( !libedit ) + libedit? ( !readline )" + +RDEPEND=" + bzip2? ( app-arch/bzip2 ) + zlib? ( sys-libs/zlib ) + libedit? ( dev-libs/libedit ) + readline? ( sys-libs/readline:0= ) +" +DEPEND=" + ${RDEPEND} + virtual/pkgconfig +" +RDEPEND=" + ${RDEPEND} +" + +S="${WORKDIR}/${MY_P}" + +MULTILIB_CHOST_TOOLS=( + /usr/bin/pcre-config +) + +PATCHES=( + "${FILESDIR}"/${PN}-8.41-sljit_mips-label-statement-fix.patch + "${FILESDIR}"/${PN}-8.41-fix-stack-size-detection.patch +) + +src_prepare() { + epatch "${PATCHES[@]}" + sed -i -e "s:-lpcre ::" libpcrecpp.pc.in || die + elibtoolize +} + +multilib_src_configure() { + local myeconfargs=( + --with-match-limit-recursion=$(usex recursion-limit 8192 MATCH_LIMIT) + $(multilib_native_use_enable bzip2 pcregrep-libbz2) + $(use_enable cxx cpp) + $(use_enable jit) $(use_enable jit pcregrep-jit) + $(use_enable pcre16) + $(use_enable pcre32) + $(multilib_native_use_enable libedit pcretest-libedit) + $(multilib_native_use_enable readline pcretest-libreadline) + $(use_enable static-libs static) + $(use_enable unicode utf) $(use_enable unicode unicode-properties) + $(multilib_native_use_enable zlib pcregrep-libz) + --enable-pcre8 + --enable-shared + --htmldir="${EPREFIX}"/usr/share/doc/${PF}/html + --docdir="${EPREFIX}"/usr/share/doc/${PF} + ) + ECONF_SOURCE="${S}" econf "${myeconfargs[@]}" +} + +multilib_src_compile() { + emake V=1 $(multilib_is_native_abi || echo "bin_PROGRAMS=") +} + +multilib_src_install() { + emake \ + DESTDIR="${D}" \ + $(multilib_is_native_abi || echo "bin_PROGRAMS= dist_html_DATA=") \ + install + gen_usr_ldscript -a pcre +} + +multilib_src_install_all() { + prune_libtool_files +} + +pkg_preinst() { + preserve_old_lib /$(get_libdir)/libpcre.so.0 +} + +pkg_postinst() { + preserve_old_lib_notify /$(get_libdir)/libpcre.so.0 +} diff --git a/dev-libs/libpcre/libpcre-8.42.ebuild b/dev-libs/libpcre/libpcre-8.42.ebuild new file mode 100644 index 000000000000..613e96bb360f --- /dev/null +++ b/dev-libs/libpcre/libpcre-8.42.ebuild @@ -0,0 +1,96 @@ +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit multilib libtool flag-o-matic toolchain-funcs multilib-minimal + +DESCRIPTION="Perl-compatible regular expression library" +HOMEPAGE="http://www.pcre.org/" +MY_P="pcre-${PV/_rc/-RC}" +if [[ ${PV} != *_rc* ]] ; then + # Only the final releases are available here. + SRC_URI="mirror://sourceforge/pcre/${MY_P}.tar.bz2 + ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/${MY_P}.tar.bz2" +else + SRC_URI="ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/Testing/${MY_P}.tar.bz2" +fi + +LICENSE="BSD" +SLOT="3" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" +IUSE="bzip2 +cxx +jit libedit pcre16 pcre32 +readline +recursion-limit static-libs unicode zlib" +REQUIRED_USE="readline? ( !libedit ) + libedit? ( !readline )" + +RDEPEND=" + bzip2? ( app-arch/bzip2 ) + zlib? ( sys-libs/zlib ) + libedit? ( dev-libs/libedit ) + readline? ( sys-libs/readline:0= ) +" +DEPEND=" + ${RDEPEND} + virtual/pkgconfig +" + +S="${WORKDIR}/${MY_P}" + +MULTILIB_CHOST_TOOLS=( + /usr/bin/pcre-config +) + +PATCHES=( + "${FILESDIR}"/${PN}-8.41-fix-stack-size-detection.patch +) + +src_prepare() { + default + sed -i -e "s:-lpcre ::" libpcrecpp.pc.in || die + elibtoolize +} + +multilib_src_configure() { + local myeconfargs=( + --with-match-limit-recursion=$(usex recursion-limit 8192 MATCH_LIMIT) + $(multilib_native_use_enable bzip2 pcregrep-libbz2) + $(use_enable cxx cpp) + $(use_enable jit) + $(use_enable jit pcregrep-jit) + $(use_enable pcre16) + $(use_enable pcre32) + $(multilib_native_use_enable libedit pcretest-libedit) + $(multilib_native_use_enable readline pcretest-libreadline) + $(use_enable static-libs static) + $(use_enable unicode utf) + $(use_enable unicode unicode-properties) + $(multilib_native_use_enable zlib pcregrep-libz) + --enable-pcre8 + --enable-shared + ) + ECONF_SOURCE="${S}" econf "${myeconfargs[@]}" +} + +multilib_src_compile() { + emake V=1 $(multilib_is_native_abi || echo "bin_PROGRAMS=") +} + +multilib_src_install() { + emake \ + DESTDIR="${D}" \ + $(multilib_is_native_abi || echo "bin_PROGRAMS= dist_html_DATA=") \ + install + gen_usr_ldscript -a pcre +} + +multilib_src_install_all() { + find "${ED}" -name "*.la" -delete || die +} + +pkg_preinst() { + preserve_old_lib /$(get_libdir)/libpcre.so.0 +} + +pkg_postinst() { + preserve_old_lib_notify /$(get_libdir)/libpcre.so.0 +} diff --git a/dev-libs/libpcre/metadata.xml b/dev-libs/libpcre/metadata.xml new file mode 100644 index 000000000000..edde7e11c64f --- /dev/null +++ b/dev-libs/libpcre/metadata.xml @@ -0,0 +1,32 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<maintainer type="project"> + <email>base-system@gentoo.org</email> + <name>Gentoo Base System</name> +</maintainer> +<use> + <flag name="bzip2"> + Add support for pcregrep command to search within + bzip2-compressed files (via <pkg>app-arch/bzip2</pkg>). + </flag> + <flag name="pcre16">Build PCRE library for 16 bit characters (e.g. UTF-16).</flag> + <flag name="pcre32">Build PCRE library for 32 bit characters (e.g. UTF-32).</flag> + <flag name="readline"> + Add support for command line editing to pcretest, through + <pkg>sys-libs/readline</pkg>. + </flag> + <flag name="recursion-limit"> + Limit match recursion to 8192; if disabled, the default limit is + used, which is the same as the match limit. + </flag> + <flag name="zlib"> + Add support for pcregrep command to search within + gzip-compressed files (via <pkg>sys-libs/zlib</pkg>). + </flag> +</use> +<upstream> + <remote-id type="cpe">cpe:/a:pcre:pcre</remote-id> + <remote-id type="sourceforge">pcre</remote-id> +</upstream> +</pkgmetadata> |