summaryrefslogtreecommitdiffstats
path: root/meta/recipes-support/apr/apr_1.7.0.bb
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2022-08-23 23:34:41 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2023-03-14 14:59:10 +0000
commit1904daa987545990813ec0d40936803452ea990a (patch)
tree63872709455df22a077fca5c2f2432fb9253ac0b /meta/recipes-support/apr/apr_1.7.0.bb
parentc86b92df02e97a6bc4c478bd82738f7fdc40363d (diff)
downloadpoky-1904daa987545990813ec0d40936803452ea990a.tar.gz
apr: Use correct strerror_r implementation based on libc type
musl does not implement GNU extention of strerror_r but XSI compliant version, therefore add it via a packageconfig to set right variables during configure to cache the value. configure detection logic depends on runtime test which will always be wrong on cross compiles therefore backport a patch to make it possible to cache the needed configure variable. (From OE-Core rev: 993cfeaefa73e3b82cf15db78584e5f9b9f86ddf) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit ded3d76a844dd1aef9ac610fbe506bf76285369b) Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-support/apr/apr_1.7.0.bb')
-rw-r--r--meta/recipes-support/apr/apr_1.7.0.bb4
1 files changed, 4 insertions, 0 deletions
diff --git a/meta/recipes-support/apr/apr_1.7.0.bb b/meta/recipes-support/apr/apr_1.7.0.bb
index b70edfaf42..b9d3e356da 100644
--- a/meta/recipes-support/apr/apr_1.7.0.bb
+++ b/meta/recipes-support/apr/apr_1.7.0.bb
@@ -24,6 +24,7 @@ SRC_URI = "${APACHE_MIRROR}/apr/${BPN}-${PV}.tar.bz2 \
24 file://libtoolize_check.patch \ 24 file://libtoolize_check.patch \
25 file://0001-Add-option-to-disable-timed-dependant-tests.patch \ 25 file://0001-Add-option-to-disable-timed-dependant-tests.patch \
26 file://autoconf270.patch \ 26 file://autoconf270.patch \
27 file://0001-add-AC_CACHE_CHECK-for-strerror_r-return-type.patch \
27 file://CVE-2021-35940.patch \ 28 file://CVE-2021-35940.patch \
28 " 29 "
29 30
@@ -44,9 +45,12 @@ CACHED_CONFIGUREVARS += "ac_cv_header_netinet_sctp_h=no ac_cv_header_netinet_sct
44CACHED_CONFIGUREVARS += "ac_cv_sizeof_struct_iovec=yes" 45CACHED_CONFIGUREVARS += "ac_cv_sizeof_struct_iovec=yes"
45CACHED_CONFIGUREVARS += "ac_cv_file__dev_zero=yes" 46CACHED_CONFIGUREVARS += "ac_cv_file__dev_zero=yes"
46 47
48CACHED_CONFIGUREVARS:append:libc-musl = " ac_cv_strerror_r_rc_int=yes"
47PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}" 49PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
50PACKAGECONFIG:append:libc-musl = " xsi-strerror"
48PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6," 51PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
49PACKAGECONFIG[timed-tests] = "--enable-timed-tests,--disable-timed-tests," 52PACKAGECONFIG[timed-tests] = "--enable-timed-tests,--disable-timed-tests,"
53PACKAGECONFIG[xsi-strerror] = "ac_cv_strerror_r_rc_int=yes,ac_cv_strerror_r_rc_int=no,"
50 54
51do_configure_prepend() { 55do_configure_prepend() {
52 # Avoid absolute paths for grep since it causes failures 56 # Avoid absolute paths for grep since it causes failures