From d5778cf595f48530f816cc5e8903c311705588a2 Mon Sep 17 00:00:00 2001 From: Alexander Livenets Date: Fri, 10 Apr 2020 01:07:02 +0200 Subject: [PATCH] deps/softwarecontainer-dependencies.sh: Fix lxc and python3-lxc installation Remove unneeded LXC packages Install python3-lxc from source Signed-off-by: Alexander Livenets --- deps/pytest-and-dbus-testing-dependencies.sh | 2 +- deps/softwarecontainer-dependencies.sh | 17 ++++++++++++++--- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/deps/pytest-and-dbus-testing-dependencies.sh b/deps/pytest-and-dbus-testing-dependencies.sh index 596e560..f67be34 100755 --- a/deps/pytest-and-dbus-testing-dependencies.sh +++ b/deps/pytest-and-dbus-testing-dependencies.sh @@ -46,7 +46,7 @@ function install { } # Install both python2 and python3 versions -install python3-dbus python3-pip python3-lxc +install python3-dbus python3-pip install python-gobject python-dbus python-pip pip install pydbus diff --git a/deps/softwarecontainer-dependencies.sh b/deps/softwarecontainer-dependencies.sh index e2ba8c9..6387792 100755 --- a/deps/softwarecontainer-dependencies.sh +++ b/deps/softwarecontainer-dependencies.sh @@ -44,9 +44,11 @@ function install { # For softwarecontainer install libdbus-1-dev libglibmm-2.4-dev libglibmm-2.4 \ unzip bridge-utils lcov libjansson-dev libjansson4 \ - dbus-x11 libcap-dev libtool python3-dev + dbus-x11 libcap-dev libtool python3-dev \ + seccomp libseccomp-dev -apt-get remove --allow-downgrades --allow-remove-essential --allow-change-held-packages -fuy lxcfs lxc2 lxc-dev lxc-common +apt-get remove --allow-downgrades --allow-remove-essential --allow-change-held-packages -fuy lxcfs lxc2 lxc-dev lxc-common \ + liblxc-common liblxc-dev lxc1 liblxc1 lxc-templates lxc-tests lxc-utils python3-lxc # Download and install lxc rm -rf lxc @@ -54,6 +56,15 @@ git clone git://github.com/lxc/lxc -b lxc-3.1.0 cd lxc ./autogen.sh -./configure --prefix=/usr --enable-capabilities --enable-python +./configure --prefix=/usr --enable-capabilities --enable-python --enable-apparmor --enable-seccomp make && make install + +cd ../ + +# Download and install python3-lxc +rm -rf python3-lxc +git clone git://github.com/lxc/python3-lxc -b python3-lxc-3.0.4 +cd python3-lxc + +python3 ./setup.py install