summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Seifert <soap@gentoo.org>2018-12-01 12:38:12 +0100
committerDavid Seifert <soap@gentoo.org>2018-12-01 12:39:35 +0100
commitbf8936159b56276eb0444560fcd776f13b17db98 (patch)
tree5728d5f0e8433b6b7d6bddcace91e8f6c4ded907 /dev-ruby/charlock_holmes
parentmail-client/thunderbird: bump sqlite3 FTS3 tokenizer patch (diff)
downloadgentoo-bf8936159b56276eb0444560fcd776f13b17db98.tar.gz
gentoo-bf8936159b56276eb0444560fcd776f13b17db98.tar.bz2
gentoo-bf8936159b56276eb0444560fcd776f13b17db98.zip
dev-ruby/charlock_holmes: Always build in C++11 mode
Closes: https://bugs.gentoo.org/653398 Package-Manager: Portage-2.3.52, Repoman-2.3.12 Signed-off-by: David Seifert <soap@gentoo.org>
Diffstat (limited to 'dev-ruby/charlock_holmes')
-rw-r--r--dev-ruby/charlock_holmes/charlock_holmes-0.7.6.ebuild4
-rw-r--r--dev-ruby/charlock_holmes/files/charlock_holmes-0.7.6-gcc5.patch16
2 files changed, 19 insertions, 1 deletions
diff --git a/dev-ruby/charlock_holmes/charlock_holmes-0.7.6.ebuild b/dev-ruby/charlock_holmes/charlock_holmes-0.7.6.ebuild
index b9bbacc1a91b..47c7658b1bd6 100644
--- a/dev-ruby/charlock_holmes/charlock_holmes-0.7.6.ebuild
+++ b/dev-ruby/charlock_holmes/charlock_holmes-0.7.6.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2018 Gentoo Foundation
+# Copyright 1999-2018 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
@@ -26,6 +26,8 @@ CDEPEND="dev-libs/icu:=
DEPEND+=" ${CDEPEND}"
RDEPEND+=" ${CDEPEND}"
+PATCHES=( "${FILESDIR}"/${PN}-0.7.6-gcc5.patch )
+
all_ruby_prepare() {
sed -i -e '/bundler/d' test/helper.rb || die
diff --git a/dev-ruby/charlock_holmes/files/charlock_holmes-0.7.6-gcc5.patch b/dev-ruby/charlock_holmes/files/charlock_holmes-0.7.6-gcc5.patch
new file mode 100644
index 000000000000..944efac19253
--- /dev/null
+++ b/dev-ruby/charlock_holmes/files/charlock_holmes-0.7.6-gcc5.patch
@@ -0,0 +1,16 @@
+--- a/ext/charlock_holmes/extconf.rb
++++ b/ext/charlock_holmes/extconf.rb
+@@ -54,11 +54,8 @@
+ have_library 'icuuc' or abort 'libicuuc missing'
+ have_library 'icudata' or abort 'libicudata missing'
+
+-# icu4c might be built in C++11 mode, but it also might not have been
+-icuconfig = `which icu-config`.chomp if icuconfig.empty?
+-if File.exist?(icuconfig) && `#{icuconfig} --cxxflags`.include?("c++11")
+- $CXXFLAGS << ' -std=c++11'
+-end
++# Always use C++11
++$CXXFLAGS << ' -std=c++11'
+
+ $CFLAGS << ' -Wall -funroll-loops'
+ $CFLAGS << ' -Wextra -O0 -ggdb3' if ENV['DEBUG']