diff options
author | 2020-02-19 10:25:13 +0100 | |
---|---|---|
committer | 2020-02-19 10:25:13 +0100 | |
commit | 728aea32ee3ff554d6c5b1f310bee7a49111b78a (patch) | |
tree | c2dd6d4b49d76ec22b7320aaae9b677dbd4ed4cf /x11-plugins | |
parent | Whoops, fix D3 ebuild (diff) | |
download | haarp-728aea32ee3ff554d6c5b1f310bee7a49111b78a.tar.gz haarp-728aea32ee3ff554d6c5b1f310bee7a49111b78a.tar.bz2 haarp-728aea32ee3ff554d6c5b1f310bee7a49111b78a.zip |
Update multiload-ng and fix NVMe/DM support
Signed-off-by: haarp <main.haarp@gmail.com>
Diffstat (limited to 'x11-plugins')
-rw-r--r-- | x11-plugins/multiload-ng/Manifest | 9 | ||||
-rw-r--r-- | x11-plugins/multiload-ng/files/fix-sysfs-nvme-dm.patch | 115 | ||||
-rw-r--r-- | x11-plugins/multiload-ng/metadata.xml | 5 | ||||
l---------[-rw-r--r--] | x11-plugins/multiload-ng/multiload-ng-1.5.2.ebuild | 93 | ||||
-rw-r--r-- | x11-plugins/multiload-ng/multiload-ng-9999.ebuild | 9 |
5 files changed, 126 insertions, 105 deletions
diff --git a/x11-plugins/multiload-ng/Manifest b/x11-plugins/multiload-ng/Manifest index f7082b2..4a7cfab 100644 --- a/x11-plugins/multiload-ng/Manifest +++ b/x11-plugins/multiload-ng/Manifest @@ -1,4 +1,5 @@ -DIST multiload-ng-1.5.2.tar.gz 183474 SHA256 ea77b84dc998c815f413a59d7e1461072abc19d97b64db6a0df4514fdc492d4a SHA512 648e14fab39a80cdffadf41fab335b946dd115b1a565e16a44a95c3121eaf3d93bec37c6b41db84a11669530500a4b1088dc6fdbcb18900ea995499b77e54140 WHIRLPOOL d90b51cca8eba2a64303b117daf2621356fdcd797d02239818b1124df1993edcfd6a99f23c2fd2f960181c98a76d8c3d486efaae6ae15d087fb0bfa86683b7fc -EBUILD multiload-ng-1.5.2.ebuild 1978 SHA256 0d4eff6aec059f58ee963c2a79edc6301c1c4ffa637f05dcf4396387e312c84a SHA512 9b3774ec0c6826af2da33f036b21a35c9dac438f4bb035024854cd8ea909e32297e6c4118a2d6c5eb41ce0ee64ab5cdccaec54f44160f3210711be41b2c393cc WHIRLPOOL 1f2fe9eeda7f7e9e222e3b92ec2d4117aa7c7f852dd5ccb90870ba732e7a2fdf1acc0533972d164383a34dec17e17a46f6d10f59e0b6ba6df36bbf9b8de021cc -EBUILD multiload-ng-9999.ebuild 1978 SHA256 0d4eff6aec059f58ee963c2a79edc6301c1c4ffa637f05dcf4396387e312c84a SHA512 9b3774ec0c6826af2da33f036b21a35c9dac438f4bb035024854cd8ea909e32297e6c4118a2d6c5eb41ce0ee64ab5cdccaec54f44160f3210711be41b2c393cc WHIRLPOOL 1f2fe9eeda7f7e9e222e3b92ec2d4117aa7c7f852dd5ccb90870ba732e7a2fdf1acc0533972d164383a34dec17e17a46f6d10f59e0b6ba6df36bbf9b8de021cc -MISC metadata.xml 2029 SHA256 f632f65b536ad14ba0ca9274dc3668038689cebceaf1fa2567ef805032b59c95 SHA512 06c6ad84ab0139bcc201d3a1bdf13f30cc09d407a7d331c47d54abfd1fce5cc683f55e893efacd5f8f84d2f2efd0f40429e6875d9db883f67aacb8f1986aa9ec WHIRLPOOL e7000b2ab5b2a844fe1f61143a3b64205e3053b27ec9a6e95689ef19d5ec0f04c57f2339d4a6b13c6083b6d90b9e0b6411c93cfe3d7cade991257c95158aa8b0 +AUX fix-sysfs-nvme-dm.patch 3562 BLAKE2B 160e6cb24b88207c5ac269b59076d5020bb5a3d83495b67ca43bb693d1e286e643903df2c7b25d205149291a05da3c25c092485bbebed82e8ea7523125a33018 SHA512 1f1c914f1704cfd6fa07d998e4b694fbe49fa567d4f0f99f9a33441121ba3def324acee854b6c560493640589d2eff960f49b9166346c768f9f856a604dc74c1 +DIST multiload-ng-1.5.2.tar.gz 183474 BLAKE2B 7614b0337f26316ca08c7b3218af28b65685e4a784b5922ebee4b1f5b66ea79f5ad6e05f6b1ecd6d495e32379f7bba41502ba496d5afb41ed9a68d1d16c2132b SHA512 648e14fab39a80cdffadf41fab335b946dd115b1a565e16a44a95c3121eaf3d93bec37c6b41db84a11669530500a4b1088dc6fdbcb18900ea995499b77e54140 +EBUILD multiload-ng-1.5.2.ebuild 2021 BLAKE2B 9f27fea24f0ec132c001e4d56038bbe2f8191296f6af7e05ffbd178c2a43212cfd53ce8f728b98d5f685b4a2e630902905f9d8132de37cc39175955c825c1c34 SHA512 f7814cd1d984ac9551bb92045f96051db1270da9b74a0a2a7c26ddd5a60f16881c25dfdac11c9f5fbf4cdce36ab282cc9ea161b44495f7606e643fb53920c52b +EBUILD multiload-ng-9999.ebuild 2021 BLAKE2B 9f27fea24f0ec132c001e4d56038bbe2f8191296f6af7e05ffbd178c2a43212cfd53ce8f728b98d5f685b4a2e630902905f9d8132de37cc39175955c825c1c34 SHA512 f7814cd1d984ac9551bb92045f96051db1270da9b74a0a2a7c26ddd5a60f16881c25dfdac11c9f5fbf4cdce36ab282cc9ea161b44495f7606e643fb53920c52b +MISC metadata.xml 1849 BLAKE2B ef267417c2342f42faf5f85266277abca6c8942175cfc1a2ee33795a86ee02f6bc1169cb6cc86f796bbf2c24567f851b0804169ece7f54934e4f22823063cd00 SHA512 85df7f37729020430d8609cf56247fee924c477779c6b535db9ab9e861d928b9a5820515a2d1003cbbe81f8f4e77a50e2e42dcfe37990784a2c301ba0d97079b diff --git a/x11-plugins/multiload-ng/files/fix-sysfs-nvme-dm.patch b/x11-plugins/multiload-ng/files/fix-sysfs-nvme-dm.patch new file mode 100644 index 0000000..c4b3b60 --- /dev/null +++ b/x11-plugins/multiload-ng/files/fix-sysfs-nvme-dm.patch @@ -0,0 +1,115 @@ +https://github.com/udda/multiload-ng/pull/63 + +From adc0d5ec53b4a8bc16da1234eff708db72b007a8 Mon Sep 17 00:00:00 2001 +From: James Nylen <jnylen@gmail.com> +Date: Tue, 24 Apr 2018 23:18:05 -0500 +Subject: [PATCH] Fix sysfs path detection for /dev/nvme* and /dev/dm-* + +--- + common/graph-data.h | 2 ++ + common/graph-disk.c | 57 ++++++++++++++++++++++++++++++--------------- + 2 files changed, 40 insertions(+), 19 deletions(-) + +diff --git a/common/graph-data.h b/common/graph-data.h +index fcf3082..c5320a6 100644 +--- a/common/graph-data.h ++++ b/common/graph-data.h +@@ -157,6 +157,8 @@ multiload_graph_load_cmdline_output (LoadGraph *g, LoadData *xd); + G_GNUC_INTERNAL void + multiload_graph_load_tooltip_update (char *buf_title, size_t len_title, char *buf_text, size_t len_text, LoadGraph *g, LoadData *xd, gint style); + ++G_GNUC_INTERNAL gboolean ++multiload_graph_disk_device_is_partition (char *device, char *prefix, size_t sizeof_prefix); + G_GNUC_INTERNAL MultiloadFilter * + multiload_graph_disk_get_filter (LoadGraph *g, DiskData *xd); + G_GNUC_INTERNAL void +diff --git a/common/graph-disk.c b/common/graph-disk.c +index 9a7405a..885971b 100644 +--- a/common/graph-disk.c ++++ b/common/graph-disk.c +@@ -35,6 +35,42 @@ + + static const char *fstype_ignore_list[] = { "rootfs", "smbfs", "nfs", "cifs", "fuse.", NULL }; + ++gboolean ++multiload_graph_disk_device_is_partition (char *device, char *prefix, size_t sizeof_prefix) { ++ gboolean is_partition = FALSE; ++ guint i; ++ g_strlcpy(prefix, device, sizeof_prefix); ++ ++ if (strncmp (prefix, "nvme", 4) == 0) { ++ // several possibilities: ++ // - nvme0 ++ // - nvme0n1 ++ // - nvme0n1p1 ++ // only the last one is a partition, with sysfs subfolder nvme0n1 ++ for (i=4; prefix[i] != '\0'; i++) { ++ if (isdigit(prefix[i]) && prefix[i-1] == 'p') { ++ prefix[i-1] = '\0'; ++ is_partition = TRUE; ++ break; ++ } ++ } ++ return is_partition; ++ } ++ ++ if (strncmp (prefix, "dm-", 3) == 0) { ++ // device-mapper devices do not show up in a sysfs subfolder ++ return FALSE; ++ } ++ ++ for (i=0; prefix[i] != '\0'; i++) { ++ if (isdigit(prefix[i])) { ++ prefix[i] = '\0'; ++ is_partition = TRUE; ++ break; ++ } ++ } ++ return is_partition; ++} + + MultiloadFilter * + multiload_graph_disk_get_filter (LoadGraph *g, DiskData *xd) +@@ -44,7 +80,6 @@ multiload_graph_disk_get_filter (LoadGraph *g, DiskData *xd) + + guint64 blocks; + char device[20], prefix[20], label[30]; +- guint i; + + MultiloadFilter *filter = multiload_filter_new(); + +@@ -55,15 +90,7 @@ multiload_graph_disk_get_filter (LoadGraph *g, DiskData *xd) + continue; + + // extract block device and partition names +- gboolean is_partition = FALSE; +- g_strlcpy(prefix, device, sizeof(prefix)); +- for (i=0; prefix[i] != '\0'; i++) { +- if (isdigit(prefix[i])) { +- prefix[i] = '\0'; +- is_partition = TRUE; +- break; +- } +- } ++ gboolean is_partition = multiload_graph_disk_device_is_partition(device, prefix, sizeof(prefix)); + + // generate sysfs path + char sysfs_path[PATH_MAX]; +@@ -133,16 +160,8 @@ multiload_graph_disk_get_data (int Maximum, int data [2], LoadGraph *g, DiskData + continue; + + // extract block device and partition names +- gboolean is_partition = FALSE; + device = &mnt->mnt_fsname[5]; +- g_strlcpy(prefix, device, sizeof(prefix)); +- for (i=0; prefix[i] != '\0'; i++) { +- if (isdigit(prefix[i])) { +- prefix[i] = '\0'; +- is_partition = TRUE; +- break; +- } +- } ++ gboolean is_partition = multiload_graph_disk_device_is_partition(device, prefix, sizeof(prefix)); + + // filter + if (g->config->filter_enable) { diff --git a/x11-plugins/multiload-ng/metadata.xml b/x11-plugins/multiload-ng/metadata.xml index 788107a..1cf1c24 100644 --- a/x11-plugins/multiload-ng/metadata.xml +++ b/x11-plugins/multiload-ng/metadata.xml @@ -1,11 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> <pkgmetadata> - <maintainer type="person" status="active"> - <email>mr.udda@gmail.com</email> - <name>Mario Cianciolo</name> - <description>Developer of Multiload-ng</description> - </maintainer> <longdescription> Multiload-ng is a modern graphical system monitor. It's a near-complete rewrite of the good old GNOME multiload applet. diff --git a/x11-plugins/multiload-ng/multiload-ng-1.5.2.ebuild b/x11-plugins/multiload-ng/multiload-ng-1.5.2.ebuild index 8cab131..01033f4 100644..120000 --- a/x11-plugins/multiload-ng/multiload-ng-1.5.2.ebuild +++ b/x11-plugins/multiload-ng/multiload-ng-1.5.2.ebuild @@ -1,92 +1 @@ -# Copyright 1999-2017 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 -inherit autotools eutils - -DESCRIPTION="Modern graphical system monitor for XFCE/MATE/LXDE (GNOME applet fork)" -HOMEPAGE="https://udda.github.io/multiload-ng/" - -if [[ ${PV} == 9999 ]]; then - inherit git-r3 - EGIT_REPO_URI="https://github.com/udda/multiload-ng.git" - KEYWORDS="" -else - SRC_URI="https://github.com/udda/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" - KEYWORDS="~amd64 ~x86" -fi - -LICENSE="GPL-2" -SLOT="0" -IUSE="autostart awn debug gtk2 +gtk3 indicator lxde mate +standalone systray xfce" - -LANGS=" de es fr it lt ru zh_CN" -IUSE="${IUSE} ${LANGS// / linguas_}" - -RDEPEND=" - gtk2? ( >=x11-libs/gtk+-2.20:2 ) - gtk3? ( x11-libs/gtk+:3 ) - x11-libs/cairo:= - awn? ( - >=gnome-extra/avant-window-navigator-0.3.9 - >=dev-cpp/glibmm-2.16.0:2 - >=dev-cpp/gtkmm-2.20:2.4 - ) - indicator? ( - gtk2? ( >=dev-libs/libappindicator-0.4.92:2 ) - gtk3? ( >=dev-libs/libappindicator-0.4.92:3 ) - ) - lxde? ( - >=lxde-base/lxpanel-0.5.8 - ) - mate? ( - gtk2? ( >=mate-base/mate-panel-1.7.0 ) - gtk3? ( >=mate-base/mate-panel-1.7.0[gtk3(-)] ) - ) - xfce? ( - gtk2? ( - >=xfce-base/libxfce4util-4.6.0 - >=xfce-base/xfce4-panel-4.6.0 - ) - gtk3? ( - >=xfce-base/libxfce4util-4.12.0 - >=xfce-base/xfce4-panel-4.12.0 - ) - )" - -DEPEND="${RDEPEND} - dev-util/intltool - sys-devel/gettext - virtual/pkgconfig" - -REQUIRED_USE=" - ^^ ( gtk2 gtk3 ) - || ( awn indicator lxde mate standalone systray xfce ) - awn? ( gtk2 )" - -DOCS=( AUTHORS Changelog.md CONTRIBUTING.md README.md ) - -src_prepare() { - eautoreconf - - eapply_user -} - -src_configure() { - if use gtk2; then - GTK_CONF="--with-gtk=2.0" - else - GTK_CONF="--with-gtk=3.0 --disable-deprecations" - fi - econf \ - $(use_enable debug) \ - $(use_enable autostart) \ - $GTK_CONF \ - $(use_with standalone) \ - $(use_with awn) \ - $(use_with indicator) \ - $(use_with lxde lxpanel) \ - $(use_with mate) \ - $(use_with systray) \ - $(use_with xfce xfce4) -} +multiload-ng-9999.ebuild
\ No newline at end of file diff --git a/x11-plugins/multiload-ng/multiload-ng-9999.ebuild b/x11-plugins/multiload-ng/multiload-ng-9999.ebuild index 8cab131..33e1c2c 100644 --- a/x11-plugins/multiload-ng/multiload-ng-9999.ebuild +++ b/x11-plugins/multiload-ng/multiload-ng-9999.ebuild @@ -1,7 +1,7 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2020 Gentoo authors # Distributed under the terms of the GNU General Public License v2 -EAPI=6 +EAPI=7 inherit autotools eutils DESCRIPTION="Modern graphical system monitor for XFCE/MATE/LXDE (GNOME applet fork)" @@ -67,9 +67,10 @@ REQUIRED_USE=" DOCS=( AUTHORS Changelog.md CONTRIBUTING.md README.md ) src_prepare() { - eautoreconf - + eapply "${FILESDIR}/fix-sysfs-nvme-dm.patch" eapply_user + + eautoreconf } src_configure() { |