summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexis Janon2020-09-20 23:45:16 +0200
committerAlexis Janon2020-09-20 23:59:16 +0200
commit9c3dc7bb4e51f351f0c17535f2bf66c5adfc2392 (patch)
tree64eb98076da1ec81a3587fd96fd825274c6d45c1
parent443fa8541d4faa987eaf6a6a436a02876c6a0515 (diff)
downloadaur-9c3dc7bb4e51f351f0c17535f2bf66c5adfc2392.tar.gz
patch 'os.h' to allow slurm to build
Following the removal of the 'sysctl' syscall in Linux 5.5, the GNU libc has removed the sys/sysctl.h header and associated function in version 2.32 (see the release notes: https://sourceware.org/pipermail/libc-announce/2020/000029.html). The 'os.h' file includes this removed header. This commit introduces the 'sysctl.patch' file, which removes the inclusion of the the 'sys/sysctl.h' file. The software seems to build and run fine without it.
-rw-r--r--.SRCINFO6
-rw-r--r--PKGBUILD13
-rw-r--r--sysctl.patch11
3 files changed, 24 insertions, 6 deletions
diff --git a/.SRCINFO b/.SRCINFO
index c48f88f20060..faeacf47aaee 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,9 +1,7 @@
-# Generated by mksrcinfo v8
-# Sun Jun 23 01:56:45 UTC 2019
pkgbase = slurm
pkgdesc = Monitoring traffic statistics in realtime
pkgver = 0.4.3
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/mattthias/slurm/wiki
arch = i686
arch = x86_64
@@ -11,7 +9,9 @@ pkgbase = slurm
makedepends = cmake
depends = ncurses
source = https://github.com/mattthias/slurm/archive/upstream/0.4.3.tar.gz
+ source = sysctl.patch
md5sums = ff39b8e1fd31274ba1bb36d4aadc1d48
+ md5sums = b8badc91fcfcfefebf68f1e4635c6e5f
pkgname = slurm
diff --git a/PKGBUILD b/PKGBUILD
index 1c7d6b693e6d..71bc6f850a1c 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -5,15 +5,22 @@
# Contributor: Falconindy
pkgname=slurm
pkgver=0.4.3
-pkgrel=1
+pkgrel=2
pkgdesc="Monitoring traffic statistics in realtime"
url="https://github.com/mattthias/slurm/wiki"
license=("GPL")
arch=('i686' 'x86_64')
depends=('ncurses')
makedepends=('cmake')
-source=("https://github.com/mattthias/$pkgname/archive/upstream/$pkgver.tar.gz")
-md5sums=('ff39b8e1fd31274ba1bb36d4aadc1d48')
+source=("https://github.com/mattthias/$pkgname/archive/upstream/$pkgver.tar.gz"
+ "sysctl.patch")
+md5sums=('ff39b8e1fd31274ba1bb36d4aadc1d48'
+ 'b8badc91fcfcfefebf68f1e4635c6e5f')
+
+prepare() {
+ cd "$srcdir/$pkgname-upstream-$pkgver"
+ patch --forward --strip=1 --input="${srcdir}/sysctl.patch"
+}
build() {
cd "$srcdir/$pkgname-upstream-$pkgver"
diff --git a/sysctl.patch b/sysctl.patch
new file mode 100644
index 000000000000..014ec1ad53c7
--- /dev/null
+++ b/sysctl.patch
@@ -0,0 +1,11 @@
+diff --unified --recursive --text package.orig/os.h package.new/os.h
+--- package.orig/os.h 2015-08-16 19:54:19.000000000 +0200
++++ package.new/os.h 2020-09-20 23:55:27.463447823 +0200
+@@ -177,7 +177,6 @@
+ #elif defined (__linux__) /* L I N U X */
+ #include <stdio.h>
+ #include <sys/param.h>
+-#include <sys/sysctl.h>
+ #include <stdlib.h>
+ #include <stdarg.h>
+ #include <unistd.h>