commit: e1ab113ab5191355b1c4738ddef01a79126710ae Author: Sam James <sam <AT> gentoo <DOT> org> AuthorDate: Tue Feb 28 23:31:30 2023 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Wed Mar 1 02:30:15 2023 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e1ab113a
sci-libs/gsl: fix configure w/ clang 16 Closes: https://bugs.gentoo.org/898410 Signed-off-by: Sam James <sam <AT> gentoo.org> .../gsl/files/gsl-2.7.1-configure-clang16.patch | 26 ++++++++++++++++++++++ .../{gsl-2.7.1-r1.ebuild => gsl-2.7.1-r2.ebuild} | 10 +++++---- 2 files changed, 32 insertions(+), 4 deletions(-) diff --git a/sci-libs/gsl/files/gsl-2.7.1-configure-clang16.patch b/sci-libs/gsl/files/gsl-2.7.1-configure-clang16.patch new file mode 100644 index 000000000000..ba239563a38e --- /dev/null +++ b/sci-libs/gsl/files/gsl-2.7.1-configure-clang16.patch @@ -0,0 +1,26 @@ +https://bugs.gentoo.org/898410 +https://savannah.gnu.org/bugs/?63679 + +Avoid calling the undeclared exit function and future failures +with compilers which do not support implicit function declarations. + +--- a/configure.ac ++++ b/configure.ac +@@ -449,7 +449,7 @@ int main (void) + inf = exp(1.0e10); + nan = inf / inf ; + status = (nan == nan); +- exit (status); ++ return status; + }]])],[ac_cv_c_ieee_comparisons="yes"],[ac_cv_c_ieee_comparisons="no"],[ac_cv_c_ieee_comparisons="yes"]) + ]) + +@@ -469,7 +469,7 @@ int main (void) + for (i = 0; i < 5; i++) { z = z / 10.0 ; }; + for (i = 0; i < 5; i++) { z = z * 10.0 ; }; + status = (z == 0.0); +- exit (status); ++ return status; + }]])],[ac_cv_c_ieee_denormals="yes"],[ac_cv_c_ieee_denormals="no"],[ac_cv_c_ieee_denormals="yes"]) + ]) + diff --git a/sci-libs/gsl/gsl-2.7.1-r1.ebuild b/sci-libs/gsl/gsl-2.7.1-r2.ebuild similarity index 93% rename from sci-libs/gsl/gsl-2.7.1-r1.ebuild rename to sci-libs/gsl/gsl-2.7.1-r2.ebuild index 64e427099641..e65ec799e0d2 100644 --- a/sci-libs/gsl/gsl-2.7.1-r1.ebuild +++ b/sci-libs/gsl/gsl-2.7.1-r2.ebuild @@ -1,7 +1,7 @@ -# Copyright 1999-2022 Gentoo Authors +# Copyright 1999-2023 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=7 +EAPI=8 inherit autotools flag-o-matic toolchain-funcs @@ -22,20 +22,22 @@ BDEPEND="virtual/pkgconfig" PATCHES=( "${WORKDIR}"/${PN}-2.7-cblas.patch + "${FILESDIR}"/${PN}-2.7.1-configure-clang16.patch ) src_prepare() { - filter-flags -ffast-math - default if use deprecated; then sed -i -e "/GSL_DISABLE_DEPRECATED/,+2d" configure.ac || die fi + eautoreconf } src_configure() { + filter-flags -ffast-math + if use cblas-external; then export CBLAS_LIBS="$($(tc-getPKG_CONFIG) --libs cblas)" export CBLAS_CFLAGS="$($(tc-getPKG_CONFIG) --cflags cblas)"
