[packages/ruby] extensions subdir may include abi
atler
atler at pld-linux.org
Tue Apr 28 01:30:16 CEST 2026
commit d2c6f4a8fbca367c3856fb5c857036f21b3c83b3
Author: Jan Palus <atler at pld-linux.org>
Date: Mon Apr 27 19:42:14 2026 +0200
extensions subdir may include abi
ruby.spec | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
---
diff --git a/ruby.spec b/ruby.spec
index 7f48570..c5e04a3 100644
--- a/ruby.spec
+++ b/ruby.spec
@@ -909,7 +909,11 @@ ln -s %{gem_dir}/gems/bundler-%{bundler_ver}/lib/bundler.rb $RPM_BUILD_ROOT%{rub
# Move the binary extensions into proper place (if no gem has binary extension,
# the extensions directory might be empty).
-find $RPM_BUILD_ROOT${gem_dir}/extensions/*-%{_target_os}/%{ruby_version}.*/* -maxdepth 0 \
+# https://github.com/ruby/ruby/blob/5483bfc/configure.ac#L280
+if [ -n "%{?_gnu}" ] && [ "%{?_gnu}" != "-gnu" ] && [[ "%{_target_platform}" = *%{?_gnu} ]]; then
+ abi=$(echo "%{?_gnu}" | sed 's/^-gnu/-/')
+fi
+find $RPM_BUILD_ROOT${gem_dir}/extensions/*-%{_target_os}$abi/%{ruby_version}.*/* -maxdepth 0 \
-exec mv '{}' $RPM_BUILD_ROOT%{_libdir}/gems/%{name}/ \; \
|| echo "No gem binary extensions to move."
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/ruby.git/commitdiff/d2c6f4a8fbca367c3856fb5c857036f21b3c83b3
More information about the pld-cvs-commit
mailing list