iSulad-img.spec 1.2 KB
Newer Older
W
WangFengTu 已提交
1
%global _version 2.0.0
W
WangFengTu 已提交
2
%global _release 20200420.005423.git3cd302f6
3
Name:       iSulad-img
O
overweight 已提交
4
Version:    %{_version}
Z
zhuchunyi 已提交
5
Release:    %{_release}
O
overweight 已提交
6 7 8 9 10
Summary:    a tool for downloading iSulad images


Group:      Applications/System
License:    Mulan PSL v1
11
URL:        https://gitee.com/src-openeuler/iSulad-img
W
WangFengTu 已提交
12
Source0:    iSulad-img-2.0.tar.gz
O
overweight 已提交
13 14 15

BuildRequires:  golang >= 1.8.3
BuildRequires:  gpgme gpgme-devel
W
WangFengTu 已提交
16
BuildRequires:  device-mapper-devel
O
overweight 已提交
17 18 19 20 21 22 23

%description
A tool for downloading iSulad images, written in go language

%global debug_package %{nil}

%prep
24
%setup -q -b 0 -c -n iSulad-img-%{version}
O
overweight 已提交
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41

# apply the patchs
cp ./patch/* ./
cat series-patch.conf | while read line
do
        if [[ $line == '' || $line =~ ^\s*# ]]; then
                continue
        fi
        patch -p1 -F1 -s < $line
done
cd -

%build
make %{?_smp_mflags}

%install
install -d $RPM_BUILD_ROOT/%{_bindir}
42
install -m 0755 ./isulad-img %{buildroot}/%{_bindir}/isulad-img
O
overweight 已提交
43 44 45 46 47 48 49 50
install -d $RPM_BUILD_ROOT/%{_sysconfdir}/containers
install -m 0644 ./default-policy.json $RPM_BUILD_ROOT/%{_sysconfdir}/containers/policy.json

%clean
rm -rf %{buildroot}

%files
%defattr(-,root,root,-)
51
%{_bindir}/isulad-img
O
overweight 已提交
52 53 54
%{_sysconfdir}/*

%changelog