summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBernard Cafarelli <voyageur@gentoo.org>2010-06-29 09:53:56 +0000
committerBernard Cafarelli <voyageur@gentoo.org>2010-06-29 09:53:56 +0000
commit9253bf456448962a911c4729d4b7fa6e7bcc31ef (patch)
treeb51f50ded8a1cefac5f7fa135518489c4e8e313d /x11-plugins/wmhdplop
parentRemoving me as a mantainer (diff)
downloadgentoo-2-9253bf456448962a911c4729d4b7fa6e7bcc31ef.tar.gz
gentoo-2-9253bf456448962a911c4729d4b7fa6e7bcc31ef.tar.bz2
gentoo-2-9253bf456448962a911c4729d4b7fa6e7bcc31ef.zip
Fix dockapp neeeding a restart after a long time, patch by Mikael Magnusson <mikachu@gmail.com> in bug #325615
(Portage version: 2.2_rc67/cvs/Linux x86_64)
Diffstat (limited to 'x11-plugins/wmhdplop')
-rw-r--r--x11-plugins/wmhdplop/ChangeLog11
-rw-r--r--x11-plugins/wmhdplop/files/wmhdplop-0.9.9-64bit.patch94
-rw-r--r--x11-plugins/wmhdplop/wmhdplop-0.9.9-r1.ebuild43
3 files changed, 146 insertions, 2 deletions
diff --git a/x11-plugins/wmhdplop/ChangeLog b/x11-plugins/wmhdplop/ChangeLog
index f5434ce29070..8910a0eacfe1 100644
--- a/x11-plugins/wmhdplop/ChangeLog
+++ b/x11-plugins/wmhdplop/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for x11-plugins/wmhdplop
-# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/x11-plugins/wmhdplop/ChangeLog,v 1.16 2009/08/16 08:47:55 betelgeuse Exp $
+# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/x11-plugins/wmhdplop/ChangeLog,v 1.17 2010/06/29 09:53:56 voyageur Exp $
+
+*wmhdplop-0.9.9-r1 (29 Jun 2010)
+
+ 29 Jun 2010; Bernard Cafarelli <voyageur@gentoo.org>
+ +wmhdplop-0.9.9-r1.ebuild, +files/wmhdplop-0.9.9-64bit.patch:
+ Fix dockapp neeeding a restart after a long time, patch by Mikael
+ Magnusson <mikachu@gmail.com> in bug #325615
16 Aug 2009; Petteri Räty <betelgeuse@gentoo.org> wmhdplop-0.9.9.ebuild:
Migrate to EAPI 2 in order to get rid of built_with_use for bug #261562.
diff --git a/x11-plugins/wmhdplop/files/wmhdplop-0.9.9-64bit.patch b/x11-plugins/wmhdplop/files/wmhdplop-0.9.9-64bit.patch
new file mode 100644
index 000000000000..13650e9bb7d9
--- /dev/null
+++ b/x11-plugins/wmhdplop/files/wmhdplop-0.9.9-64bit.patch
@@ -0,0 +1,94 @@
+diff -pudr wmhdplop-0.9.9/devnames.h wmhdplop-0.9.9-fixed/devnames.h
+--- wmhdplop-0.9.9/devnames.h 2004-04-07 01:14:01.000000000 +0200
++++ wmhdplop-0.9.9-fixed/devnames.h 2010-06-25 21:56:10.662190796 +0200
+@@ -9,7 +9,7 @@ typedef struct DiskList {
+ unsigned major, minor;
+ int hd_id, part_id; /* part_id = 0 for disks */
+ int enable_hddtemp;
+- int nr, nw, touched_r, touched_w;
++ long nr, nw, touched_r, touched_w;
+ struct DiskList *next;
+ } DiskList;
+
+diff -pudr wmhdplop-0.9.9/procstat.c wmhdplop-0.9.9-fixed/procstat.c
+--- wmhdplop-0.9.9/procstat.c 2007-04-20 11:12:16.000000000 +0200
++++ wmhdplop-0.9.9-fixed/procstat.c 2010-06-25 21:55:37.086191145 +0200
+@@ -8,7 +8,7 @@
+ static ProcStats ps;
+ int use_proc_diskstats;
+
+-void pstat_init(struct pstat *pst, int nslice, float update_interval) {
++void pstat_init(struct pstat *pst, long nslice, float update_interval) {
+ pst->nslice = nslice;
+ ALLOC_VEC(pst->slices, nslice);
+ pst->cur_slice = 0;
+@@ -17,7 +17,7 @@ void pstat_init(struct pstat *pst, int n
+ }
+
+ float pstat_current(struct pstat *pst) {
+- int idx = pst->cur_slice ? pst->cur_slice-1 : pst->nslice-1;
++ long idx = pst->cur_slice ? pst->cur_slice-1 : pst->nslice-1;
+ return pst->slices[idx]/pst->update_interval;
+ }
+
+@@ -101,13 +101,13 @@ void update_stats() {
+ if (!Prefs.debug_disk_rd) {
+ pstat_add(&ps.disk_read, nr);
+ } else {
+- static int cntr = 0; cntr+=(rand()%30) == 0 ? Prefs.debug_disk_rd : 0;
++ static long cntr = 0; cntr+=(rand()%30) == 0 ? Prefs.debug_disk_rd : 0;
+ pstat_add(&ps.disk_read, nr + cntr);
+ }
+ if (!Prefs.debug_disk_wr) {
+ pstat_add(&ps.disk_write, nw);
+ } else {
+- static int cntw = 0; cntw+=(rand()%30) == 0 ? Prefs.debug_disk_wr : 0;
++ static long cntw = 0; cntw+=(rand()%30) == 0 ? Prefs.debug_disk_wr : 0;
+ pstat_add(&ps.disk_write, nw + cntw);
+ }
+ readok = 2;
+@@ -121,7 +121,7 @@ void update_stats() {
+ pstat_add(&ps.swap_in, nr);
+ pstat_add(&ps.swap_out, nw);
+ } else {
+- static int cnt = 0; cnt+=Prefs.debug_swapio;
++ static long cnt = 0; cnt+=Prefs.debug_swapio;
+ pstat_add(&ps.swap_in, nr + cnt);
+ pstat_add(&ps.swap_out, nw + cnt);
+ }
+@@ -144,10 +144,10 @@ void init_stats(float update_interval) {
+ char s[512];
+ FILE *f;
+
+- pstat_init(&ps.swap_in, (int)(0.5/update_interval)+1, update_interval);
+- pstat_init(&ps.swap_out, (int)(0.5/update_interval)+1, update_interval);
+- pstat_init(&ps.disk_read, (int)(0.5/update_interval)+1, update_interval);
+- pstat_init(&ps.disk_write, (int)(0.5/update_interval)+1, update_interval);
++ pstat_init(&ps.swap_in, (long)(0.5/update_interval)+1, update_interval);
++ pstat_init(&ps.swap_out, (long)(0.5/update_interval)+1, update_interval);
++ pstat_init(&ps.disk_read, (long)(0.5/update_interval)+1, update_interval);
++ pstat_init(&ps.disk_write, (long)(0.5/update_interval)+1, update_interval);
+ f = fopen("/proc/swaps","r");
+ //if (!f) { perror("/proc/swaps"); exit(1); }
+ if (f) {
+diff -pudr wmhdplop-0.9.9/procstat.h wmhdplop-0.9.9-fixed/procstat.h
+--- wmhdplop-0.9.9/procstat.h 2004-03-14 12:07:15.000000000 +0100
++++ wmhdplop-0.9.9-fixed/procstat.h 2010-06-25 21:45:52.146334994 +0200
+@@ -4,7 +4,7 @@
+
+ struct pstat {
+ unsigned long total;
+- int nslice, cur_slice;
++ long nslice, cur_slice;
+ unsigned long *slices;
+ float update_interval;
+ };
+@@ -15,7 +15,7 @@ typedef struct {
+ struct pstat disk_read, disk_write;
+ } ProcStats;
+
+-void pstat_init(struct pstat *pst, int nslice, float update_interval);
++void pstat_init(struct pstat *pst, long nslice, float update_interval);
+ float pstat_current(struct pstat *pst);
+ void pstat_add(struct pstat *pst, unsigned long v);
+ void pstat_advance(struct pstat *pst);
diff --git a/x11-plugins/wmhdplop/wmhdplop-0.9.9-r1.ebuild b/x11-plugins/wmhdplop/wmhdplop-0.9.9-r1.ebuild
new file mode 100644
index 000000000000..a999dce31624
--- /dev/null
+++ b/x11-plugins/wmhdplop/wmhdplop-0.9.9-r1.ebuild
@@ -0,0 +1,43 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/x11-plugins/wmhdplop/wmhdplop-0.9.9-r1.ebuild,v 1.1 2010/06/29 09:53:56 voyageur Exp $
+
+EAPI="2"
+
+inherit eutils multilib
+
+DESCRIPTION="a dockapp for monitoring disk activities with fancy visuals."
+HOMEPAGE="http://hules.free.fr/wmhdplop"
+SRC_URI="http://hules.free.fr/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86"
+IUSE="gkrellm"
+
+RDEPEND="media-libs/imlib2[X]
+ x11-libs/libX11
+ x11-libs/libXext
+ media-fonts/corefonts
+ >=media-libs/freetype-2"
+DEPEND="${RDEPEND}
+ x11-proto/xextproto
+ gkrellm? ( dev-util/pkgconfig
+ >=app-admin/gkrellm-2 )"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-64bit.patch
+ sed -i -e "s:-O3 -fomit-frame-pointer -ffast-math:${CFLAGS}:" "${S}"/configure
+}
+
+src_configure() {
+ econf $(use_enable gkrellm)
+}
+
+src_install() {
+ emake DESTDIR="${D}" install || die "emake install failed."
+ dodoc AUTHORS ChangeLog NEWS README || die
+
+ insinto /usr/$(get_libdir)/gkrellm2/plugins
+ use gkrellm && doins gkhdplop.so
+}