@@ -489,6 +489,7 @@ source "package/libical/Config.in"
source "package/libnspr/Config.in"
source "package/libsigc/Config.in"
source "package/libtpl/Config.in"
+source "package/libseccomp/Config.in"
source "package/liburcu/Config.in"
source "package/linux-pam/Config.in"
source "package/lttng-libust/Config.in"
new file mode 100644
@@ -0,0 +1,13 @@
+config BR2_PACKAGE_LIBSECCOMP
+ bool "libseccomp"
+ help
+ High level interface to the Linux Kernel's seccomp filter
+
+ The libseccomp library provides and easy to use, platform independent,
+ interface to the Linux Kernel's syscall filtering mechanism: seccomp.
+ The libseccomp API is designed to abstract away the underlying BPF
+ based syscall filter language and present a more conventional
+ function-call based filtering interface that should be familiar to,
+ and easily adopted by application developers.
+
+ http://sourceforge.net/projects/libseccomp/
new file mode 100644
@@ -0,0 +1,19 @@
+diff -du libseccomp-1.0.0.orig/configure libseccomp-1.0.0/configure
+--- libseccomp-1.0.0.orig/configure 2012-07-27 22:35:05.000000000 +0200
++++ libseccomp-1.0.0/configure 2012-09-07 00:00:09.918429292 +0200
+@@ -205,7 +205,8 @@
+ #
+
+ # system seccomp includes
+-if [[ -r "/usr/include/linux/seccomp.h" ]]; then
++# ${SYSROOT} added by buildroot for cross-compilation
++if [[ -r "${SYSROOT}/usr/include/linux/seccomp.h" ]]; then
+ opt_sysinc_seccomp="yes"
+ else
+ opt_sysinc_seccomp="no"
+Common subdirectories: libseccomp-1.0.0.orig/doc and libseccomp-1.0.0/doc
+Common subdirectories: libseccomp-1.0.0.orig/include and libseccomp-1.0.0/include
+Common subdirectories: libseccomp-1.0.0.orig/install and libseccomp-1.0.0/install
+Common subdirectories: libseccomp-1.0.0.orig/src and libseccomp-1.0.0/src
+Common subdirectories: libseccomp-1.0.0.orig/tests and libseccomp-1.0.0/tests
+Common subdirectories: libseccomp-1.0.0.orig/tools and libseccomp-1.0.0/tools
new file mode 100644
@@ -0,0 +1,22 @@
+#############################################################
+#
+# libseccomp
+#
+#############################################################
+
+LIBSECCOMP_VERSION = 1.0.0
+LIBSECCOMP_SOURCE = libseccomp-$(LIBSECCOMP_VERSION).tar.gz
+LIBSECCOMP_SITE = http://downloads.sourceforge.net/project/libseccomp
+LIBSECCOMP_LICENSE = LGPLv2.1
+LIBSECCOMP_LICENSE_FILES = LICENSE
+LIBSECCOMP_INSTALL_STAGING = YES
+
+# Needed for configure to find our system headers:
+LIBSECCOMP_CONF_ENV = SYSROOT=$(STAGING_DIR)
+LIBSECCOMP_MAKE_ENV = $(TARGET_CONFIGURE_OPTS)
+LIBSECCOMP_MAKE_OPT = SUBDIRS_BUILD=src
+LIBSECCOMP_INSTALL_STAGING_OPT = SUBDIRS_BUILD=src SUBDIRS_INSTALL="src include" DESTDIR=$(STAGING_DIR) install
+LIBSECCOMP_INSTALL_TARGET_OPT = SUBDIRS_BUILD=src SUBDIRS_INSTALL="src include" DESTDIR=$(TARGET_DIR) install
+
+# Not a real autotools package, but works quite OK nonetheless
+$(eval $(autotools-package))
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> --- package/Config.in | 1 + package/libseccomp/Config.in | 13 +++++++++++ ...ibseccomp-use-system-headers-from-sysroot.patch | 19 +++++++++++++++++ package/libseccomp/libseccomp.mk | 22 ++++++++++++++++++++ 4 files changed, 55 insertions(+), 0 deletions(-) create mode 100644 package/libseccomp/Config.in create mode 100644 package/libseccomp/libseccomp-use-system-headers-from-sysroot.patch create mode 100644 package/libseccomp/libseccomp.mk