From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from smtprelay01.ispgateway.de ([80.67.18.13]) by metis.ext.pengutronix.de with esmtp (Exim 4.72) (envelope-from ) id 1SGvdu-0005VE-H0 for ptxdist@pengutronix.de; Sun, 08 Apr 2012 19:11:31 +0200 Received: from [93.210.45.114] (helo=galilei.fritz.box) by smtprelay01.ispgateway.de with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.68) (envelope-from ) id 1SGvdu-0002BI-7R for ptxdist@pengutronix.de; Sun, 08 Apr 2012 19:11:10 +0200 From: Bernhard Walle Date: Sun, 8 Apr 2012 19:11:00 +0200 Message-Id: <1333905060-19627-3-git-send-email-bernhard@bwalle.de> In-Reply-To: <1333905060-19627-1-git-send-email-bernhard@bwalle.de> References: <1333905060-19627-1-git-send-email-bernhard@bwalle.de> Subject: [ptxdist] [PATCH 2/2] libcap: Fix build on non-Linux host Reply-To: ptxdist@pengutronix.de List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: ptxdist-bounces@pengutronix.de Errors-To: ptxdist-bounces@pengutronix.de To: ptxdist@pengutronix.de The patch has been already sent upstream (in a lightly different variant). For now, it works. Signed-off-by: Bernhard Walle --- .../0002-Fix-build-on-non-Linux-host.patch | 41 ++++++++++++++++++++ patches/libcap-2.21/series | 4 +- 2 files changed, 44 insertions(+), 1 deletion(-) create mode 100644 patches/libcap-2.21/0002-Fix-build-on-non-Linux-host.patch diff --git a/patches/libcap-2.21/0002-Fix-build-on-non-Linux-host.patch b/patches/libcap-2.21/0002-Fix-build-on-non-Linux-host.patch new file mode 100644 index 0000000..b226906 --- /dev/null +++ b/patches/libcap-2.21/0002-Fix-build-on-non-Linux-host.patch @@ -0,0 +1,41 @@ +From dd53fb42020b5a0612870924dd95e3a488ddf13d Mon Sep 17 00:00:00 2001 +From: Bernhard Walle +Date: Sun, 8 Apr 2012 17:55:56 +0200 +Subject: [PATCH] Fix build on non-Linux host + +Signed-off-by: Bernhard Walle +--- + libcap/include/linux/capability.h | 6 ++++++ + libcap/include/sys/capability.h | 1 - + 2 files changed, 6 insertions(+), 1 deletion(-) + +diff --git a/libcap/include/linux/capability.h b/libcap/include/linux/capability.h +index 4924f2a..6d2fdaf 100644 +--- a/libcap/include/linux/capability.h ++++ b/libcap/include/linux/capability.h +@@ -13,7 +13,13 @@ + #ifndef _LINUX_CAPABILITY_H + #define _LINUX_CAPABILITY_H + ++#ifdef __linux__ + #include ++#else ++#include ++typedef uint32_t __u32; ++typedef uint32_t __le32; ++#endif + + struct task_struct; + +diff --git a/libcap/include/sys/capability.h b/libcap/include/sys/capability.h +index 4b54acc..d6ef07f 100644 +--- a/libcap/include/sys/capability.h ++++ b/libcap/include/sys/capability.h +@@ -21,7 +21,6 @@ extern "C" { + + #include + #include +-#include + + /* + * Required to limit what gets defined in the kernel header file. diff --git a/patches/libcap-2.21/series b/patches/libcap-2.21/series index ab798c0..d16ef28 100644 --- a/patches/libcap-2.21/series +++ b/patches/libcap-2.21/series @@ -1,3 +1,5 @@ # generated by git-ptx-patches +#tag:base --start-number 1 0001-Make.Rules-don-t-overwrite-CFLAGS-and-LDFLAGS.patch -# 1d206f03899ee1c148cbf9652fc1aec3 - git-ptx-patches magic +0002-Fix-build-on-non-Linux-host.patch +# 187508e7e810aa0efb7a7ad4d7af2d9e - git-ptx-patches magic -- 1.7.9.5 -- ptxdist mailing list ptxdist@pengutronix.de