summaryrefslogtreecommitdiffstats
path: root/meta/recipes-support/libcap-ng
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-support/libcap-ng')
-rw-r--r--meta/recipes-support/libcap-ng/files/0001-Fix-python-path-when-invoking-py-compile-54.patch34
-rw-r--r--meta/recipes-support/libcap-ng/files/fix-issues-with-swig-4-2.patch32
-rw-r--r--meta/recipes-support/libcap-ng/libcap-ng-python_0.8.4.bb29
-rw-r--r--meta/recipes-support/libcap-ng/libcap-ng-python_0.8.5.bb17
-rw-r--r--meta/recipes-support/libcap-ng/libcap-ng.inc14
-rw-r--r--meta/recipes-support/libcap-ng/libcap-ng_0.8.5.bb (renamed from meta/recipes-support/libcap-ng/libcap-ng_0.8.4.bb)2
6 files changed, 61 insertions, 67 deletions
diff --git a/meta/recipes-support/libcap-ng/files/0001-Fix-python-path-when-invoking-py-compile-54.patch b/meta/recipes-support/libcap-ng/files/0001-Fix-python-path-when-invoking-py-compile-54.patch
new file mode 100644
index 0000000000..a0452ad53d
--- /dev/null
+++ b/meta/recipes-support/libcap-ng/files/0001-Fix-python-path-when-invoking-py-compile-54.patch
@@ -0,0 +1,34 @@
+From 1fe7c1cfeea00ba4eb903fbb39b74361594d4835 Mon Sep 17 00:00:00 2001
+From: Jan Palus <jpalus@fastmail.com>
+Date: Wed, 10 Apr 2024 21:30:51 +0200
+Subject: [PATCH] Fix python path when invoking py-compile (#54)
+
+48eebb2 replaced custom PYTHON3 variable with PYTHON by using standard
+AM_PATH_PYTHON macro. Makefile however still referred to old one.
+There's no need to set PYTHON explicitly anymore so drop it.
+
+Fixes #53
+
+Upstream-Status: Backport
+[https://github.com/stevegrubb/libcap-ng/commit/1fe7c1cfeea00ba4eb903fbb39b74361594d4835]
+
+Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
+---
+ bindings/python3/Makefile.am | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/bindings/python3/Makefile.am b/bindings/python3/Makefile.am
+index 70a1dd8..6072fc2 100644
+--- a/bindings/python3/Makefile.am
++++ b/bindings/python3/Makefile.am
+@@ -27,7 +27,6 @@ AM_CPPFLAGS = -I. -I$(top_builddir) $(PYTHON3_INCLUDES)
+ LIBS = ${top_builddir}/src/libcap-ng.la
+ SWIG_FLAGS = -python
+ SWIG_INCLUDES = ${AM_CPPFLAGS}
+-PYTHON = $(PYTHON3)
+ pyexec_PYTHON = capng.py
+ pyexec_LTLIBRARIES = _capng.la
+ pyexec_SOLIBRARIES = _capng.so
+--
+2.25.1
+
diff --git a/meta/recipes-support/libcap-ng/files/fix-issues-with-swig-4-2.patch b/meta/recipes-support/libcap-ng/files/fix-issues-with-swig-4-2.patch
deleted file mode 100644
index fb424fe725..0000000000
--- a/meta/recipes-support/libcap-ng/files/fix-issues-with-swig-4-2.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 355eada2d20886287cffc16e304087dd6f66ae37 Mon Sep 17 00:00:00 2001
-From: Steve Grubb <ausearch.1@gmail.com>
-Date: Thu, 4 Jan 2024 15:06:29 -0500
-Subject: [PATCH] Remove python global exception handler since its deprecated
-
-Upstream-Status: Backport [https://github.com/stevegrubb/libcap-ng/commit/30453b6553948cd05c438f9f509013e3bb84f25b]
-Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
----
- bindings/src/capng_swig.i | 7 -------
- 1 file changed, 7 deletions(-)
-
-diff --git a/bindings/src/capng_swig.i b/bindings/src/capng_swig.i
-index fcdaf18..fa85e13 100644
---- a/bindings/src/capng_swig.i
-+++ b/bindings/src/capng_swig.i
-@@ -30,13 +30,6 @@
-
- %varargs(16, signed capability = 0) capng_updatev;
-
--%except(python) {
-- $action
-- if (result < 0) {
-- PyErr_SetFromErrno(PyExc_OSError);
-- return NULL;
-- }
--}
- #endif
-
- %define __signed__
---
-2.43.2
-
diff --git a/meta/recipes-support/libcap-ng/libcap-ng-python_0.8.4.bb b/meta/recipes-support/libcap-ng/libcap-ng-python_0.8.4.bb
deleted file mode 100644
index 4790134ae9..0000000000
--- a/meta/recipes-support/libcap-ng/libcap-ng-python_0.8.4.bb
+++ /dev/null
@@ -1,29 +0,0 @@
-require libcap-ng.inc
-
-FILESEXTRAPATHS:prepend := "${THISDIR}/libcap-ng:"
-
-SUMMARY .= " - python"
-
-inherit lib_package autotools python3targetconfig
-
-# drop setuptools when version > 0.8.3 is released; it's needed only for distutils
-DEPENDS += "libcap-ng python3 swig-native python3-setuptools-native"
-
-S = "${WORKDIR}/libcap-ng-${PV}"
-
-EXTRA_OECONF += "--with-python3"
-
-do_install:append() {
- rm -rf ${D}${bindir}
- rm -rf ${D}${libdir}/.debug
- rm -f ${D}${libdir}/lib*
- rm -rf ${D}${libdir}/pkgconfig
- rm -rf ${D}${datadir}
- rm -rf ${D}${includedir}
-}
-
-# PACKAGES = "${PN}"
-
-FILES:${PN} = "${libdir}/python${PYTHON_BASEVERSION}"
-FILES:${PN}-dbg =+ "${PYTHON_SITEPACKAGES_DIR}/.debug/_capng.so"
-
diff --git a/meta/recipes-support/libcap-ng/libcap-ng-python_0.8.5.bb b/meta/recipes-support/libcap-ng/libcap-ng-python_0.8.5.bb
new file mode 100644
index 0000000000..f702056f02
--- /dev/null
+++ b/meta/recipes-support/libcap-ng/libcap-ng-python_0.8.5.bb
@@ -0,0 +1,17 @@
+require libcap-ng.inc
+
+FILESEXTRAPATHS:prepend := "${THISDIR}/libcap-ng:"
+
+SUMMARY .= " - python"
+
+inherit python3targetconfig
+
+DEPENDS += "libcap-ng python3 swig-native"
+
+EXTRA_OECONF += "--with-python3"
+
+do_install() {
+ oe_runmake 'DESTDIR=${D}' install -C ${B}/bindings/python3
+}
+
+FILES:${PN} = "${libdir}/python${PYTHON_BASEVERSION}"
diff --git a/meta/recipes-support/libcap-ng/libcap-ng.inc b/meta/recipes-support/libcap-ng/libcap-ng.inc
index 845b7c2f0a..4c8ffd41c2 100644
--- a/meta/recipes-support/libcap-ng/libcap-ng.inc
+++ b/meta/recipes-support/libcap-ng/libcap-ng.inc
@@ -1,17 +1,23 @@
SUMMARY = "An alternate posix capabilities library"
DESCRIPTION = "The libcap-ng library is intended to make programming \
with POSIX capabilities much easier than the traditional libcap library."
-HOMEPAGE = "http://freecode.com/projects/libcap-ng"
+HOMEPAGE = "https://github.com/stevegrubb/libcap-ng"
SECTION = "base"
LICENSE = "GPL-2.0-or-later & LGPL-2.1-or-later"
LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
file://COPYING.LIB;md5=e3eda01d9815f8d24aae2dbd89b68b06"
-SRC_URI = "https://people.redhat.com/sgrubb/libcap-ng/libcap-ng-${PV}.tar.gz \
- file://fix-issues-with-swig-4-2.patch \
+SRC_URI = "git://github.com/stevegrubb/libcap-ng.git;protocol=https;branch=master \
+ file://0001-Fix-python-path-when-invoking-py-compile-54.patch \
"
+SRCREV = "f5d39702622208b3ada064d7b2eaeaf1454c9bd3"
+S = "${WORKDIR}/git"
-SRC_URI[sha256sum] = "68581d3b38e7553cb6f6ddf7813b1fc99e52856f21421f7b477ce5abd2605a8a"
+inherit lib_package autotools
+
+do_configure:prepend() {
+ touch ${S}/NEWS
+}
EXTRA_OECONF:append:class-target = " --with-capability_header=${STAGING_INCDIR}/linux/capability.h"
EXTRA_OECONF:append:class-nativesdk = " --with-capability_header=${STAGING_INCDIR}/linux/capability.h"
diff --git a/meta/recipes-support/libcap-ng/libcap-ng_0.8.4.bb b/meta/recipes-support/libcap-ng/libcap-ng_0.8.5.bb
index 3dbe3e2ffd..b482368a41 100644
--- a/meta/recipes-support/libcap-ng/libcap-ng_0.8.4.bb
+++ b/meta/recipes-support/libcap-ng/libcap-ng_0.8.5.bb
@@ -1,7 +1,5 @@
require libcap-ng.inc
-inherit lib_package autotools
-
EXTRA_OECONF += "--without-python3"
BBCLASSEXTEND = "native nativesdk"