summaryrefslogtreecommitdiff
path: root/sys-process/numactl
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /sys-process/numactl
reinit the tree, so we can have metadata
Diffstat (limited to 'sys-process/numactl')
-rw-r--r--sys-process/numactl/Manifest16
-rw-r--r--sys-process/numactl/files/numactl-2.0.10-numademo-cflags.patch15
-rw-r--r--sys-process/numactl/files/numactl-2.0.11-sysmacros.patch41
-rw-r--r--sys-process/numactl/files/numactl-2.0.8-cpuid-pic.patch17
-rw-r--r--sys-process/numactl/files/numactl-2.0.8-static_libs.patch86
-rw-r--r--sys-process/numactl/files/numactl-2.0.9-testsuite_fix.patch12
-rw-r--r--sys-process/numactl/files/numactl-2.0.9-testsuite_path.patch14
-rw-r--r--sys-process/numactl/metadata.xml8
-rw-r--r--sys-process/numactl/numactl-2.0.10-r2.ebuild49
-rw-r--r--sys-process/numactl/numactl-2.0.11-r1.ebuild58
-rw-r--r--sys-process/numactl/numactl-2.0.11.ebuild54
-rw-r--r--sys-process/numactl/numactl-2.0.9.ebuild55
12 files changed, 425 insertions, 0 deletions
diff --git a/sys-process/numactl/Manifest b/sys-process/numactl/Manifest
new file mode 100644
index 000000000000..c6b396573373
--- /dev/null
+++ b/sys-process/numactl/Manifest
@@ -0,0 +1,16 @@
+AUX numactl-2.0.10-numademo-cflags.patch 504 SHA256 fd1b3cc3f03155269f52f4e4beda67221993104315eaef413fb83f271e98cd1b SHA512 15266d98c375241fd84146a010f329265644666ab90d517865675618a8f793ea6bdc39e7c8b64836fa5b393afad1cd3c89452e838d751adbb315668a2cd29b78 WHIRLPOOL 8d8313bb7d4423e4008bd755c268a658bd88a40a33956afc26134bcf18b21e5f0283a68d36a45af48a8f06a8bdd9b216e2dc55c1c037da405860bfb3367cf3c8
+AUX numactl-2.0.11-sysmacros.patch 1391 SHA256 592f30f7f5f757dfc239ad0ffd39a9a048487ad803c26b419e0f96b8cda08c1a SHA512 39c5841000650af58ae4f6b15a2e2af7b4fb45e7514537f1d081cc0be74bf13aaa3d336a31ef15386b897cc3478ec58b8c194850e99ca2605f5f25be1650a63f WHIRLPOOL 6ba6d97fc65bd9544b56cb07623784532cf21f06eda20e366a77699428fbcd81cd3dd79083b71a7547c12ffab01b7efa633ed2501456c9d21b70daf3deff50d4
+AUX numactl-2.0.8-cpuid-pic.patch 697 SHA256 fc6d5e058ceb1953665fe67ec893a575b51c4cdd43a11117fb416bb88ad45459 SHA512 d9624110a7f8459c13b67eb990f05bc54ffe55818d586691b307dcc4ca5861f064a7269f1038cba5f8abf0f2b6d359d30e4f8d6e904a7e5c0da3404ef1bd4d51 WHIRLPOOL a59de11f4784636d618774f1a660eed3a534225e85881a036b13a59ec28823813b224081dffb9ab5870f7cf3bf4155bb0c92abc317dd3955fed8ab266f8d299d
+AUX numactl-2.0.8-static_libs.patch 2761 SHA256 ff8abe7defc4fde1f2bd380ccb0df3990ea57ddfcafd07cde6327820c667be16 SHA512 828dbcd719671c8ca81745d5670d48c071a8b353b9e42bbbaf9eeffd41b607a53ae24ddd6f0be422a2e6f61899635228da0926d7d8dedd143f52fde5bc5dbe05 WHIRLPOOL fd8f1dcc105b6cec190cd767a0c9bf2b3f556b541637e88c8ec718973732108bac3eec8cc1bcb5394c2f882b972b37d6234b016b2bbc3d8e1faa1372eb13e60c
+AUX numactl-2.0.9-testsuite_fix.patch 262 SHA256 2b857d892f99fb93e2fb961ac08f054d60b0c9a93331226e866d6bb66b7c4417 SHA512 8b9d952076eb04f0093d25c87f25e3f68f9a02a96daa4b574414f75092ded757fd587419584e8ea1883c0881aa2d462cf04904a479c0a925784e111e4b95a6c8 WHIRLPOOL 9d996e854e68d610658e0a0853ee4be9ea5aa30dc4ced8db0a55689c5d8d3235af54102744704b0480d1d8213f814dbe5b8792479ac7e90cce1de2597747bb02
+AUX numactl-2.0.9-testsuite_path.patch 716 SHA256 a498b303d93c8d311c163d497e7b28899dfd09fc5201ef3cde7b65381ea99878 SHA512 ed6ba9f225f551d473231c187b962e7c6dd2d20ded491a07fab6ec1edebd27c0eed7186e6eeee0c665eb2139425b23dd4a1162cca0eab31e8f063d48a4908629 WHIRLPOOL f91ff4876e75f6130d4199e1dd3d0beb4d7e959c25877f5703342623366ef4f841e2b7832177fbe7222607a5f1c120a89dd6ed88b5b84f020347bf28d28287e9
+DIST numactl-2.0.10.tar.gz 98999 SHA256 9d197fefac81c73dc2b2e554f1758b2ec56d4e9b2f04a7f45dff5d6cb14fb9ce SHA512 3a82b28bbc724a2340950ac33396055da852ee06e5b1d3414cd83dd6f9e26fbb648faae35ce4009c76d6a180f3067a8f3fb18e3ffaa6b6db68adfc0877e94975 WHIRLPOOL 59a172c14d96b01b1e13d2913f6f820d4f9bacb2f80e2920d4350273ff01ab57d56ab4a163fde2df3898c4b7cf204bd4a333c99f9feb9d5bcd89fea799a3d2db
+DIST numactl-2.0.11.tar.gz 408175 SHA256 450c091235f891ee874a8651b179c30f57a1391ca5c4673354740ba65e527861 SHA512 1969d7ee0ff3de0d6f1fa42ec089a17cdb3f92cb35d453b8f8b2eec49724c43787ecbd213357013a8f2500a260b0df9844d515815ca3a0376314a0eed050a0d4 WHIRLPOOL 2d22a54de00bea80835e206704652d4fead1b585b3bedd4eeb4b61d96514117e91a9c8bda466bd7f8d17e3777c4e7a8d69dd0a6e5b6ab29c0141e086c09c311b
+DIST numactl-2.0.9.tar.gz 341455 SHA256 9ca033e6c14c0f26c20379b0cf9299429fd5a354a79c3c7880fd41ef69f7751c SHA512 483cbb1607da0f3bf0923202ea565100ea430b19502bdbd322f043f75dc945cc0f47878c0ed28badab23561c37da0b04aa12d07656bb4666c4f8d02a0d256407 WHIRLPOOL 5aba5b4a6ab0a4f06a2266054fdc7be8ca81696cf417e4fa4d10667ab95195edc5e002551a3bda4ea1eb25caf01d171ed18a16e4c29960902546aa78d7b93d73
+EBUILD numactl-2.0.10-r2.ebuild 1341 SHA256 e2e7e246ab9e032849df4c4d24478fc3bb8c8ab267268d705a85161c2922e290 SHA512 ca84553e42fdfc562ffa94d4add751b0005d9696891556a49961e6941e49b1334e786f0c385cbc37c7cea22fb2bc9345bae1998eb14f86d287c07ce9c5f7f331 WHIRLPOOL 5af12e18621908d51074cac692e7501229cd841d034db04da0b3d9a9279c6ac205e40e74e0efdd1821f2c0d520e2472026e37dc762360ebdb9027f1c34345533
+EBUILD numactl-2.0.11-r1.ebuild 1668 SHA256 142a557291b78e3977bdb93c9d434d96791aafabd2c3d990adf299e9ac10ce99 SHA512 f7a4265e81b14d1d5b6814ecddc5640f30fb1ca9c7cf7e8750a754bd397e7327d9af00598a7c19b8906f405487205cbee62f1937faee83fb56a5d1adbe48d740 WHIRLPOOL 86f237681f130ce92c595696549f29d731a97660f3dd2d42299715c1b3887a5764d2b170b29e1c5ccf1cb976104cd8bbc0db2dae19351c703eb74f976250422a
+EBUILD numactl-2.0.11.ebuild 1527 SHA256 b4d2313199c5324bff7918821ddf2c90a0bc2b6bf4c9c742234930a07df19fbb SHA512 0a0a6eff479e075be84a48dbe2994c1ce884ad3dee6da4d2d83c770ec7db42cdde077bcd3e17c23166bf19eb83eeecbeb86d1b7c48df34c3146bfece8db481dd WHIRLPOOL 7d783ab0405bccedfb40cd0f68b1a38b7e45abae2dc837bb0acbbadfa6072edbda73eebb9fd5066e1dce412d6e3b79801a261cb2c5f6edd9737f15cfe6ac6731
+EBUILD numactl-2.0.9.ebuild 1555 SHA256 ffec5268b61594973b98470f5bd4f0dcc79d64509f9810dc72eadee08983593d SHA512 9fc857360e0dc121a0737f2109b017d0d5c5474b349ce34aa7632301f44991303b4fd6479f3d23d81c4d629553ed580f7468d1ebc5f001530eed7e1d76fd3833 WHIRLPOOL 5dfc64ab18d43cd52233c2331142c2841a5c0127cd617cee4b675fc5b555918aae9a363aedc14c28d9c0feb90289fcec0cbb0eaf468d2eb7a52a72b6ec5630d1
+MISC ChangeLog 5484 SHA256 97de5d01d56a13f7c2dea7dc7de62cff0e73b18fae8504b3676a90c57e7107b5 SHA512 1f0a8f41d536fccc01f7d77a47d41fa185d17385f3cb8138a66ccab346d80562a0c2b61a04209ee9bb2090562c241ba011ce89bcb642fcb04f6f3348b5bc4d83 WHIRLPOOL 7bdb16614201dc9bf5a6bf99db9d015d335156d6c665ef5ed4dff1a6cca92cdeb71672898d02950ccf80d5bb1817f400defada715df50bc863d0dfdca7ee2d78
+MISC ChangeLog-2015 6498 SHA256 63cc4288b037d0495b6907a3f601452e181e40c2625f8446d1ed694f92d4bc7c SHA512 43519e08192c9c14ef982ff851b7a77eea4c06a0a50243e3def2238d7b08644d0bd9750c96dbccbc0e1e4fafdc29ca1bef4cf75d97c79fd16ee9b867380068e9 WHIRLPOOL 96bf61e149caeb26755dbb7c5f235f70fa4ad491502e41350617b4f650f0d7dfc7629eff66548507a0c6c459b411035d49f7046f77de64144cd354f07e55ffcb
+MISC metadata.xml 253 SHA256 d82c33ef453113a5c1ebe250dcba373c22934a69b0a86c6ab15a5ca589c25b91 SHA512 54a9069aeb4165d2dff3d473c8001bc51613aac9dff3f7f5e9971a9891a737a31511ffa11cbd523febe581ac1d9de2bdf2f40410f0c4239138f2ccca3ef15555 WHIRLPOOL e5aee23acff864609953a1e4de768f0e4aef704b44c53c021f28573e1ca5c99f1a46d92935ecec2449f7b4419a36d8373127d0ecfa8d7bae72d835e1839eb3f8
diff --git a/sys-process/numactl/files/numactl-2.0.10-numademo-cflags.patch b/sys-process/numactl/files/numactl-2.0.10-numademo-cflags.patch
new file mode 100644
index 000000000000..9b318df5a5ca
--- /dev/null
+++ b/sys-process/numactl/files/numactl-2.0.10-numademo-cflags.patch
@@ -0,0 +1,15 @@
+https://bugs.gentoo.org/540856
+
+respect user CFLAGS
+
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -23,7 +23,7 @@ numastat_CFLAGS = $(AM_CFLAGS) -std=gnu99
+
+ numademo_SOURCES = numademo.c stream_lib.c stream_lib.h mt.c mt.h clearcache.c clearcache.h
+ numademo_CPPFLAGS = $(AM_CPPFLAGS) -DHAVE_STREAM_LIB -DHAVE_MT -DHAVE_CLEAR_CACHE
+-numademo_CFLAGS = -O3 -ffast-math -funroll-loops
++numademo_CFLAGS = $(AM_CFLAGS) -ffast-math -funroll-loops
+ if HAVE_TREE_VECTORIZE
+ numademo_CFLAGS += -ftree-vectorize
+ endif
diff --git a/sys-process/numactl/files/numactl-2.0.11-sysmacros.patch b/sys-process/numactl/files/numactl-2.0.11-sysmacros.patch
new file mode 100644
index 000000000000..3f9536757391
--- /dev/null
+++ b/sys-process/numactl/files/numactl-2.0.11-sysmacros.patch
@@ -0,0 +1,41 @@
+https://bugs.gentoo.org/580098
+
+From c1644f92e340d797e490c41a9ef9961125d202b9 Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Mon, 18 Apr 2016 18:49:51 -0400
+Subject: [PATCH] include sys/sysmacros.h for major/minor
+
+These functions are not part of any official spec, and glibc has always
+kept them in sys/sysmacros.h. As glibc moves to conform to POSIX, and
+more alternative C libraries come up, we need to include this header
+explicitly to get the prototypes. Otherwise we fail to build like:
+
+affinity.c: In function 'affinity_file':
+affinity.c:177:7: warning: implicit declaration of function 'major' [-Wimplicit-function-declaration]
+ if (major(d) != maj || minor(d) != min)
+ ^
+affinity.c:177:26: warning: implicit declaration of function 'minor' [-Wimplicit-function-declaration]
+ if (major(d) != maj || minor(d) != min)
+ ^
+./.libs/libnuma.so: undefined reference to 'minor'
+./.libs/libnuma.so: undefined reference to 'major'
+collect2: error: ld returned 1 exit status
+---
+ affinity.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/affinity.c b/affinity.c
+index 9fbd6af..984291c 100644
+--- a/affinity.c
++++ b/affinity.c
+@@ -40,6 +40,7 @@
+ #include <linux/rtnetlink.h>
+ #include <linux/netlink.h>
+ #include <sys/types.h>
++#include <sys/sysmacros.h>
+ #include <ctype.h>
+ #include <assert.h>
+ #include <regex.h>
+--
+2.7.4
+
diff --git a/sys-process/numactl/files/numactl-2.0.8-cpuid-pic.patch b/sys-process/numactl/files/numactl-2.0.8-cpuid-pic.patch
new file mode 100644
index 000000000000..02e84b725772
--- /dev/null
+++ b/sys-process/numactl/files/numactl-2.0.8-cpuid-pic.patch
@@ -0,0 +1,17 @@
+make the code work on x86/PIC. this code is only used in the demo,
+and the overhead of always running this is system noise, so don't
+bother bracketing with __i386__/__PIC__ defines.
+
+http://bugs.gentoo.org/456238
+
+--- a/clearcache.c
++++ b/clearcache.c
+@@ -57,7 +57,7 @@ void clearcache(unsigned char *mem, unsigned size)
+ #if defined(__i386__) || defined(__x86_64__)
+ unsigned i, cl, eax, feat;
+ /* get clflush unit and feature */
+- asm("cpuid" : "=a" (eax), "=b" (cl), "=d" (feat) : "0" (1) : "cx");
++ asm("xchg %%ebx, %%esi; cpuid; xchg %%esi, %%ebx;" : "=a" (eax), "=S" (cl), "=d" (feat) : "0" (1) : "cx");
+ if (!(feat & (1 << 19)))
+ fallback_clearcache();
+ cl = ((cl >> 8) & 0xff) * 8;
diff --git a/sys-process/numactl/files/numactl-2.0.8-static_libs.patch b/sys-process/numactl/files/numactl-2.0.8-static_libs.patch
new file mode 100644
index 000000000000..efb84ff6240a
--- /dev/null
+++ b/sys-process/numactl/files/numactl-2.0.8-static_libs.patch
@@ -0,0 +1,86 @@
+Build static libs without -fPIC and only if BUILD_STATIC=yes
+
+https://bugs.gentoo.org/379849
+
+Patch written by Kacper Kowalik <xarthisius@gentoo.org>
+--- a/Makefile
++++ b/Makefile
+@@ -7,6 +7,8 @@
+ # for compatibility with old releases
+ CFLAGS += ${OPT_CFLAGS}
+ override CFLAGS += -I.
++# build static libraries by default
++BUILD_STATIC ?= yes
+
+ # find out if compiler supports __thread
+ THREAD_SUPPORT := $(shell if $(CC) $(CFLAGS) threadtest.c -o threadtest \
+@@ -24,6 +26,7 @@
+
+ CLEANFILES := numactl.o libnuma.o numactl numademo numademo.o distance.o \
+ memhog libnuma.so libnuma.so.1 numamon numamon.o syscall.o bitops.o \
++ distance.pic.o libnuma.pic.o syscall.pic.o \
+ memhog.o util.o stream_main.o stream_lib.o shm.o stream clearcache.o \
+ test/pagesize test/tshared test/mynode.o test/tshared.o mt.o empty.o empty.c \
+ test/mynode test/ftok test/prefered test/randmap \
+@@ -40,11 +43,16 @@
+ libdir := ${prefix}/$(shell ./getlibdir)
+ docdir := ${prefix}/share/doc
+
++NUMA_LIBS = libnuma.so
++ifeq ($(BUILD_STATIC),yes)
++NUMA_LIBS+= libnuma.a
++endif
++
+ all: numactl migratepages migspeed libnuma.so numademo numamon memhog \
+ test/tshared stream test/mynode test/pagesize test/ftok test/prefered \
+ test/randmap test/nodemap test/distance test/tbitmap test/move_pages \
+ test/mbind_mig_pages test/migrate_pages test/realloc_test libnuma.a \
+- test/node-parse numastat
++ test/node-parse numastat ${NUMA_LIBS}
+
+ numactl: numactl.o util.o shm.o bitops.o libnuma.so
+
+@@ -81,13 +89,14 @@
+
+ libnuma.so.1: versions.ldscript
+
+-libnuma.so.1: libnuma.o syscall.o distance.o affinity.o sysfs.o rtnetlink.o
++libnuma.so.1: libnuma.pic.o syscall.pic.o distance.pic.o affinity.pic.o sysfs.pic.o rtnetlink.pic.o
+ ${CC} ${LDFLAGS} -shared -Wl,-soname=libnuma.so.1 -Wl,--version-script,versions.ldscript -Wl,-init,numa_init -Wl,-fini,numa_fini -o libnuma.so.1 $(filter-out versions.ldscript,$^)
+
+ libnuma.so: libnuma.so.1
+ ln -sf libnuma.so.1 libnuma.so
+
+-libnuma.o : CFLAGS += -fPIC
++%.pic.o: %.c
++ ${CC} -fPIC ${CPPFLAGS} ${CFLAGS} -c $< -o $@
+
+ AR ?= ar
+ RANLIB ?= ranlib
+@@ -95,16 +104,6 @@
+ $(AR) rc $@ $^
+ $(RANLIB) $@
+
+-distance.o : CFLAGS += -fPIC
+-
+-syscall.o : CFLAGS += -fPIC
+-
+-affinity.o : CFLAGS += -fPIC
+-
+-sysfs.o : CFLAGS += -fPIC
+-
+-rtnetlink.o : CFLAGS += -fPIC
+-
+ test/tshared: test/tshared.o libnuma.so
+
+ test/mynode: test/mynode.o libnuma.so
+@@ -143,7 +148,9 @@
+ mkdir -p ${libdir}
+ install -m 0755 libnuma.so.1 ${libdir}
+ cd ${libdir} ; ln -sf libnuma.so.1 libnuma.so
++ifeq ($(BUILD_STATIC),yes)
+ install -m 0644 libnuma.a ${libdir}
++endif
+ mkdir -p ${prefix}/include
+ install -m 0644 numa.h numaif.h numacompat1.h ${prefix}/include
+ install -m 0755 numastat ${prefix}/bin
diff --git a/sys-process/numactl/files/numactl-2.0.9-testsuite_fix.patch b/sys-process/numactl/files/numactl-2.0.9-testsuite_fix.patch
new file mode 100644
index 000000000000..27a97fdf2509
--- /dev/null
+++ b/sys-process/numactl/files/numactl-2.0.9-testsuite_fix.patch
@@ -0,0 +1,12 @@
+Tests fail with /bin/dash
+
+Singned-off-by: Lars Wendler <polynomial-c@gentoo.org>
+
+--- numactl-2.0.9/test/printcpu
++++ numactl-2.0.9/test/printcpu
+@@ -1,4 +1,4 @@
+-#!/bin/sh
++#!/bin/bash
+ #print cpu it is running on
+ declare -a arr
+ arr=( $(< /proc/self/stat) )
diff --git a/sys-process/numactl/files/numactl-2.0.9-testsuite_path.patch b/sys-process/numactl/files/numactl-2.0.9-testsuite_path.patch
new file mode 100644
index 000000000000..018fc6dbcd18
--- /dev/null
+++ b/sys-process/numactl/files/numactl-2.0.9-testsuite_path.patch
@@ -0,0 +1,14 @@
+diff -Naur numactl-2.0.10-orig/test/bind_range numactl-2.0.10/test/bind_range
+--- numactl-2.0.10-orig/test/bind_range 2015-05-03 22:23:31.095600314 -0400
++++ numactl-2.0.10/test/bind_range 2015-05-03 22:25:29.107592557 -0400
+@@ -93,8 +93,8 @@
+
+ HIGHESTCPU=$(grep 'processor' /proc/cpuinfo | tail -n1 | cut -f2 -d':')
+ HIGHESTCPU=$(echo $HIGHESTCPU | cut -f2 -d' ')
+-HIGHESTNODE=$(numactl -H | grep -e 'node [0-9]* cpus' | tail -n1 | cut -f2 -d' ')
+-LOWESTNODE=$(numactl -H | grep -e 'node [0-9]* cpus' | head -n1 | cut -f2 -d' ')
++HIGHESTNODE=$(../numactl -H | grep -e 'node [0-9]* cpus' | tail -n1 | cut -f2 -d' ')
++LOWESTNODE=$(../numactl -H | grep -e 'node [0-9]* cpus' | head -n1 | cut -f2 -d' ')
+
+ get_mask
+
diff --git a/sys-process/numactl/metadata.xml b/sys-process/numactl/metadata.xml
new file mode 100644
index 000000000000..56c124413057
--- /dev/null
+++ b/sys-process/numactl/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer type="project">
+ <email>base-system@gentoo.org</email>
+ <name>Gentoo Base System</name>
+</maintainer>
+</pkgmetadata>
diff --git a/sys-process/numactl/numactl-2.0.10-r2.ebuild b/sys-process/numactl/numactl-2.0.10-r2.ebuild
new file mode 100644
index 000000000000..9fb85bfcce33
--- /dev/null
+++ b/sys-process/numactl/numactl-2.0.10-r2.ebuild
@@ -0,0 +1,49 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+inherit autotools eutils toolchain-funcs multilib-minimal
+
+DESCRIPTION="Utilities and libraries for NUMA systems"
+HOMEPAGE="http://oss.sgi.com/projects/libnuma/"
+SRC_URI="ftp://oss.sgi.com/www/projects/libnuma/download/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+# ARM lacks the __NR_migrate_pages syscall.
+KEYWORDS="~amd64 -arm ~ia64 ~mips ~ppc ~ppc64 ~x86 ~amd64-linux"
+IUSE=""
+
+ECONF_SOURCE=${S}
+
+src_prepare() {
+ epatch "${FILESDIR}"/${PN}-2.0.8-cpuid-pic.patch #456238
+ epatch "${FILESDIR}"/${PN}-2.0.10-numademo-cflags.patch #540856
+ eautoreconf
+}
+
+src_test() {
+ if [ -d /sys/devices/system/node ]; then
+ einfo "The only generically safe test is regress2."
+ einfo "The other test cases require 2 NUMA nodes."
+ emake regress2
+ else
+ ewarn "You do not have baseline NUMA support in your kernel, skipping tests."
+ fi
+}
+
+multilib_src_compile() {
+ multilib_is_native_abi && default || emake libnuma.la
+}
+
+multilib_src_install() {
+ emake DESTDIR="${D}" install$(multilib_is_native_abi || echo "-libLTLIBRARIES install-includeHEADERS")
+}
+
+multilib_src_install_all() {
+ DOCS=( README TODO CHANGES DESIGN )
+ einstalldocs
+ # delete man pages provided by the man-pages package #238805
+ rm -r "${ED}"/usr/share/man/man[25] || die
+}
diff --git a/sys-process/numactl/numactl-2.0.11-r1.ebuild b/sys-process/numactl/numactl-2.0.11-r1.ebuild
new file mode 100644
index 000000000000..ff96a5ace1b1
--- /dev/null
+++ b/sys-process/numactl/numactl-2.0.11-r1.ebuild
@@ -0,0 +1,58 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="5"
+
+inherit autotools eutils toolchain-funcs multilib-minimal
+
+DESCRIPTION="Utilities and libraries for NUMA systems"
+HOMEPAGE="http://oss.sgi.com/projects/libnuma/"
+SRC_URI="ftp://oss.sgi.com/www/projects/libnuma/download/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+# ARM lacks the __NR_migrate_pages syscall.
+KEYWORDS="~amd64 -arm ~arm64 ~ia64 ~mips ~ppc ~ppc64 ~x86 ~amd64-linux"
+IUSE="static-libs"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${PN}-2.0.8-cpuid-pic.patch #456238
+ epatch "${FILESDIR}"/${PN}-2.0.10-numademo-cflags.patch #540856
+ epatch "${FILESDIR}"/${PN}-2.0.11-sysmacros.patch #580098
+ eautoreconf
+ # We need to copy the sources or else tests will fail
+ multilib_copy_sources
+}
+
+multilib_src_configure() {
+ ECONF_SOURCE=${S} \
+ econf $(use_enable static-libs static)
+}
+
+multilib_src_compile() {
+ multilib_is_native_abi && default || emake libnuma.la
+}
+
+multilib_src_test() {
+ if multilib_is_native_abi ; then
+ if [ -d /sys/devices/system/node ]; then
+ einfo "The only generically safe test is regress2."
+ einfo "The other test cases require 2 NUMA nodes."
+ emake regress2
+ else
+ ewarn "You do not have baseline NUMA support in your kernel, skipping tests."
+ fi
+ fi
+}
+
+multilib_src_install() {
+ emake DESTDIR="${D}" install$(multilib_is_native_abi || echo "-libLTLIBRARIES install-includeHEADERS")
+ find "${ED}"/usr/ -name libnuma.la -delete
+}
+
+multilib_src_install_all() {
+ DOCS=( README TODO CHANGES DESIGN )
+ einstalldocs
+ # delete man pages provided by the man-pages package #238805
+ rm -r "${ED}"/usr/share/man/man[25] || die
+}
diff --git a/sys-process/numactl/numactl-2.0.11.ebuild b/sys-process/numactl/numactl-2.0.11.ebuild
new file mode 100644
index 000000000000..513866b7c61a
--- /dev/null
+++ b/sys-process/numactl/numactl-2.0.11.ebuild
@@ -0,0 +1,54 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+inherit autotools eutils toolchain-funcs multilib-minimal
+
+DESCRIPTION="Utilities and libraries for NUMA systems"
+HOMEPAGE="http://oss.sgi.com/projects/libnuma/"
+SRC_URI="ftp://oss.sgi.com/www/projects/libnuma/download/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+# ARM lacks the __NR_migrate_pages syscall.
+KEYWORDS="amd64 -arm ia64 ~mips ppc ppc64 x86 ~amd64-linux"
+IUSE=""
+
+ECONF_SOURCE=${S}
+
+src_prepare() {
+ epatch "${FILESDIR}"/${PN}-2.0.8-cpuid-pic.patch #456238
+ epatch "${FILESDIR}"/${PN}-2.0.10-numademo-cflags.patch #540856
+ epatch "${FILESDIR}"/${PN}-2.0.11-sysmacros.patch #580098
+ eautoreconf
+ # We need to copy the sources or else tests will fail
+ multilib_copy_sources
+}
+
+multilib_src_test() {
+ if multilib_is_native_abi ; then
+ if [ -d /sys/devices/system/node ]; then
+ einfo "The only generically safe test is regress2."
+ einfo "The other test cases require 2 NUMA nodes."
+ emake regress2
+ else
+ ewarn "You do not have baseline NUMA support in your kernel, skipping tests."
+ fi
+ fi
+}
+
+multilib_src_compile() {
+ multilib_is_native_abi && default || emake libnuma.la
+}
+
+multilib_src_install() {
+ emake DESTDIR="${D}" install$(multilib_is_native_abi || echo "-libLTLIBRARIES install-includeHEADERS")
+}
+
+multilib_src_install_all() {
+ DOCS=( README TODO CHANGES DESIGN )
+ einstalldocs
+ # delete man pages provided by the man-pages package #238805
+ rm -r "${ED}"/usr/share/man/man[25] || die
+}
diff --git a/sys-process/numactl/numactl-2.0.9.ebuild b/sys-process/numactl/numactl-2.0.9.ebuild
new file mode 100644
index 000000000000..15331a31a4d5
--- /dev/null
+++ b/sys-process/numactl/numactl-2.0.9.ebuild
@@ -0,0 +1,55 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="4"
+
+inherit eutils toolchain-funcs multilib
+
+DESCRIPTION="Utilities and libraries for NUMA systems"
+HOMEPAGE="http://oss.sgi.com/projects/libnuma/"
+SRC_URI="ftp://oss.sgi.com/www/projects/libnuma/download/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+# ARM lacks the __NR_migrate_pages syscall.
+KEYWORDS="amd64 -arm ia64 ppc ppc64 x86 ~amd64-linux"
+IUSE="static-libs"
+
+src_prepare() {
+ echo "printf $(get_libdir)" > getlibdir
+ epatch "${FILESDIR}"/${PN}-2.0.8-static_libs.patch
+ epatch "${FILESDIR}"/${PN}-2.0.8-cpuid-pic.patch #456238
+ epatch "${FILESDIR}"/${PN}-2.0.9-testsuite_fix.patch
+ epatch "${FILESDIR}"/${P}-testsuite_path.patch
+ rm numastat || die #466108
+}
+
+src_compile() {
+ emake \
+ AR="$(tc-getAR)" \
+ CC="$(tc-getCC)" \
+ RANLIB="$(tc-getRANLIB)" \
+ CFLAGS="${CFLAGS}" \
+ BENCH_CFLAGS="" \
+ THREAD_SUPPORT=$(tc-has-tls && echo yes || echo no) \
+ BUILD_STATIC=$(usex static-libs)
+}
+
+src_test() {
+ if [ -d /sys/devices/system/node ]; then
+ einfo "The only generically safe test is regress2."
+ einfo "The other test cases require 2 NUMA nodes."
+ cd test
+ ./regress2 || die
+ else
+ ewarn "You do not have baseline NUMA support in your kernel, skipping tests."
+ fi
+}
+
+src_install() {
+ emake install prefix="${ED}/usr" BUILD_STATIC=$(usex static-libs)
+ # delete man pages provided by the man-pages package #238805
+ rm -rf "${ED}"/usr/share/man/man[25]
+ doman *.8 # makefile doesnt get them all
+ dodoc README TODO CHANGES DESIGN
+}