!5 add loongarch64 support for rubygem-ffi

From: @zhangwenlong01 
Reviewed-by: @jxy_git 
Signed-off-by: @jxy_git
This commit is contained in:
openeuler-ci-bot 2023-05-19 06:26:52 +00:00 committed by Gitee
commit 507ffe472d
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
3 changed files with 1412 additions and 1 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,13 +1,15 @@
%global gem_name ffi
Name: rubygem-%{gem_name}
Version: 1.10.0
Release: 3
Release: 4
Summary: FFI Extensions for Ruby
License: BSD-3-Clause and MIT
URL: https://www.github.com/ffi/ffi
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
Source1: https://www.github.com/ffi/%{gem_name}/archive/%{version}.tar.gz
Source2: ffi-1.10.0-loongarch64.gemspec
Patch0: Remove-taint-support.patch
Patch1: 0001-add-loongarch64-support-for-ffi.patch
BuildRequires: ruby(release) rubygems-devel ruby-devel gcc libffi-devel rubygem(rspec)
%description
Ruby-FFI is a ruby extension for programmatically loading dynamic
@ -28,9 +30,16 @@ Documentation for %{name}.
ln -s %{gem_name}-%{version}/test test
ln -s %{gem_name}-%{version}/spec spec
%patch0 -p1
%ifarch loongarch64
%patch1 -p1
%endif
%build
%ifarch loongarch64
gem build %{SOURCE2}
%else
gem build ../%{gem_name}-%{version}.gemspec
%endif
%gem_install
%install
@ -72,6 +81,9 @@ popd
%{gem_instdir}/ffi.gemspec
%changelog
* Thu May 18 2023 Wenlong Zhang <zhangwenlong@loongson.cn> - 1.10.0-4
- add loongarch64 support for rubygem-ffi
* Tue May 10 2022 yaoxin <yaoxin30@h-partners.com> - 1.10.0-3
- License compliance rectification