mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-10-21 20:08:54 +00:00
Installation path was not the expected in SUSE. Signed-off-by: Jose Carlos Venegas Munoz <jose.carlos.venegas.munoz@intel.com>
79 lines
1.8 KiB
Plaintext
79 lines
1.8 KiB
Plaintext
%global DOMAIN github.com
|
|
%global ORG kata-containers
|
|
%global PROJECT shim
|
|
%global IMPORTNAME %{DOMAIN}/%{ORG}/%{PROJECT}
|
|
%global GO_VERSION @GO_VERSION@
|
|
|
|
%define LIBEXECDIR /usr/libexec
|
|
|
|
%undefine _missing_build_ids_terminate_build
|
|
Name: kata-shim
|
|
Version: @VERSION@+git.@HASH@
|
|
Release: @RELEASE@.<B_CNT>
|
|
Summary : No detailed summary available
|
|
Group : Development/Tools
|
|
License : Apache-2.0
|
|
Source0: %{name}-%{version}.tar.gz
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
BuildRequires: git
|
|
Requires: kata-shim-bin
|
|
|
|
%global debug_package %{nil}
|
|
|
|
# Patches
|
|
@RPM_PATCH_LIST@
|
|
|
|
%description
|
|
.. contents::
|
|
.. sectnum::
|
|
``kata-shim``
|
|
===================
|
|
Overview
|
|
--------
|
|
|
|
%package bin
|
|
Summary: bin components for the kata-shim package.
|
|
Group: Binaries
|
|
|
|
%description bin
|
|
bin components for the kata-shim package.
|
|
|
|
%prep
|
|
mkdir local
|
|
tar -C local -xzf ../SOURCES/go%{GO_VERSION}.linux-@GO_ARCH@.tar.gz
|
|
|
|
%setup -q
|
|
# Patches
|
|
@RPM_APPLY_PATCHES@
|
|
|
|
%build
|
|
export GOROOT=$HOME/rpmbuild/BUILD/local/go
|
|
export PATH=$PATH:$HOME/rpmbuild/BUILD/local/go/bin
|
|
export GOPATH=$HOME/rpmbuild/BUILD/go/
|
|
|
|
mkdir -p $HOME/rpmbuild/BUILD/go/src/%{DOMAIN}/%{ORG}
|
|
ln -s %{_builddir}/%{name}-%{version} $HOME/rpmbuild/BUILD/go/src/%{IMPORTNAME}
|
|
cd $HOME/rpmbuild/BUILD/go/src/%{IMPORTNAME}
|
|
make COMMIT=@HASH@
|
|
|
|
%check
|
|
export http_proxy=http://127.0.0.1:9/
|
|
export https_proxy=http://127.0.0.1:9/
|
|
export no_proxy=localhost
|
|
|
|
%install
|
|
export GOROOT=$HOME/rpmbuild/BUILD/local/go
|
|
export PATH=$PATH:$HOME/rpmbuild/BUILD/local/go/bin
|
|
export GOPATH=$HOME/rpmbuild/BUILD/go/
|
|
|
|
make install LIBEXECDIR=%{buildroot}%{LIBEXECDIR} COMMIT=@HASH@
|
|
|
|
%files
|
|
%defattr(-,root,root,-)
|
|
|
|
%files bin
|
|
%defattr(-,root,root,-)
|
|
%dir %{LIBEXECDIR}
|
|
%dir %{LIBEXECDIR}/kata-containers
|
|
%{LIBEXECDIR}/kata-containers/kata-shim
|