Fix for EL6 build failure.

epel9
Thomas Moschny 8 years ago
parent 7a57abc43f
commit ec14f382cc

@ -0,0 +1,33 @@
diff -up lxc-2.0.8/src/lxc/caps.h.orig lxc-2.0.8/src/lxc/caps.h
--- lxc-2.0.8/src/lxc/caps.h.orig 2017-05-11 17:23:06.000000000 +0000
+++ lxc-2.0.8/src/lxc/caps.h 2017-06-10 07:04:48.702079368 +0000
@@ -28,6 +28,7 @@
#define __LXC_CAPS_H
#if HAVE_LIBCAP
+#include <linux/types.h>
#include <sys/capability.h>
extern int lxc_caps_down(void);
diff -up lxc-2.0.8/src/lxc/conf.c.orig lxc-2.0.8/src/lxc/conf.c
--- lxc-2.0.8/src/lxc/conf.c.orig 2017-05-11 17:23:06.000000000 +0000
+++ lxc-2.0.8/src/lxc/conf.c 2017-06-10 07:08:18.448806856 +0000
@@ -90,6 +90,7 @@
#include "lsm/lsm.h"
#if HAVE_LIBCAP
+#include <linux/types.h>
#include <sys/capability.h>
#endif
diff -up lxc-2.0.8/src/lxc/start.c.orig lxc-2.0.8/src/lxc/start.c
--- lxc-2.0.8/src/lxc/start.c.orig 2017-05-11 17:23:06.000000000 +0000
+++ lxc-2.0.8/src/lxc/start.c 2017-06-10 07:05:33.166293224 +0000
@@ -47,6 +47,7 @@
#include <sys/wait.h>
#if HAVE_LIBCAP
+#include <linux/types.h>
#include <sys/capability.h>
#endif

@ -31,7 +31,7 @@
Name: lxc Name: lxc
Version: 2.0.8 Version: 2.0.8
Release: %{?prerel:0.}1%{?prerel:.%{prerel}}%{?dist} Release: %{?prerel:0.}2%{?prerel:.%{prerel}}%{?dist}
Summary: Linux Resource Containers Summary: Linux Resource Containers
Group: Applications/System Group: Applications/System
License: LGPLv2+ and GPLv2 License: LGPLv2+ and GPLv2
@ -43,6 +43,7 @@ Source0: http://linuxcontainers.org/downloads/%{name}-%{version}.tar.gz
%endif %endif
Patch0: lxc-2.0.7-fix-init.patch Patch0: lxc-2.0.7-fix-init.patch
Patch1: lxc-2.0.6-fix-lxc-net.patch Patch1: lxc-2.0.6-fix-lxc-net.patch
Patch2: lxc-2.0.8-fix_capability_h.patch
BuildRequires: docbook2X BuildRequires: docbook2X
BuildRequires: doxygen BuildRequires: doxygen
BuildRequires: kernel-headers BuildRequires: kernel-headers
@ -177,6 +178,11 @@ This package contains documentation for %{name}.
%setup -q -n %{name}-%{?!prerel:%{version}}%{?prerel:%{commit}} %setup -q -n %{name}-%{?!prerel:%{version}}%{?prerel:%{commit}}
%patch0 -p1 %patch0 -p1
%patch1 -p1 %patch1 -p1
%if 0%{?rhel} == 6
# fix build failure with broken sys/capabilities.h (see
# e.g. rhbz#483548)
%patch2 -p1
%endif
%build %build
@ -376,6 +382,9 @@ fi
%changelog %changelog
* Sat Jun 10 2017 Thomas Moschny <thomas.moschny@gmx.de> - 2.0.8-2
- Fix for EL6 build failure.
* Tue Jun 6 2017 Thomas Moschny <thomas.moschny@gmx.de> - 2.0.8-1 * Tue Jun 6 2017 Thomas Moschny <thomas.moschny@gmx.de> - 2.0.8-1
- Update to 2.0.8. - Update to 2.0.8.

Loading…
Cancel
Save