diff options
Diffstat (limited to 'build.macros.in')
-rw-r--r-- | build.macros.in | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/build.macros.in b/build.macros.in index baca002..1036db5 100644 --- a/build.macros.in +++ b/build.macros.in @@ -489,6 +489,7 @@ popd # %__ruby_module_name %{?oname}%{!?oname:%(echo %{name}|cut -d\- -f2-)} +%gem_name %__ruby_module_name %gem_setup \ %setup -q \ @@ -514,19 +515,18 @@ sed -i -e 's/`git ls-files`/`find -type f`/' \\\ --install-dir %{buildroot}%{ruby_gemdir} \\\ --bindir %{buildroot}%{_bindir} \ %{-d: \ - mkdir -p %{buildroot}%{ruby_vendorarchdir} \ - for f in $(find %{buildroot}%{ruby_gemdir}/gems/%{__ruby_module_name}-%{version}/ext -name *.h); do \ - mv $f %{buildroot}%{ruby_vendorarchdir}/ \ - done \ + (cd %{buildroot}%{gem_instdir}; \\\ + for f in $(find -name *.h); do \\\ + mkdir -p %{buildroot}%{gem_extdir_mri}/$(dirname $f); \\\ + mv $f %{buildroot}%{gem_extdir_mri}/$f; \\\ + done ) \ } \ - (cd %{buildroot}%{ruby_gemdir}/gems/%{__ruby_module_name}-%{version}; \\\ - for f in $(find -name '*.so'); do \\\ - dest=${f##./ext/}; \\\ - dest=${dest##./lib/}; \\\ - mkdir -p %{buildroot}%{ruby_sitearchdir}/$(dirname $dest); \\\ - mv $f %{buildroot}%{ruby_sitearchdir}/$dest; done ) \ + (cd %{buildroot}%{gem_instdir}; \\\ + for f in $(find -name '*.so'); do \\\ + mkdir -p %{buildroot}%{gem_extdir_mri}/$(dirname $f); \\\ + mv $f %{buildroot}%{gem_extdir_mri}/$f; done ) \ rm -fr %{buildroot}%{ruby_gemdir}/{cache,gems/%{__ruby_module_name}-%{version}/ext,gems/%{__ruby_module_name}-%{version}/%{__ruby_module_name}.gemspec} \ - find %{buildroot}%{ruby_gemdir}/gems/%{__ruby_module_name}-%{version} -maxdepth 1 -type f -delete \ + find %{buildroot}%{gem_instdir} -maxdepth 1 -type f -delete \ #------------------------------------------------------------------------------ # Systemd and general service related macros |