diff options
Diffstat (limited to 'dev-libs/apr')
-rw-r--r-- | dev-libs/apr/Manifest | 1 | ||||
-rw-r--r-- | dev-libs/apr/apr-1.7.4-r1.ebuild | 150 |
2 files changed, 151 insertions, 0 deletions
diff --git a/dev-libs/apr/Manifest b/dev-libs/apr/Manifest index 6b8c7cbb4921..8b57e88e87d5 100644 --- a/dev-libs/apr/Manifest +++ b/dev-libs/apr/Manifest @@ -11,5 +11,6 @@ DIST apr-1.7.4.tar.bz2 894526 BLAKE2B a93b9d3f2c46fe0a34ce1d544e7a43ba40720e2fae EBUILD apr-1.7.2-r1.ebuild 3747 BLAKE2B 930ea9f82e48a1d53f9658f00f5a144549814d5e95febb08f232f0f12a716a305f76cdb6670017fb8973ed33e5b30ac532f97268b119a9001192cee94d18e5c1 SHA512 831a343f765fc6cdd33c5e773838a9c125c2a94b9e88923843a5fbd6e683d32aa6aedd93dedefab379c710a36bca4565eb18b15014293ae330cc50cae35d4382 EBUILD apr-1.7.2.ebuild 3693 BLAKE2B 214f0a25eb988f0198c343ecf422fd4d6b510009049a21469ed55726c1c83271811a37e665faa35e4e6a74d352a861343e3f9f96b8961dee5ac8ed7a47a127fb SHA512 dce3f7ad05ddcbbb637254c47f776200aff8dc6cd3178dad9613c490a1cee7bfac42622f8c22fa9b9b82c901e1dd2281f0acb03649dc4357f3b7b45c3b486036 EBUILD apr-1.7.3.ebuild 3741 BLAKE2B 88f85efbcafea7bf473daf725f61bcd259207aa9802c0d3b784583146b97e1eac1ecffadcab9a920126557c190d1342237cfe2759ace0b71d1a6225522a12db8 SHA512 45ff76a68141d32613a8927bdb10d448f443d4e2665e3ca6136498ed770d33edfcd57d59c6ead78eb62d2d954dc979838ca989ca0c42de75d3ce23e7f19c9199 +EBUILD apr-1.7.4-r1.ebuild 3846 BLAKE2B e15f300ca2496f38d97c6df51b6d3332e085d7dbdab30530628e095f310ab1c9309882c9027861f5ea64185f9e9b0ee5ee018cbe45239dcbdb2e3d52c486d3bd SHA512 56618a852633168e59c3d3a9c34380b385e3b3d382b5922a073460cf6bf1861e130b39df34d99229b8e5e5054abaac22538e75c99d8edea6576bfc6051becea6 EBUILD apr-1.7.4.ebuild 3816 BLAKE2B e2dd29c206603d9f1b156edceb8ce14e75ee20ae919e1948775d1629a046f30e672126f50b2aa0083514947b2a00bab4ad9f699079a5fbab29268d96c585d328 SHA512 d7e841f1ce6eb00beca0ecacfdd27abc263f74ed3808fbc539f64b08d981bdde98af200e977d6809170449c6795e2ccb5b93a304867adddfcd60adb767e0df42 MISC metadata.xml 487 BLAKE2B 826e5b4b8b87d0077f1b2063ae1c808447987ddea524eeb4cdd17d60bea8b3919a2a714cdb0706cf758dfcf86109b702399c04dd054872d8465e1f6b3469c795 SHA512 9e8fbae61974080394151944ca7e2fec92a6c99b2c2fe75dc2486dced890933ac4694c8ac2984504bbfe42706bed6895b7d5fe9f9a9ced96c5c0ead8016f4366 diff --git a/dev-libs/apr/apr-1.7.4-r1.ebuild b/dev-libs/apr/apr-1.7.4-r1.ebuild new file mode 100644 index 000000000000..b422544bfc7c --- /dev/null +++ b/dev-libs/apr/apr-1.7.4-r1.ebuild @@ -0,0 +1,150 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools flag-o-matic toolchain-funcs + +DESCRIPTION="Apache Portable Runtime Library" +HOMEPAGE="https://apr.apache.org/" +SRC_URI="mirror://apache/apr/${P}.tar.bz2" + +LICENSE="Apache-2.0" +SLOT="1/${PV%.*}" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris" +IUSE="doc old-kernel selinux static-libs +urandom valgrind" + +# See bug #815265 for libcrypt dependency +DEPEND=" + virtual/libcrypt:= + elibc_glibc? ( >=sys-apps/util-linux-2.16 ) +" +RDEPEND=" + ${DEPEND} + selinux? ( sec-policy/selinux-base-policy ) +" +DEPEND+=" valgrind? ( dev-util/valgrind )" +BDEPEND=" + >=sys-devel/libtool-2.4.2 + doc? ( app-doc/doxygen ) +" + +DOCS=( CHANGES NOTICE README ) + +PATCHES=( + "${FILESDIR}"/${PN}-1.6.3-skip-known-failing-tests.patch + "${FILESDIR}"/${PN}-1.7.2-libtool.patch + "${FILESDIR}"/${PN}-1.7.2-sysroot.patch # bug #385775 + "${FILESDIR}"/${PN}-1.7.2-fix-pkgconfig-libs.patch + "${FILESDIR}"/${PN}-1.7.2-respect-flags.patch + "${FILESDIR}"/${PN}-1.7.2-autoconf-2.72.patch + "${FILESDIR}"/config.layout.patch +) + +src_prepare() { + default + + mv configure.in configure.ac || die + AT_M4DIR="build" eautoreconf +} + +src_configure() { + tc-export AS CC CPP + + local myconf=( + --enable-layout=gentoo + --enable-nonportable-atomics + --enable-posix-shm + --enable-threads + $(use_enable static-libs static) + $(use_with valgrind) + --with-installbuilddir="${EPREFIX}"/usr/share/${PN}/build + ) + + tc-is-static-only && myconf+=( --disable-dso ) + + if use old-kernel; then + local apr_cv_accept4 apr_cv_dup3 apr_cv_epoll_create1 apr_cv_sock_cloexec + export apr_cv_accept4="no" + export apr_cv_dup3="no" + export apr_cv_epoll_create1="no" + export apr_cv_sock_cloexec="no" + fi + + if tc-is-cross-compiler; then + # The apache project relies heavily on AC_TRY_RUN and doesn't + # have any sane cross-compiling fallback logic. + export \ + ac_cv_file__dev_zero="yes" \ + ac_cv_func_sem_open="yes" \ + ac_cv_mmap__dev_zero="yes" \ + ac_cv_negative_eai="yes" \ + ac_cv_o_nonblock_inherited="no" \ + ac_cv_struct_rlimit="yes" \ + ap_cv_atomic_builtins="yes" \ + apr_cv_accept4="yes" \ + apr_cv_dup3="yes" \ + apr_cv_epoll="yes" \ + apr_cv_epoll_create1="yes" \ + apr_cv_gai_addrconfig="yes" \ + apr_cv_mutex_recursive="yes" \ + apr_cv_mutex_robust_shared="yes" \ + apr_cv_process_shared_works="yes" \ + apr_cv_pthreads_lib="-pthread" \ + apr_cv_sock_cloexec="yes" \ + apr_cv_tcp_nodelay_with_cork="yes" + fi + + if use urandom; then + myconf+=( --with-devrandom=/dev/urandom ) + else + myconf+=( --with-devrandom=/dev/random ) + fi + + # Avoid libapr containing undefined references (underlinked) + # undefined reference to `__sync_val_compare_and_swap_8' + # (May be possible to fix via libatomic linkage in future?) + # bug #740464 + append-atomic-flags + if [[ ${LIBS} == *atomic* ]] ; then + myconf+=( --disable-nonportable-atomics ) + fi + + econf "${myconf[@]}" +} + +src_compile() { + if tc-is-cross-compiler; then + # This header is the same across targets, so use the build compiler. + emake tools/gen_test_char + + tc-export_build_env BUILD_CC + ${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_CPPFLAGS} ${BUILD_LDFLAGS} \ + tools/gen_test_char.c -o tools/gen_test_char || die + fi + + emake all $(usev doc dox) +} + +src_test() { + # Building tests in parallel is broken + emake -j1 check +} + +src_install() { + default + + if ! use static-libs; then + find "${ED}" -name '*.la' -delete || die + fi + + if use doc; then + docinto html + dodoc -r docs/dox/html/* + fi + + # This file is only used on AIX systems, which Gentoo is not, + # and causes collisions between the SLOTs, so remove it. + # Even in Prefix, we don't need this on AIX. + rm "${ED}/usr/$(get_libdir)/apr.exp" || die +} |