From 80b16b4732e8249dc65d03f759c69bc0fa814e43 Mon Sep 17 00:00:00 2001 From: Lokesh Mandvekar Date: Mon, 16 May 2022 16:36:52 -0400 Subject: [PATCH] bump to 1.5 Resolves: #2108456 - use latest criu Resolves: #2101691 - enable likbrun support in rawhide Signed-off-by: Lokesh Mandvekar --- .gitignore | 1 + crun.spec | 33 +++++++++++++++++++++++++++++---- sources | 2 +- 3 files changed, 31 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 16c2d23..90071cc 100644 --- a/.gitignore +++ b/.gitignore @@ -59,3 +59,4 @@ crun-0.1.1.tar.gz /crun-1.4.3.tar.xz /crun-1.4.4.tar.xz /crun-1.4.5.tar.xz +/crun-1.5.tar.xz diff --git a/crun.spec b/crun.spec index 9a9976a..a413b00 100644 --- a/crun.spec +++ b/crun.spec @@ -1,12 +1,20 @@ -%global built_tag 1.4.5 +%if 0%{?fedora} >= 37 +%ifarch aarch64,x86_64 +%global krun_support enabled +%endif +%else +%global krun_support disabled +%endif + +%global built_tag 1.5 Summary: OCI runtime written in C Name: crun -Version: 1.4.5 +Version: 1.5 URL: https://github.com/containers/%{name} Source0: %{url}/releases/download/%{version}/%{name}-%{version}.tar.xz %if "%{_vendor}" == "debbuild" -Maintainer: Lokesh Mandvekar +Packager: Lokesh Mandvekar License: GPL-2.0+ Release: 0%{?dist} %else @@ -31,6 +39,10 @@ BuildRequires: python3 BuildRequires: libcap-devel BuildRequires: systemd-devel BuildRequires: yajl-devel +%if "%{krun_support}" == "enabled" +BuildRequires: libkrun-devel +Provides: krun +%endif BuildRequires: libseccomp-devel BuildRequires: libselinux-devel BuildRequires: python3-libmount @@ -38,9 +50,10 @@ BuildRequires: make BuildRequires: glibc-static BuildRequires: protobuf-c-devel %ifnarch %ix86 -BuildRequires: criu-devel >= 3.15 +BuildRequires: criu-devel >= 3.17.1-2 %endif %endif +Requires: criu >= 3.17.1-2 Provides: oci-runtime %description @@ -51,7 +64,12 @@ Provides: oci-runtime %build ./autogen.sh + +%if "%{krun_support}" == "enabled" +%configure --disable-silent-rules --with-libkrun +%else %configure --disable-silent-rules +%endif %make_build @@ -59,9 +77,16 @@ Provides: oci-runtime %make_install rm -rf %{buildroot}%{_prefix}/lib* +%if "%{krun_support}" == "enabled" +ln -s %{_bindir}/%{name} %{buildroot}%{_bindir}/krun +%endif + %files %license COPYING %{_bindir}/%{name} +%if "%{krun_support}" == "enabled" +%{_bindir}/krun +%endif %{_mandir}/man1/* %changelog diff --git a/sources b/sources index afd9fb7..f94d63d 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (crun-1.4.5.tar.xz) = 9f288279615fdf587018c465047fc8793daae280ab864bf9046994983239129d50f2eb89cac9b092e5cdc49a10f3523ab403a3f0e7451f7536b79f651a355153 +SHA512 (crun-1.5.tar.xz) = 8ae5c6e306878194842f3a6a40bfc07038f69b9bd693395d64251133acf59186ce79272a45a3aee26b2a9812cbedb7a37370aece582abb3119ab7cdf7183e57b