mirror of
git://git.savannah.gnu.org/guix.git
synced 2023-12-14 03:33:07 +01:00
gnu: cpulimit: Fix build with glibc-2.32.
* gnu/packages/patches/cpulimit-with-glib-2.32.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/admin.scm (cpulimit)[source]: Use it.
This commit is contained in:
parent
bbe52d3b86
commit
1949c8b206
3 changed files with 39 additions and 2 deletions
|
@ -965,6 +965,7 @@ dist_patch_DATA = \
|
|||
%D%/packages/patches/coq-fix-envvars.patch \
|
||||
%D%/packages/patches/coreutils-ls.patch \
|
||||
%D%/packages/patches/cpuinfo-system-libraries.patch \
|
||||
%D%/packages/patches/cpulimit-with-glib-2.32.patch \
|
||||
%D%/packages/patches/crawl-upgrade-saves.patch \
|
||||
%D%/packages/patches/crda-optional-gcrypt.patch \
|
||||
%D%/packages/patches/clucene-contribs-lib.patch \
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès <ludo@gnu.org>
|
||||
;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com>
|
||||
;;; Copyright © 2014, 2015, 2016, 2018, 2019, 2020 Mark H Weaver <mhw@netris.org>
|
||||
;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2020, 2021 Eric Bavier <bavier@posteo.net>
|
||||
;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2020, 2021, 2022 Eric Bavier <bavier@posteo.net>
|
||||
;;; Copyright © 2015, 2016 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
|
||||
;;; Copyright © 2015 Alex Sassmannshausen <alex.sassmannshausen@gmail.com>
|
||||
;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
|
||||
|
@ -2858,7 +2858,8 @@ lookup to YAML Mode. You could enable the mode with @code{(add-hook
|
|||
(commit (string-append "v" version))))
|
||||
(file-name (git-file-name name version))
|
||||
(sha256
|
||||
(base32 "1dz045yhcsw1rdamzpz4bk8mw888in7fyqk1q1b3m1yk4pd1ahkh"))))
|
||||
(base32 "1dz045yhcsw1rdamzpz4bk8mw888in7fyqk1q1b3m1yk4pd1ahkh"))
|
||||
(patches (search-patches "cpulimit-with-glib-2.32.patch"))))
|
||||
(build-system gnu-build-system)
|
||||
(arguments
|
||||
`(#:phases (modify-phases %standard-phases
|
||||
|
|
35
gnu/packages/patches/cpulimit-with-glib-2.32.patch
Normal file
35
gnu/packages/patches/cpulimit-with-glib-2.32.patch
Normal file
|
@ -0,0 +1,35 @@
|
|||
From 4a4794e041edf85cb67b9fbba66ad1a22fdcaaec Mon Sep 17 00:00:00 2001
|
||||
From: Eric Bavier <bavier@posteo.net>
|
||||
Date: Sat, 29 Jan 2022 00:10:20 -0600
|
||||
Subject: [PATCH] Fixes linux build with glibc-2.32.
|
||||
|
||||
* cpulimit.c: Guard inclusion of <sys/sysctl.h> which is needed only for
|
||||
__APPLE__ and is deprecated and unavailable starting with glibc-2.32.
|
||||
---
|
||||
src/cpulimit.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
Submitted upstream at https://github.com/opsengine/cpulimit/pull/105
|
||||
|
||||
diff --git a/src/cpulimit.c b/src/cpulimit.c
|
||||
index 50eabea..be8cf22 100644
|
||||
--- a/src/cpulimit.c
|
||||
+++ b/src/cpulimit.c
|
||||
@@ -38,13 +38,13 @@
|
||||
#include <string.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/time.h>
|
||||
-#include <sys/sysctl.h>
|
||||
#include <sys/resource.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/wait.h>
|
||||
|
||||
#ifdef __APPLE__ || __FREEBSD__
|
||||
#include <libgen.h>
|
||||
+#include <sys/sysctl.h>
|
||||
#endif
|
||||
|
||||
#include "process_group.h"
|
||||
--
|
||||
2.34.0
|
||||
|
Loading…
Reference in a new issue