summaryrefslogtreecommitdiffstats
path: root/meta/recipes-extended/psmisc
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-extended/psmisc')
-rw-r--r--meta/recipes-extended/psmisc/psmisc.inc59
-rw-r--r--meta/recipes-extended/psmisc/psmisc/0001-Use-UINTPTR_MAX-instead-of-__WORDSIZE.patch47
-rw-r--r--meta/recipes-extended/psmisc/psmisc_23.7.bb59
3 files changed, 55 insertions, 110 deletions
diff --git a/meta/recipes-extended/psmisc/psmisc.inc b/meta/recipes-extended/psmisc/psmisc.inc
deleted file mode 100644
index 23e98d21be..0000000000
--- a/meta/recipes-extended/psmisc/psmisc.inc
+++ /dev/null
@@ -1,59 +0,0 @@
1SUMMARY = "Utilities for managing processes on your system"
2HOMEPAGE = "http://psmisc.sf.net/"
3DESCRIPTION = "The psmisc package contains utilities for managing processes on your \
4system: pstree, killall and fuser. The pstree command displays a tree \
5structure of all of the running processes on your system. The killall \
6command sends a specified signal (SIGTERM if nothing is specified) to \
7processes identified by name. The fuser command identifies the PIDs \
8of processes that are using specified files or filesystems."
9SECTION = "base"
10DEPENDS = "ncurses virtual/libintl"
11LICENSE = "GPL-2.0-only"
12
13SRC_URI = "${SOURCEFORGE_MIRROR}/psmisc/psmisc-${PV}.tar.gz"
14
15S = "${WORKDIR}/psmisc-${PV}"
16
17inherit autotools gettext
18
19# Upstream has a custom autogen.sh which invokes po/update-potfiles as they
20# don't ship a po/POTFILES.in (which is silly). Without that file gettext
21# doesn't believe po/ is a gettext directory and won't generate po/Makefile.
22do_configure:prepend() {
23 ( cd ${S} && po/update-potfiles )
24}
25
26
27PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
28PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
29PACKAGECONFIG[selinux] = "--enable-selinux,--disable-selinux,libselinux"
30
31ALLOW_EMPTY:${PN} = "1"
32
33PACKAGES =+ "fuser fuser-doc killall killall-doc pstree pstree-doc"
34PACKAGES += "psmisc-extras"
35
36FILES:${PN} = ""
37RDEPENDS:${PN} = "fuser killall pstree"
38
39FILES:fuser = "${bindir}/fuser.${BPN}"
40FILES:fuser-doc = "${mandir}/man1/fuser*"
41
42FILES:killall = "${bindir}/killall.${BPN}"
43FILES:killall-doc = "${mandir}/man1/killall*"
44
45FILES:pstree = "${bindir}/pstree"
46FILES:pstree-doc = "${mandir}/man1/pstree*"
47
48FILES:psmisc-extras = "${bindir}"
49FILES:psmisc-extras-doc = "${mandir}"
50
51inherit update-alternatives
52
53ALTERNATIVE_PRIORITY = "90"
54
55ALTERNATIVE:killall = "killall"
56
57ALTERNATIVE:fuser = "fuser"
58
59ALTERNATIVE:pstree = "pstree"
diff --git a/meta/recipes-extended/psmisc/psmisc/0001-Use-UINTPTR_MAX-instead-of-__WORDSIZE.patch b/meta/recipes-extended/psmisc/psmisc/0001-Use-UINTPTR_MAX-instead-of-__WORDSIZE.patch
deleted file mode 100644
index 01335bdf40..0000000000
--- a/meta/recipes-extended/psmisc/psmisc/0001-Use-UINTPTR_MAX-instead-of-__WORDSIZE.patch
+++ /dev/null
@@ -1,47 +0,0 @@
1From 338d2d46d1c20ebadf317938af98d0532a62f8d4 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Thu, 24 Mar 2016 15:46:14 +0000
4Subject: [PATCH] Use UINTPTR_MAX instead of __WORDSIZE
5
6Do not include sys/user.h since it conflicts with
7pt_regs struct from kernel APIs in asm/ptrace.h
8
9Signed-off-by: Khem Raj <raj.khem@gmail.com>
10Upstream-Status: Pending
11---
12 src/peekfd.c | 13 ++++++++-----
13 1 file changed, 8 insertions(+), 5 deletions(-)
14
15diff --git a/src/peekfd.c b/src/peekfd.c
16index 36dff04..2b4b1dc 100644
17--- a/src/peekfd.c
18+++ b/src/peekfd.c
19@@ -30,8 +30,11 @@
20 #include <asm/ptrace.h>
21 #include <byteswap.h>
22 #include <endian.h>
23+#ifdef __GLIBC__
24 #include <sys/user.h>
25+#endif
26 #include <stdlib.h>
27+#include <stdint.h>
28 #include <getopt.h>
29 #include <ctype.h>
30 #include <dirent.h>
31@@ -341,11 +344,11 @@ int main(int argc, char **argv)
32 if (WIFSTOPPED(status)) {
33 #ifdef PPC
34 struct pt_regs regs;
35- regs.gpr[0] = ptrace(PTRACE_PEEKUSER, pid, __WORDSIZE/8 * PT_R0, 0);
36- regs.gpr[3] = ptrace(PTRACE_PEEKUSER, pid, __WORDSIZE/8 * PT_R3, 0);
37- regs.gpr[4] = ptrace(PTRACE_PEEKUSER, pid, __WORDSIZE/8 * PT_R4, 0);
38- regs.gpr[5] = ptrace(PTRACE_PEEKUSER, pid, __WORDSIZE/8 * PT_R5, 0);
39- regs.orig_gpr3 = ptrace(PTRACE_PEEKUSER, pid, __WORDSIZE/8 * PT_ORIG_R3, 0);
40+ regs.gpr[0] = ptrace(PTRACE_PEEKUSER, pid, UINTPTR_MAX/8 * PT_R0, 0);
41+ regs.gpr[3] = ptrace(PTRACE_PEEKUSER, pid, UINTPTR_MAX/8 * PT_R3, 0);
42+ regs.gpr[4] = ptrace(PTRACE_PEEKUSER, pid, UINTPTR_MAX/8 * PT_R4, 0);
43+ regs.gpr[5] = ptrace(PTRACE_PEEKUSER, pid, UINTPTR_MAX/8 * PT_R5, 0);
44+ regs.orig_gpr3 = ptrace(PTRACE_PEEKUSER, pid, UINTPTR_MAX/8 * PT_ORIG_R3, 0);
45 #elif defined(ARM)
46 struct pt_regs regs;
47 ptrace(PTRACE_GETREGS, pid, 0, &regs);
diff --git a/meta/recipes-extended/psmisc/psmisc_23.7.bb b/meta/recipes-extended/psmisc/psmisc_23.7.bb
index ea272cd92d..44f8530977 100644
--- a/meta/recipes-extended/psmisc/psmisc_23.7.bb
+++ b/meta/recipes-extended/psmisc/psmisc_23.7.bb
@@ -1,9 +1,60 @@
1require psmisc.inc 1SUMMARY = "Utilities for managing processes on your system"
2HOMEPAGE = "http://psmisc.sf.net/"
3DESCRIPTION = "The psmisc package contains utilities for managing processes on your \
4system: pstree, killall and fuser. The pstree command displays a tree \
5structure of all of the running processes on your system. The killall \
6command sends a specified signal (SIGTERM if nothing is specified) to \
7processes identified by name. The fuser command identifies the PIDs \
8of processes that are using specified files or filesystems."
9SECTION = "base"
10DEPENDS = "ncurses virtual/libintl"
11
2LICENSE = "GPL-2.0-only" 12LICENSE = "GPL-2.0-only"
3LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3" 13LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3"
4 14
5SRC_URI = "git://gitlab.com/psmisc/psmisc.git;protocol=https;branch=master \ 15SRC_URI = "git://gitlab.com/psmisc/psmisc.git;protocol=https;branch=master;tag=v${PV} \
6 file://0001-Use-UINTPTR_MAX-instead-of-__WORDSIZE.patch \
7 " 16 "
8SRCREV = "9091d6dbcce3d8fb87adf9249a2eb346d25a562c" 17SRCREV = "9091d6dbcce3d8fb87adf9249a2eb346d25a562c"
9S = "${WORKDIR}/git" 18
19inherit autotools gettext
20
21# Upstream has a custom autogen.sh which invokes po/update-potfiles as they
22# don't ship a po/POTFILES.in (which is silly). Without that file gettext
23# doesn't believe po/ is a gettext directory and won't generate po/Makefile.
24do_configure:prepend() {
25 ( cd ${S} && po/update-potfiles )
26}
27
28PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
29PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6,"
30PACKAGECONFIG[selinux] = "--enable-selinux,--disable-selinux,libselinux"
31
32ALLOW_EMPTY:${PN} = "1"
33
34PACKAGES =+ "fuser fuser-doc killall killall-doc pstree pstree-doc"
35PACKAGES += "psmisc-extras"
36
37FILES:${PN} = ""
38RDEPENDS:${PN} = "fuser killall pstree"
39
40FILES:fuser = "${bindir}/fuser.${BPN}"
41FILES:fuser-doc = "${mandir}/man1/fuser*"
42
43FILES:killall = "${bindir}/killall.${BPN}"
44FILES:killall-doc = "${mandir}/man1/killall*"
45
46FILES:pstree = "${bindir}/pstree"
47FILES:pstree-doc = "${mandir}/man1/pstree*"
48
49FILES:psmisc-extras = "${bindir}"
50FILES:psmisc-extras-doc = "${mandir}"
51
52inherit update-alternatives
53
54ALTERNATIVE_PRIORITY = "90"
55
56ALTERNATIVE:killall = "killall"
57
58ALTERNATIVE:fuser = "fuser"
59
60ALTERNATIVE:pstree = "pstree"