summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormatoro <matoro@users.noreply.github.com>2022-07-13 19:21:08 -0400
committerMatt Turner <mattst88@gentoo.org>2022-10-22 17:33:10 -0400
commit3e08fd22940d04460ac8200318d3ed89eddcbc6d (patch)
tree26d80885ef21b8fae6ad4d8c1ec538aa586f983e /dev-ruby
parentdev-ruby/ffi: revbump 1.15.5-r1, fix sparc (diff)
downloadgentoo-3e08fd22940d04460ac8200318d3ed89eddcbc6d.tar.gz
gentoo-3e08fd22940d04460ac8200318d3ed89eddcbc6d.tar.bz2
gentoo-3e08fd22940d04460ac8200318d3ed89eddcbc6d.zip
dev-ruby/ffi-compiler: revbump 1.0.1-r2, respect *FLAGS
Signed-off-by: matoro <matoro@users.noreply.github.com> Signed-off-by: Matt Turner <mattst88@gentoo.org>
Diffstat (limited to 'dev-ruby')
-rw-r--r--dev-ruby/ffi-compiler/ffi-compiler-1.0.1-r2.ebuild22
-rw-r--r--dev-ruby/ffi-compiler/files/respect-cflags.patch17
2 files changed, 39 insertions, 0 deletions
diff --git a/dev-ruby/ffi-compiler/ffi-compiler-1.0.1-r2.ebuild b/dev-ruby/ffi-compiler/ffi-compiler-1.0.1-r2.ebuild
new file mode 100644
index 000000000000..6a6262edb1ff
--- /dev/null
+++ b/dev-ruby/ffi-compiler/ffi-compiler-1.0.1-r2.ebuild
@@ -0,0 +1,22 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+USE_RUBY="ruby26 ruby27 ruby30 ruby31"
+
+RUBY_FAKEGEM_EXTRADOC="README.md"
+
+RUBY_FAKEGEM_RECIPE_TEST="none"
+
+inherit ruby-fakegem
+
+DESCRIPTION="Ruby FFI Rakefile generator"
+HOMEPAGE="https://github.com/ffi/ffi/wiki"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc64 ~sparc ~x86"
+IUSE=""
+# PATCHES=( "${FILESDIR}/respect-cflags.patch" )
+
+ruby_add_rdepend "dev-ruby/rake >=dev-ruby/ffi-1.0.0"
diff --git a/dev-ruby/ffi-compiler/files/respect-cflags.patch b/dev-ruby/ffi-compiler/files/respect-cflags.patch
new file mode 100644
index 000000000000..3fe68f8211cb
--- /dev/null
+++ b/dev-ruby/ffi-compiler/files/respect-cflags.patch
@@ -0,0 +1,17 @@
+diff --git a/lib/ffi-compiler/compile_task.rb b/lib/ffi-compiler/compile_task.rb
+index 363c247..637fd3d 100644
+--- a/lib/ffi-compiler/compile_task.rb
++++ b/lib/ffi-compiler/compile_task.rb
+@@ -26,9 +26,9 @@ module FFI
+ @libraries = []
+ @headers = []
+ @functions = []
+- @cflags = DEFAULT_CFLAGS.dup
+- @cxxflags = DEFAULT_CFLAGS.dup
+- @ldflags = DEFAULT_LDFLAGS.dup
++ @cflags = ENV['CFLAGS']&.split || DEFAULT_CFLAGS.dup
++ @cxxflags = ENV['CXXFLAGS']&.split || DEFAULT_CFLAGS.dup
++ @ldflags = ENV['LDFLAGS']&.split || DEFAULT_LDFLAGS.dup
+ @libs = []
+ @platform = Platform.system
+ @exports = []