Browse Source

package/numactl: bump to version 2.0.18

For change logs since 2.0.16, see:
https://github.com/numactl/numactl/releases/tag/v2.0.18
https://github.com/numactl/numactl/releases/tag/v2.0.17

This commit also removes the package patch, which was included in
numactl v2.0.17. Since this patch was modifying configure.ac, the
"NUMACTL_AUTORECONF = YES" directive is also removed. Finally, the
patch entry in the ".checkpackageignore" file is also removed.

This commit also adds an upstream patch, not yet in this release, which
fixes builds with Kernel header not providing the
set_mempolicy_home_node() system call.

Signed-off-by: Julien Olivain <ju.o@free.fr>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Julien Olivain 10 months ago
parent
commit
b5f337e891

+ 0 - 1
.checkpackageignore

@@ -947,7 +947,6 @@ package/nss-pam-ldapd/S45nslcd Shellcheck lib_sysv.EmptyLastLine lib_sysv.Indent
 package/ntp/0001-ntp-syscalls-fallback.patch lib_patch.Upstream
 package/ntp/S49ntp.in lib_sysv.Variables
 package/ntpsec/0001-wscript-remove-checks-for-bsd-string.h-fixes-host-co.patch lib_patch.Upstream
-package/numactl/0001-link-with-latomic-if-needed-again.patch lib_patch.Upstream
 package/nuttcp/0001-susv3-legacy.patch lib_patch.Upstream
 package/nvidia-driver/0001-use-LDFLAGS.patch lib_patch.Upstream
 package/octave/0001-Fix-BLAS-library-integer-size-detection.patch lib_patch.Upstream

+ 46 - 0
package/numactl/0001-Don-t-fail-build-when-set_mempolicy_home_node-syscal.patch

@@ -0,0 +1,46 @@
+From c265971648f82464a76f797c4c20a09def078be9 Mon Sep 17 00:00:00 2001
+From: Andi Kleen <ak@linux.intel.com>
+Date: Thu, 16 May 2024 09:03:24 -0700
+Subject: [PATCH] Don't fail build when set_mempolicy_home_node syscall is
+ unknown
+
+Instead just warn at build and return ENOSYS. This fixes build
+on architectures like arm without kernel headers installed.
+
+Fixes #219
+
+Upstream: https://github.com/numactl/numactl/commit/87342c3b9a42aadbe1398ca8233d13ab524aa64f
+Signed-off-by: Andi Kleen <ak@linux.intel.com>
+---
+ syscall.c | 7 ++++++-
+ 1 file changed, 6 insertions(+), 1 deletion(-)
+
+diff --git a/syscall.c b/syscall.c
+index 63b3e53..392f736 100644
+--- a/syscall.c
++++ b/syscall.c
+@@ -144,7 +144,7 @@
+ #if defined(__x86_64__) || defined(__aarch64__)
+ #define __NR_set_mempolicy_home_node 450
+ #else
+-#error "Add syscalls for your architecture or update kernel headers"
++#warning "Add syscalls for your architecture or update kernel headers"
+ #endif
+ 
+ #endif
+@@ -261,7 +261,12 @@ long WEAK move_pages(int pid, unsigned long count,
+ 
+ int WEAK set_mempolicy_home_node(void *start, unsigned long len, int home_node, int flags)
+ {
++#ifndef __NR_set_mempolicy_home_node
++   errno = ENOSYS;
++   return -1;
++#else
+    return syscall(__NR_set_mempolicy_home_node, start, len, home_node, flags);
++#endif
+ }
+ 
+ /* SLES8 glibc doesn't define those */
+-- 
+2.46.2
+

+ 0 - 41
package/numactl/0001-link-with-latomic-if-needed-again.patch

@@ -1,41 +0,0 @@
-From 692abb6d751a41c7f0206771ecd454933750256e Mon Sep 17 00:00:00 2001
-From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
-Date: Wed, 2 Nov 2022 13:28:02 +0100
-Subject: [PATCH] link with -latomic if needed (again ...)
-
-numactl unconditionally uses __atomic_fetch_and but some architectures
-(e.g. sparc) needs to link with -latomic to be able to use it. So check
-if -latomic is needed and update numa.pc accordingly.
-
-This linking was made by e0de0d9e981ddb53bdeb4a4b9dc43046c9ff4ff9 but
-wrongly reverted by 10c277c20768be9a563f75265bcd7e73954763ad resulting
-in the following build failure on sparc or microblaze:
-
-/nvmedata/autobuild/instance-7/output-1/per-package/numactl/host/bin/../lib/gcc/sparc-buildroot-linux-uclibc/10.4.0/../../../../sparc-buildroot-linux-uclibc/bin/ld: ./.libs/libnuma.a(libnuma.o): in function `numa_police_memory':
-libnuma.c:(.text+0xe28): undefined reference to `__atomic_fetch_and_1'
-
-Fixes:
- - http://autobuild.buildroot.org/results/54b7567d804d9abff56f47cd26bae774c1e38669
-
-Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
-[Upstream status: https://github.com/numactl/numactl/pull/144]
----
- configure.ac | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/configure.ac b/configure.ac
-index 8510fc5..ebf9917 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -27,6 +27,8 @@ AM_CONDITIONAL([RISCV64], [test x"${target_cpu}" = x"riscv64"])
- 
- AC_CONFIG_FILES([Makefile])
- 
-+AC_SEARCH_LIBS([__atomic_fetch_and_1], [atomic])
-+
- # GCC tries to be "helpful" and only issue a warning for unrecognized
- # attributes.  So we compile the test with Werror, so that if the
- # attribute is not recognized the compilation fails
--- 
-2.35.1
-

+ 1 - 1
package/numactl/numactl.hash

@@ -1,4 +1,4 @@
 # Locally calculated
-sha256  1b242f893af977a1d31af6ce9d6b8dafdd2d8ec3dc9207f7c2dc0d3446e7c7c8  numactl-2.0.16.tar.gz
+sha256  b4fc0956317680579992d7815bc43d0538960dc73aa1dd8ca7e3806e30bc1274  numactl-2.0.18.tar.gz
 sha256  ab15fd526bd8dd18a9e77ebc139656bf4d33e97fc7238cd11bf60e2b9b8666c6  LICENSE.GPL2
 sha256  dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551  LICENSE.LGPL2.1

+ 1 - 3
package/numactl/numactl.mk

@@ -4,14 +4,12 @@
 #
 ################################################################################
 
-NUMACTL_VERSION = 2.0.16
+NUMACTL_VERSION = 2.0.18
 NUMACTL_SITE = \
 	https://github.com/numactl/numactl/releases/download/v$(NUMACTL_VERSION)
 NUMACTL_LICENSE = LGPL-2.1 (libnuma), GPL-2.0 (programs)
 NUMACTL_LICENSE_FILES = LICENSE.GPL2 LICENSE.LGPL2.1
 NUMACTL_INSTALL_STAGING = YES
-# We're patching configure.ac
-NUMACTL_AUTORECONF = YES
 NUMACTL_CONF_ENV = CFLAGS="$(TARGET_CFLAGS) -fPIC"
 
 $(eval $(autotools-package))