2022-08-11 19:59:09 +00:00
|
|
|
%global krun_opts %{nil}
|
|
|
|
|
2022-05-16 20:36:52 +00:00
|
|
|
%if 0%{?fedora} >= 37
|
2022-08-11 19:59:09 +00:00
|
|
|
%ifarch aarch64 || x86_64
|
2022-05-16 20:36:52 +00:00
|
|
|
%global krun_support enabled
|
2022-08-11 19:59:09 +00:00
|
|
|
%global krun_opts --with-libkrun
|
2022-05-16 20:36:52 +00:00
|
|
|
%endif
|
|
|
|
%endif
|
|
|
|
|
2022-08-17 18:48:15 +00:00
|
|
|
%global built_tag_strip 1.5
|
2021-04-28 12:54:17 +00:00
|
|
|
|
2019-06-21 17:11:11 +00:00
|
|
|
Summary: OCI runtime written in C
|
|
|
|
Name: crun
|
2022-09-07 15:03:24 +00:00
|
|
|
Version: 1.6
|
2022-03-31 17:28:16 +00:00
|
|
|
URL: https://github.com/containers/%{name}
|
2022-03-03 14:53:05 +00:00
|
|
|
Source0: %{url}/releases/download/%{version}/%{name}-%{version}.tar.xz
|
2022-05-16 20:36:52 +00:00
|
|
|
%if "%{_vendor}" == "debbuild"
|
2022-08-16 18:05:28 +00:00
|
|
|
Packager: Podman Debbuild Maintainers <https://github.com/orgs/containers/teams/podman-debbuild-maintainers>
|
2022-05-16 20:36:52 +00:00
|
|
|
License: GPL-2.0+
|
|
|
|
Release: 0%{?dist}
|
|
|
|
%else
|
2021-04-16 16:15:40 +00:00
|
|
|
License: GPLv2+
|
2022-05-16 20:36:52 +00:00
|
|
|
Release: %autorelease
|
|
|
|
%endif
|
2019-06-21 17:11:11 +00:00
|
|
|
BuildRequires: autoconf
|
|
|
|
BuildRequires: automake
|
2022-05-16 20:36:52 +00:00
|
|
|
BuildRequires: go-md2man
|
|
|
|
BuildRequires: libtool
|
|
|
|
%if "%{_vendor}" == "debbuild"
|
|
|
|
BuildRequires: git
|
|
|
|
BuildRequires: libcap-dev
|
|
|
|
BuildRequires: libseccomp-dev
|
|
|
|
BuildRequires: libsystemd-dev
|
|
|
|
BuildRequires: libyajl-dev
|
|
|
|
BuildRequires: pkg-config
|
2022-08-16 18:05:28 +00:00
|
|
|
Requires: criu
|
2022-05-16 20:36:52 +00:00
|
|
|
%else
|
2019-06-21 17:11:11 +00:00
|
|
|
BuildRequires: gcc
|
2022-05-16 20:36:52 +00:00
|
|
|
BuildRequires: git-core
|
2022-03-10 18:22:48 +00:00
|
|
|
BuildRequires: python3
|
2021-04-06 07:56:23 +00:00
|
|
|
BuildRequires: libcap-devel
|
2019-06-21 17:11:11 +00:00
|
|
|
BuildRequires: systemd-devel
|
|
|
|
BuildRequires: yajl-devel
|
2022-05-16 20:36:52 +00:00
|
|
|
%if "%{krun_support}" == "enabled"
|
|
|
|
BuildRequires: libkrun-devel
|
|
|
|
Provides: krun
|
|
|
|
%endif
|
2019-06-21 17:11:11 +00:00
|
|
|
BuildRequires: libseccomp-devel
|
|
|
|
BuildRequires: libselinux-devel
|
|
|
|
BuildRequires: python3-libmount
|
2020-12-17 04:03:08 +00:00
|
|
|
BuildRequires: make
|
2021-02-19 07:55:38 +00:00
|
|
|
BuildRequires: glibc-static
|
2021-09-28 12:54:24 +00:00
|
|
|
BuildRequires: protobuf-c-devel
|
2020-12-17 13:57:56 +00:00
|
|
|
%ifnarch %ix86
|
2022-05-16 20:36:52 +00:00
|
|
|
BuildRequires: criu-devel >= 3.17.1-2
|
2020-12-17 13:57:56 +00:00
|
|
|
%endif
|
2022-07-25 18:52:59 +00:00
|
|
|
Requires: criu >= 3.17.1
|
2022-08-16 18:05:28 +00:00
|
|
|
%endif
|
2021-04-13 19:19:27 +00:00
|
|
|
Provides: oci-runtime
|
2019-06-21 17:01:30 +00:00
|
|
|
|
|
|
|
%description
|
2022-03-31 17:28:16 +00:00
|
|
|
%{name} is a runtime for running OCI containers
|
2019-06-21 17:01:30 +00:00
|
|
|
|
|
|
|
%prep
|
2022-08-17 18:48:15 +00:00
|
|
|
%autosetup -Sgit %{name}-%{built_tag_strip}
|
2019-06-21 17:01:30 +00:00
|
|
|
|
|
|
|
%build
|
2019-06-21 17:11:11 +00:00
|
|
|
./autogen.sh
|
2022-08-11 19:59:09 +00:00
|
|
|
%configure --disable-silent-rules %{krun_opts}
|
2019-06-21 17:11:11 +00:00
|
|
|
%make_build
|
2019-06-21 17:01:30 +00:00
|
|
|
|
2019-06-21 17:11:11 +00:00
|
|
|
%install
|
|
|
|
%make_install
|
2021-04-28 12:54:17 +00:00
|
|
|
rm -rf %{buildroot}%{_prefix}/lib*
|
2019-06-21 17:01:30 +00:00
|
|
|
|
2022-05-16 20:36:52 +00:00
|
|
|
%if "%{krun_support}" == "enabled"
|
|
|
|
ln -s %{_bindir}/%{name} %{buildroot}%{_bindir}/krun
|
|
|
|
%endif
|
|
|
|
|
2019-06-21 17:01:30 +00:00
|
|
|
%files
|
2019-06-21 17:11:11 +00:00
|
|
|
%license COPYING
|
|
|
|
%{_bindir}/%{name}
|
2022-05-16 20:36:52 +00:00
|
|
|
%if "%{krun_support}" == "enabled"
|
|
|
|
%{_bindir}/krun
|
|
|
|
%endif
|
2019-06-21 17:11:11 +00:00
|
|
|
%{_mandir}/man1/*
|
2019-06-21 17:01:30 +00:00
|
|
|
|
|
|
|
%changelog
|
2022-05-16 20:36:52 +00:00
|
|
|
%if "%{_vendor}" != "debbuild"
|
2022-01-27 17:59:35 +00:00
|
|
|
%autochangelog
|
2022-05-16 20:36:52 +00:00
|
|
|
%endif
|