add loongarch64 and sw_64 support

(cherry picked from commit 540cc43b82071787b57addc2fbb2a00354a546e8)
This commit is contained in:
yeqinglong 2023-08-10 15:14:48 +08:00 committed by openeuler-sync-bot
parent 7b1a468a1d
commit 8e7d762869

View File

@ -4,7 +4,7 @@
Name: umoci
Version: 0.4.7
Release: 2
Release: 3
Summary: Open Container Image manipulation tool
License: ISC and MIT and Apache-2.0
URL: https://github.com/opencontainers/umoci
@ -23,6 +23,13 @@ the OCI.
%prep
%autosetup -n %{name}-%{version} -p1
tar -xf %SOURCE1
%ifarch loongarch64 sw_64
# Replace sys provided by golang
cp -af %{_prefix}/lib/golang/src/cmd/vendor/golang.org/x/sys vendor/golang.org/x/
%endif
%ifarch sw_64
sed -i 's/-buildmode=pie/-buildmode=exe/g' `grep buildmode=pie -rl .`
%endif
%build
cd go-md2man-*
@ -55,6 +62,9 @@ done
%{_mandir}/man1/umoci*
%changelog
* Thu Aug 10 2023 yeqinglong <yeqinglong@kylinsec.com.cn> - 0.4.7-3
- add loongarch64 and sw_64 support
* Tue Feb 15 2022 caodongxia <caodongxia@huawei.com> - 0.4.7-2
- fix bad build flags