diff --git a/debian/control b/debian/control index 0b0a60f7..c289db1d 100644 --- a/debian/control +++ b/debian/control @@ -2,11 +2,22 @@ Source: containerd.io Section: devel Priority: optional Maintainer: Containerd team + +# libseccomp-golang commit 9814e55a2e59df39b8ad4fbff1226585ebb84674 started using +# a new seccomp_version API, which was introduced in libseccomp 2.3 (addded in +# https://github.com/seccomp/libseccomp/commit/58a7c20). As a result, if the binary +# is compiled with libseccomp 2.3 or up, the minimum requirement for libseccomp +# to run the binary will also be libseccomp 2.3.0 (running on a system with an +# older version of libseccomp, will produce "undefined symbol: seccomp_version") +# +# Here, we restrict the version of libseccomp-dev at compile time to 2.2.x, so +# that the new API isn't used, and that the binary is compatible with libseccomp +# 2.2.0 and up. Running on a system with Build-Depends: libbtrfs-dev | btrfs-tools , debhelper, dh-systemd, pkg-config, - libseccomp-dev + libseccomp-dev (<< 2.3.0) Standards-Version: 4.1.4 Homepage: https://containerd.io Vcs-Browser: https://github.com/containerd/containerd diff --git a/rpm/containerd.spec b/rpm/containerd.spec index 30f274d3..4cb30e50 100644 --- a/rpm/containerd.spec +++ b/rpm/containerd.spec @@ -62,7 +62,18 @@ Requires: container-selinux >= 2:2.74 BuildRequires: make BuildRequires: gcc BuildRequires: systemd -BuildRequires: libseccomp-devel + +# libseccomp-golang commit 9814e55a2e59df39b8ad4fbff1226585ebb84674 started using +# a new seccomp_version API, which was introduced in libseccomp 2.3 (addded in +# https://github.com/seccomp/libseccomp/commit/58a7c20). As a result, if the binary +# is compiled with libseccomp 2.3 or up, the minimum requirement for libseccomp +# to run the binary will also be libseccomp 2.3.0 (running on a system with an +# older version of libseccomp, will produce "undefined symbol: seccomp_version") +# +# Here, we restrict the version of libseccomp-dev at compile time to 2.2.x, so +# that the new API isn't used, and that the binary is compatible with libseccomp +# 2.2.0 and up. +BuildRequires: libseccomp-devel << 2.3.0 # Should only return true if `el8` (rhel8) is NOT defined %if 0%{!?el8:1}