1
0
mirror of https://github.com/termux/termux-packages synced 2024-06-27 06:47:09 +00:00
termux-packages/packages/htop/fix-missing-macros.patch
marcusz ce99a04eab
move and update htop to 3.0.5 from root-repo (#9998)
package `htop` will be merged into one and should be usable for all users while keeping it up-to-date
2022-04-15 15:36:10 +08:00

34 lines
710 B
Diff

--- ./Process.c.orig 2021-02-13 11:57:02.747930225 +0000
+++ ./Process.c 2021-02-13 11:58:40.299938503 +0000
@@ -35,6 +35,13 @@
#include <sys/sysmacros.h>
#endif
+#ifndef major
+#define major(rdev) ((rdev)>>8)
+#endif
+
+#ifndef minor
+#define minor(rdev) ((rdev) & 0xff)
+#endif
static uid_t Process_getuid = (uid_t)-1;
--- ./linux/LinuxProcessList.c.orig 2021-02-13 11:57:02.747930225 +0000
+++ ./linux/LinuxProcessList.c 2021-02-13 11:59:30.411609089 +0000
@@ -52,6 +52,14 @@
#include <sys/sysmacros.h>
#endif
+#ifndef major
+#define major(rdev) ((rdev)>>8)
+#endif
+
+#ifndef minor
+#define minor(rdev) ((rdev) & 0xff)
+#endif
+
#ifdef HAVE_SENSORS_SENSORS_H
#include "LibSensors.h"
#endif