commit:     470e544d6e3d1fa514eb23aac769ad9953379eff
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Wed Sep 11 22:11:06 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Wed Sep 11 22:12:25 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=470e544d

dev-ruby/grpc: respect MAKEOPTS

extconf.rb uses nproc otherwise.

Bug: https://bugs.gentoo.org/921103
Signed-off-by: Sam James <sam <AT> gentoo.org>

 dev-ruby/grpc/grpc-1.54.0.ebuild | 8 +++++++-
 dev-ruby/grpc/grpc-1.59.2.ebuild | 8 +++++++-
 2 files changed, 14 insertions(+), 2 deletions(-)

diff --git a/dev-ruby/grpc/grpc-1.54.0.ebuild b/dev-ruby/grpc/grpc-1.54.0.ebuild
index 934ddf075b4a..931429078487 100644
--- a/dev-ruby/grpc/grpc-1.54.0.ebuild
+++ b/dev-ruby/grpc/grpc-1.54.0.ebuild
@@ -8,7 +8,7 @@ RUBY_FAKEGEM_EXTENSIONS=(src/ruby/ext/grpc/extconf.rb)
 RUBY_FAKEGEM_EXTRAINSTALL="etc src"
 RUBY_FAKEGEM_RECIPE_TEST="none"
 
-inherit ruby-fakegem
+inherit multiprocessing ruby-fakegem
 
 DESCRIPTION="Send RPCs from Ruby using GRPC"
 HOMEPAGE="https://github.com/grpc/grpc";
@@ -23,6 +23,12 @@ ruby_add_rdepend "
        >=dev-ruby/google-protobuf-3.24.4
 "
 
+each_ruby_configure() {
+       export GRPC_RUBY_BUILD_PROCS="$(makeopts_jobs)"
+
+       each_fakegem_configure
+}
+
 each_ruby_install() {
        # Remove all the "src" bits that are not needed
        rm -rf src/core src/ruby/spec src/ruby/ext/grpc/{libs,objs} || die

diff --git a/dev-ruby/grpc/grpc-1.59.2.ebuild b/dev-ruby/grpc/grpc-1.59.2.ebuild
index 934ddf075b4a..931429078487 100644
--- a/dev-ruby/grpc/grpc-1.59.2.ebuild
+++ b/dev-ruby/grpc/grpc-1.59.2.ebuild
@@ -8,7 +8,7 @@ RUBY_FAKEGEM_EXTENSIONS=(src/ruby/ext/grpc/extconf.rb)
 RUBY_FAKEGEM_EXTRAINSTALL="etc src"
 RUBY_FAKEGEM_RECIPE_TEST="none"
 
-inherit ruby-fakegem
+inherit multiprocessing ruby-fakegem
 
 DESCRIPTION="Send RPCs from Ruby using GRPC"
 HOMEPAGE="https://github.com/grpc/grpc";
@@ -23,6 +23,12 @@ ruby_add_rdepend "
        >=dev-ruby/google-protobuf-3.24.4
 "
 
+each_ruby_configure() {
+       export GRPC_RUBY_BUILD_PROCS="$(makeopts_jobs)"
+
+       each_fakegem_configure
+}
+
 each_ruby_install() {
        # Remove all the "src" bits that are not needed
        rm -rf src/core src/ruby/spec src/ruby/ext/grpc/{libs,objs} || die

Reply via email to