github.com/meulengracht/snapd@v0.0.0-20210719210640-8bde69bcc84e/packaging/debian-sid/patches/0001-cmd-snap-seccomp-use-upstream-seccomp-package.patch (about)

     1  From b699fd17fa7ec5191901ea116369b1b963b58e14 Mon Sep 17 00:00:00 2001
     2  From: Zygmunt Krynicki <me@zygoon.pl>
     3  Date: Thu, 17 Jan 2019 15:48:46 +0200
     4  Subject: [PATCH 1/9] cmd/snap-seccomp: use upstream seccomp package
     5  
     6  Upstream snapd uses a fork that carries additional compatibility patch
     7  required to build snapd for Ubuntu 14.04. This patch is not required with
     8  the latest snapshot of the upstream seccomp golang bindings but they are
     9  neither released upstream nor backported (in their entirety) to Ubuntu
    10  14.04.
    11  
    12  The forked seccomp library is not packaged in Debian. As such, to build
    13  snapd, we need to switch to the regular, non-forked package name.
    14  
    15  Signed-off-by: Zygmunt Krynicki <me@zygoon.pl>
    16  Signed-off-by: Maciej Borzecki <maciej.zenon.borzecki@canonical.com>
    17  ---
    18   cmd/snap-seccomp/main.go             | 3 +--
    19   cmd/snap-seccomp/main_test.go        | 2 +-
    20   cmd/snap-seccomp/versioninfo.go      | 2 +-
    21   cmd/snap-seccomp/versioninfo_test.go | 2 +-
    22   4 files changed, 4 insertions(+), 5 deletions(-)
    23  
    24  diff --git a/cmd/snap-seccomp/main.go b/cmd/snap-seccomp/main.go
    25  index 1f56f5876f62637cd99e3adab177d15fa8a941af..f7b5b8b62b5c511f3710a6bdd23367c0641144ae 100644
    26  --- a/cmd/snap-seccomp/main.go
    27  +++ b/cmd/snap-seccomp/main.go
    28  @@ -180,8 +180,7 @@ import (
    29   	"strings"
    30   	"syscall"
    31   
    32  -	// FIXME: we want github.com/seccomp/libseccomp-golang but that will not work with trusty because libseccomp-golang checks for the seccomp version and errors if it find one < 2.2.0
    33  -	"github.com/mvo5/libseccomp-golang"
    34  +	"github.com/seccomp/libseccomp-golang"
    35   
    36   	"github.com/snapcore/snapd/arch"
    37   	"github.com/snapcore/snapd/osutil"
    38  diff --git a/cmd/snap-seccomp/main_test.go b/cmd/snap-seccomp/main_test.go
    39  index 90590e5d89901e7298fbfe37c818ff6d6d2c7874..6933649ea743d9422321f772967c8dfe2054c432 100644
    40  --- a/cmd/snap-seccomp/main_test.go
    41  +++ b/cmd/snap-seccomp/main_test.go
    42  @@ -30,7 +30,7 @@ import (
    43   	"strings"
    44   	"testing"
    45   
    46  -	"github.com/mvo5/libseccomp-golang"
    47  +	"github.com/seccomp/libseccomp-golang"
    48   	. "gopkg.in/check.v1"
    49   
    50   	"github.com/snapcore/snapd/arch"
    51  diff --git a/cmd/snap-seccomp/versioninfo.go b/cmd/snap-seccomp/versioninfo.go
    52  index b206d9b8c732d8b116e700f0e343ad4377fb19d2..2ddba5fd0becfbbc1eae1ac92b3711a8e4c69704 100644
    53  --- a/cmd/snap-seccomp/versioninfo.go
    54  +++ b/cmd/snap-seccomp/versioninfo.go
    55  @@ -25,7 +25,7 @@ import (
    56   	"os"
    57   	"strings"
    58   
    59  -	"github.com/mvo5/libseccomp-golang"
    60  +	"github.com/seccomp/libseccomp-golang"
    61   
    62   	"github.com/snapcore/snapd/cmd/snap-seccomp/syscalls"
    63   	"github.com/snapcore/snapd/osutil"
    64  diff --git a/cmd/snap-seccomp/versioninfo_test.go b/cmd/snap-seccomp/versioninfo_test.go
    65  index fadfaf10ca4aa2a631f7d8b0a342fde2b2436412..ea20c306c5031bbd6eab912a35070436fc52e74d 100644
    66  --- a/cmd/snap-seccomp/versioninfo_test.go
    67  +++ b/cmd/snap-seccomp/versioninfo_test.go
    68  @@ -23,7 +23,7 @@ import (
    69   	"fmt"
    70   	"strings"
    71   
    72  -	"github.com/mvo5/libseccomp-golang"
    73  +	"github.com/seccomp/libseccomp-golang"
    74   	. "gopkg.in/check.v1"
    75   
    76   	main "github.com/snapcore/snapd/cmd/snap-seccomp"
    77  -- 
    78  2.32.0
    79