aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlessandro Barbieri <lssndrbarbieri@gmail.com>2022-05-31 17:19:46 +0200
committerAlessandro Barbieri <lssndrbarbieri@gmail.com>2022-05-31 17:36:42 +0200
commit1480b29b69d6d7a8981f94fbca337ae5a2db4cb7 (patch)
tree9733290f6b01c9cc98cf376d86bd8fb8d299b226 /sys-devel
parentdev-cpp/fbthrift: add boost restriction (diff)
downloadguru-1480b29b69d6d7a8981f94fbca337ae5a2db4cb7.tar.gz
guru-1480b29b69d6d7a8981f94fbca337ae5a2db4cb7.tar.bz2
guru-1480b29b69d6d7a8981f94fbca337ae5a2db4cb7.zip
sys-devel/gsl: respect CC and flags
Closes: https://bugs.gentoo.org/847328 Signed-off-by: Alessandro Barbieri <lssndrbarbieri@gmail.com>
Diffstat (limited to 'sys-devel')
-rw-r--r--sys-devel/gsl/files/gsl-4.1.5-respect-flags.patch13
-rw-r--r--sys-devel/gsl/gsl-4.1.5-r1.ebuild11
2 files changed, 24 insertions, 0 deletions
diff --git a/sys-devel/gsl/files/gsl-4.1.5-respect-flags.patch b/sys-devel/gsl/files/gsl-4.1.5-respect-flags.patch
new file mode 100644
index 000000000..9d8ebb5f0
--- /dev/null
+++ b/sys-devel/gsl/files/gsl-4.1.5-respect-flags.patch
@@ -0,0 +1,13 @@
+--- a/src/c
++++ b/src/c
+@@ -156,8 +156,8 @@
+ #
+ case "$($CCNAME --version)" in
+ *gcc*|*GCC*)
+- [ -z "$BOOM_MODEL_NOOPT" ] && CCDEBUG="-O2"
+- [ -z "$BOOM_MODEL_NOOPT" ] && CCNODEBUG="$CCNODEBUG -O2"
++ [ -z "$BOOM_MODEL_NOOPT" ] && CCDEBUG="${CFLAGS}"
++ [ -z "$BOOM_MODEL_NOOPT" ] && CCNODEBUG="$CCNODEBUG ${CFLAGS}"
+ CCOPTS="-D_REENTRANT -D_GNU_SOURCE -Wall -Wno-unused -fno-strict-aliasing"
+ # We assume the following standard libraries are all present.
+ # If your build is failing because of missing libraries then
diff --git a/sys-devel/gsl/gsl-4.1.5-r1.ebuild b/sys-devel/gsl/gsl-4.1.5-r1.ebuild
index 89ffc2238..c42875214 100644
--- a/sys-devel/gsl/gsl-4.1.5-r1.ebuild
+++ b/sys-devel/gsl/gsl-4.1.5-r1.ebuild
@@ -3,6 +3,8 @@
EAPI=8
+inherit toolchain-funcs
+
DESCRIPTION='iMatix GSL code generator'
HOMEPAGE="https://github.com/zeromq/gsl"
SRC_URI="https://github.com/zeromq/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
@@ -15,6 +17,15 @@ IUSE="examples"
DEPEND="dev-libs/libpcre:3"
RDEPEND="${DEPEND}"
+PATCHES=( "${FILESDIR}/${P}-respect-flags.patch" )
+
+src_prepare() {
+ tc-export RANLIB
+ export CCNAME="$(tc-getCC)"
+ export CCPLUS="$(tc-getCXX)"
+ default
+}
+
src_install() {
DESTDIR="${D}/usr" emake install
if use examples; then