commit: e971f6c01ee6574d167e767a4854a61e117cb5cc Author: Z. Liu <zhixu.liu <AT> gmail <DOT> com> AuthorDate: Tue Oct 28 13:29:44 2025 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Thu Dec 4 01:21:51 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e971f6c0
app-containers/crun: fix building on musl The reason is the same as in commit a4aa03f192a3b51ffce6e540220c3b466d3381ae, which had been fixed upstream in https://github.com/containers/crun/pull/1887. However, since we cannot provide a single patch for all the thress versions in the tree, this is fixed by using sed to remove error.h from AC_CHECK_HEADERS and append a new line with AC_CHECK_FUNC included. Closes: https://bugs.gentoo.org/956287 Closes: https://bugs.gentoo.org/963641 Signed-off-by: Z. Liu <zhixu.liu <AT> gmail.com> Part-of: https://github.com/gentoo/gentoo/pull/44377 Closes: https://github.com/gentoo/gentoo/pull/44377 Signed-off-by: Sam James <sam <AT> gentoo.org> app-containers/crun/crun-1.19.1.ebuild | 11 ++++++++++- app-containers/crun/crun-1.20.ebuild | 11 ++++++++++- app-containers/crun/crun-1.21.ebuild | 11 ++++++++++- 3 files changed, 30 insertions(+), 3 deletions(-) diff --git a/app-containers/crun/crun-1.19.1.ebuild b/app-containers/crun/crun-1.19.1.ebuild index af92ab475fd3..0e59b651b1eb 100644 --- a/app-containers/crun/crun-1.19.1.ebuild +++ b/app-containers/crun/crun-1.19.1.ebuild @@ -5,7 +5,7 @@ EAPI=8 PYTHON_COMPAT=( python3_{10..13} ) -inherit libtool python-any-r1 +inherit autotools libtool python-any-r1 DESCRIPTION="A fast and low-memory footprint OCI Container Runtime fully written in C" HOMEPAGE="https://github.com/containers/crun" @@ -40,6 +40,15 @@ BDEPEND=" src_prepare() { default elibtoolize + + # https://github.com/containers/crun/pull/1887 + sed -i -E '/AC_CHECK_HEADERS\(\[error.h/{ + s/error\.h[[:space:]]*//g + a\ + AC_CHECK_HEADER([error.h], [AC_CHECK_FUNC([error], AC_DEFINE([HAVE_ERROR_H], [1], [Define if error.h is usable]))]) + }' configure.ac || die + + eautoreconf } src_configure() { diff --git a/app-containers/crun/crun-1.20.ebuild b/app-containers/crun/crun-1.20.ebuild index 1a97040741a2..8d8b91f378e0 100644 --- a/app-containers/crun/crun-1.20.ebuild +++ b/app-containers/crun/crun-1.20.ebuild @@ -5,7 +5,7 @@ EAPI=8 PYTHON_COMPAT=( python3_{10..13} ) -inherit libtool python-any-r1 +inherit autotools libtool python-any-r1 DESCRIPTION="A fast and low-memory footprint OCI Container Runtime fully written in C" HOMEPAGE="https://github.com/containers/crun" @@ -40,6 +40,15 @@ BDEPEND=" src_prepare() { default elibtoolize + + # https://github.com/containers/crun/pull/1887 + sed -i -E '/AC_CHECK_HEADERS\(\[error.h/{ + s/error\.h[[:space:]]*//g + a\ + AC_CHECK_HEADER([error.h], [AC_CHECK_FUNC([error], AC_DEFINE([HAVE_ERROR_H], [1], [Define if error.h is usable]))]) + }' configure.ac || die + + eautoreconf } src_configure() { diff --git a/app-containers/crun/crun-1.21.ebuild b/app-containers/crun/crun-1.21.ebuild index 16f0b6821136..eb94320c065f 100644 --- a/app-containers/crun/crun-1.21.ebuild +++ b/app-containers/crun/crun-1.21.ebuild @@ -5,7 +5,7 @@ EAPI=8 PYTHON_COMPAT=( python3_{11..14} ) -inherit libtool python-any-r1 +inherit autotools libtool python-any-r1 DESCRIPTION="Fast and low-memory footprint OCI Container Runtime fully written in C" HOMEPAGE="https://github.com/containers/crun" @@ -42,6 +42,15 @@ BDEPEND=" src_prepare() { default elibtoolize + + # https://github.com/containers/crun/pull/1887 + sed -i -E '/AC_CHECK_HEADERS\(\[error.h/{ + s/error\.h[[:space:]]*//g + a\ + AC_CHECK_HEADER([error.h], [AC_CHECK_FUNC([error], AC_DEFINE([HAVE_ERROR_H], [1], [Define if error.h is usable]))]) + }' configure.ac || die + + eautoreconf } src_configure() {
