summaryrefslogtreecommitdiffstats
path: root/meta/recipes-support/libnl
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-support/libnl')
-rw-r--r--meta/recipes-support/libnl/files/enable-serial-tests.patch29
-rw-r--r--meta/recipes-support/libnl/files/fa7f97f8982544c4fcb403893bae6701230d5165.patch48
-rwxr-xr-xmeta/recipes-support/libnl/files/run-ptest17
-rw-r--r--meta/recipes-support/libnl/libnl_3.9.0.bb (renamed from meta/recipes-support/libnl/libnl_3.6.0.bb)34
4 files changed, 12 insertions, 116 deletions
diff --git a/meta/recipes-support/libnl/files/enable-serial-tests.patch b/meta/recipes-support/libnl/files/enable-serial-tests.patch
deleted file mode 100644
index db774ad8217..00000000000
--- a/meta/recipes-support/libnl/files/enable-serial-tests.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From b1476d89bf7a0bc6062438731ee4e9026696328b Mon Sep 17 00:00:00 2001
-From: Eric Xu <chi.xu@windriver.com>
-Date: Fri, 9 Mar 2018 03:38:49 +0000
-Subject: [PATCH] Add ptest for libnl
-
-serial-tests is required to generate those targets.
-
-Upstream-Status: Inappropriate [oe-specific]
-Signed-off-by: Eric Xu <chi.xu@windriver.com>
----
- configure.ac | 2 +-
- 1 files changed, 1 insertion(+), 1 deletions(-)
-
-diff --git a/configure.ac b/configure.ac
-index dfead98..2cc8257 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -46,7 +46,7 @@ AC_INIT(libnl, [libnl_version], [], [], [http://www.infradead.org/~tgr/libnl/])
- AC_CONFIG_HEADERS([lib/defs.h])
- AC_CONFIG_AUX_DIR([build-aux])
- AC_CONFIG_MACRO_DIR([m4])
--AM_INIT_AUTOMAKE([-Wall foreign subdir-objects])
-+AM_INIT_AUTOMAKE([-Wall foreign subdir-objects serial-tests])
- m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES(yes)], [])
- m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
-
---
-2.13.3
-
diff --git a/meta/recipes-support/libnl/files/fa7f97f8982544c4fcb403893bae6701230d5165.patch b/meta/recipes-support/libnl/files/fa7f97f8982544c4fcb403893bae6701230d5165.patch
deleted file mode 100644
index 02662c939eb..00000000000
--- a/meta/recipes-support/libnl/files/fa7f97f8982544c4fcb403893bae6701230d5165.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From fa7f97f8982544c4fcb403893bae6701230d5165 Mon Sep 17 00:00:00 2001
-From: Thomas Haller <thaller@redhat.com>
-Date: Fri, 15 Apr 2022 13:29:49 +0200
-Subject: [PATCH] build: avoid building check-direct with --disable-static
-
-"check-direct" needs to statically link with the libraries, because
-it wants to test internal ABI, which is hidden in the share libraries.
-When configuring with "--disable-static", static libs are not build
-and the test tool cannot be build.
-
-Just skip the test in that case.
-
-https://github.com/thom311/libnl/issues/306
-Upstream-Status: Backport [https://github.com/thom311/libnl/commit/fa7f97f8982544c4fcb403893bae6701230d5165]
-Signed-off-by: Alexander Kanavin <alex@linutronix.de>
----
- Makefile.am | 2 ++
- configure.ac | 2 ++
- 2 files changed, 4 insertions(+)
-
-diff --git a/Makefile.am b/Makefile.am
-index a6bcf553..2f5e0dfc 100644
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -984,8 +984,10 @@ tests_check_all_LDADD = \
- $(NULL)
-
- if WITH_CHECK
-+if ENABLE_STATIC
- check_programs += tests/check-direct
- endif
-+endif
-
- tests_check_direct_SOURCES = \
- tests/check-direct.c \
-diff --git a/configure.ac b/configure.ac
-index 1f9ad0eb..0fd1cc0f 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -107,6 +107,8 @@ else
- AC_CHECK_LIB([pthread], [pthread_mutex_lock], [], AC_MSG_ERROR([libpthread is required]))
- fi
-
-+AM_CONDITIONAL([ENABLE_STATIC], [test "$enable_static" != "no"])
-+
- AC_ARG_ENABLE([debug],
- AS_HELP_STRING([--disable-debug], [Do not include debugging statements]),
- [enable_debug="$enableval"], [enable_debug="yes"])
diff --git a/meta/recipes-support/libnl/files/run-ptest b/meta/recipes-support/libnl/files/run-ptest
index e5c9eb0a328..0d0c665cd22 100755
--- a/meta/recipes-support/libnl/files/run-ptest
+++ b/meta/recipes-support/libnl/files/run-ptest
@@ -1,16 +1,3 @@
-#!/bin/sh
+#! /bin/sh
-num_fail=0
-
-for test in check*
-do
- ./"$test" \
- && echo "PASS: $test" \
- || {
- echo "FAIL: $test"
- num_fail=$(( ${num_fail} + 1))
- }
-
-done
-
-exit $num_fail
+CK_AUTOMAKE=1 ./check-all
diff --git a/meta/recipes-support/libnl/libnl_3.6.0.bb b/meta/recipes-support/libnl/libnl_3.9.0.bb
index af3aa410401..db9d93e8cb3 100644
--- a/meta/recipes-support/libnl/libnl_3.6.0.bb
+++ b/meta/recipes-support/libnl/libnl_3.9.0.bb
@@ -14,19 +14,16 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
DEPENDS = "flex-native bison-native"
-SRC_URI = " \
- https://github.com/thom311/${BPN}/releases/download/${BPN}${@d.getVar('PV').replace('.','_')}/${BP}.tar.gz \
- file://enable-serial-tests.patch \
+SRC_URI = "${GITHUB_BASE_URI}/download/${BPN}${@d.getVar('PV').replace('.','_')}/${BP}.tar.gz \
file://run-ptest \
- file://fa7f97f8982544c4fcb403893bae6701230d5165.patch \
- "
+ "
-SRC_URI[sha256sum] = "532155fd011e5a805bd67121b87a01c757e2bb24112ac17e69cb86013b970009"
+SRC_URI[sha256sum] = "aed507004d728a5cf11eab48ca4bf9e6e1874444e33939b9d3dfed25018ee9bb"
+GITHUB_BASE_URI = "https://github.com/thom311/${BPN}/releases"
+UPSTREAM_CHECK_REGEX = "releases/tag/libnl(?P<pver>.+)"
-UPSTREAM_CHECK_URI = "https://github.com/thom311/${BPN}/releases"
-
-inherit autotools pkgconfig ptest
+inherit autotools pkgconfig ptest github-releases
FILES:${PN} = "${libdir}/libnl-3.so.* \
${libdir}/libnl.so.* \
@@ -53,26 +50,15 @@ FILES:${PN}-xfrm = "${libdir}/libnl-xfrm-3.so.*"
RREPLACES:${PN}-genl = "libnl-genl2"
RCONFLICTS:${PN}-genl = "libnl-genl2"
-RDEPENDS:${PN}-ptest += "libcheck"
-RRECOMMENDS:${PN}-ptest += "kernel-module-dummy kernel-module-bonding"
DEPENDS += "${@bb.utils.contains('PTEST_ENABLED', '1', 'libcheck', '', d)}"
-
-# make sure the tests don't link against wrong so file
-EXTRA_OECONF += "${@bb.utils.contains('PTEST_ENABLED', '1', '--disable-rpath', '', d)}"
+RRECOMMENDS:${PN}-ptest += "kernel-module-dummy kernel-module-bonding"
do_compile_ptest() {
- # hack to remove the call to `make runtest-TESTS`
- sed -i 's/$(MAKE) $(AM_MAKEFLAGS) runtest-TESTS//g' Makefile
- oe_runmake check
+ oe_runmake ./tests/check-all
}
-do_install_ptest(){
- # legacy? tests are also installed, but ptest-runner will not run them
- # upstream are not running these tests in their CI pipeline
- # issue opened https://github.com/thom311/libnl/issues/270
- install -m 0755 tests/.libs/* ${D}${PTEST_PATH}/
- # contains build paths
- rm ${D}${PTEST_PATH}/*.la
+do_install_ptest() {
+ ./libtool install install ./tests/check-all ${D}${PTEST_PATH}/
}
BBCLASSEXTEND = "native nativesdk"