public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: x11-plugins/wmmon/files/, x11-plugins/wmmon/
@ 2016-01-04 12:57 Bernard Cafarelli
  0 siblings, 0 replies; 2+ messages in thread
From: Bernard Cafarelli @ 2016-01-04 12:57 UTC (permalink / raw
  To: gentoo-commits

commit:     fb9770ae922e6d105a7643102b3b805a93b5a39a
Author:     Bernard Cafarelli <voyageur <AT> gentoo <DOT> org>
AuthorDate: Mon Jan  4 12:38:55 2016 +0000
Commit:     Bernard Cafarelli <voyageur <AT> gentoo <DOT> org>
CommitDate: Mon Jan  4 12:56:48 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fb9770ae

x11-plugins/wmmon: fix compilation with gcc 5, bug #570212

Package-Manager: portage-2.2.26

 x11-plugins/wmmon/files/wmmon-1.2_beta1-list.patch | 127 +++++++++++++++++++++
 x11-plugins/wmmon/wmmon-1.2_beta1.ebuild           |   3 +-
 2 files changed, 129 insertions(+), 1 deletion(-)

diff --git a/x11-plugins/wmmon/files/wmmon-1.2_beta1-list.patch b/x11-plugins/wmmon/files/wmmon-1.2_beta1-list.patch
new file mode 100644
index 0000000..1b1ac31
--- /dev/null
+++ b/x11-plugins/wmmon/files/wmmon-1.2_beta1-list.patch
@@ -0,0 +1,127 @@
+diff -Naur wmgeneral.orig/list.c wmgeneral/list.c
+--- wmgeneral.orig/list.c	2016-01-04 13:28:36.583339716 +0100
++++ wmgeneral/list.c	2016-01-04 13:28:48.694343645 +0100
+@@ -38,7 +38,7 @@
+ 
+ /* Return a cons cell produced from (head . tail)
+ 
+-INLINE LinkedList* 
++LinkedList* 
+ list_cons(void* head, LinkedList* tail)
+ {
+   LinkedList* cell;
+@@ -51,7 +51,7 @@
+ 
+ /* Return the length of a list, list_length(NULL) returns zero
+ 
+-INLINE int
++int
+ list_length(LinkedList* list)
+ {
+   int i = 0;
+@@ -66,7 +66,7 @@
+ /* Return the Nth element of LIST, where N count from zero.  If N 
+    larger than the list length, NULL is returned 
+ 
+-INLINE void*
++void*
+ list_nth(int index, LinkedList* list)
+ {
+   while(index-- != 0)
+@@ -81,7 +81,7 @@
+ 
+ /* Remove the element at the head by replacing it by its successor
+ 
+-INLINE void
++void
+ list_remove_head(LinkedList** list)
+ {
+   if (!*list) return;  
+@@ -101,7 +101,7 @@
+ 
+ /* Remove the element with `car' set to ELEMENT
+ /*
+-INLINE void
++void
+ list_remove_elem(LinkedList** list, void* elem)
+ {
+   while (*list)
+@@ -112,7 +112,7 @@
+     }
+ 
+ 
+-INLINE LinkedList *
++LinkedList *
+ list_remove_elem(LinkedList* list, void* elem)
+ {
+     LinkedList *tmp;
+@@ -132,7 +132,7 @@
+ 
+ /* Return element that has ELEM as car
+ 
+-INLINE LinkedList*
++LinkedList*
+ list_find(LinkedList* list, void* elem)
+ {
+   while(list)
+@@ -146,7 +146,7 @@
+ 
+ /* Free list (backwards recursive)
+ 
+-INLINE void
++void
+ list_free(LinkedList* list)
+ {
+   if(list)
+@@ -158,7 +158,7 @@
+ 
+ /* Map FUNCTION over all elements in LIST
+ 
+-INLINE void
++void
+ list_mapcar(LinkedList* list, void(*function)(void*))
+ {
+   while(list)
+diff -Naur wmgeneral.orig/list.h wmgeneral/list.h
+--- wmgeneral.orig/list.h	2016-01-04 13:28:36.583339716 +0100
++++ wmgeneral/list.h	2016-01-04 13:28:39.471340654 +0100
+@@ -29,31 +29,25 @@
+ #ifndef __LIST_H_
+ #define __LIST_H_
+ 
+-#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
+-# define INLINE inline
+-#else
+-# define INLINE
+-#endif
+-
+ typedef struct LinkedList {
+   void *head;
+   struct LinkedList *tail;
+ } LinkedList;
+ 
+-INLINE LinkedList* list_cons(void* head, LinkedList* tail);
++LinkedList* list_cons(void* head, LinkedList* tail);
+ 
+-INLINE int list_length(LinkedList* list);
++int list_length(LinkedList* list);
+ 
+-INLINE void* list_nth(int index, LinkedList* list);
++void* list_nth(int index, LinkedList* list);
+ 
+-INLINE void list_remove_head(LinkedList** list);
++void list_remove_head(LinkedList** list);
+ 
+-INLINE LinkedList *list_remove_elem(LinkedList* list, void* elem);
++LinkedList *list_remove_elem(LinkedList* list, void* elem);
+ 
+-INLINE void list_mapcar(LinkedList* list, void(*function)(void*));
++void list_mapcar(LinkedList* list, void(*function)(void*));
+ 
+-INLINE LinkedList*list_find(LinkedList* list, void* elem);
++LinkedList*list_find(LinkedList* list, void* elem);
+ 
+-INLINE void list_free(LinkedList* list);
++void list_free(LinkedList* list);
+ 
+ #endif

diff --git a/x11-plugins/wmmon/wmmon-1.2_beta1.ebuild b/x11-plugins/wmmon/wmmon-1.2_beta1.ebuild
index c3ba34c..f099c9d 100644
--- a/x11-plugins/wmmon/wmmon-1.2_beta1.ebuild
+++ b/x11-plugins/wmmon/wmmon-1.2_beta1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2012 Gentoo Foundation
+# Copyright 1999-2016 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 
@@ -24,6 +24,7 @@ S=${WORKDIR}/${P/_beta/b}
 
 src_prepare() {
 	epatch "${FILESDIR}"/${P}-Makefile.patch
+	epatch "${FILESDIR}"/${P}-list.patch
 }
 
 src_compile() {


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: x11-plugins/wmmon/files/, x11-plugins/wmmon/
@ 2017-09-01 11:06 Bernard Cafarelli
  0 siblings, 0 replies; 2+ messages in thread
From: Bernard Cafarelli @ 2017-09-01 11:06 UTC (permalink / raw
  To: gentoo-commits

commit:     ef0014a3a61a08f82d57fdd951282244d2268909
Author:     Bernard Cafarelli <voyageur <AT> gentoo <DOT> org>
AuthorDate: Fri Sep  1 08:53:44 2017 +0000
Commit:     Bernard Cafarelli <voyageur <AT> gentoo <DOT> org>
CommitDate: Fri Sep  1 11:06:01 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ef0014a3

x11-plugins/wmmon: drop old

Package-Manager: Portage-2.3.8, Repoman-2.3.3

 x11-plugins/wmmon/Manifest                         |   1 -
 .../wmmon/files/wmmon-1.0_beta2-kernel26-v2.patch  | 207 ---------------------
 x11-plugins/wmmon/wmmon-1.0_beta2-r3.ebuild        |  39 ----
 3 files changed, 247 deletions(-)

diff --git a/x11-plugins/wmmon/Manifest b/x11-plugins/wmmon/Manifest
index 2f254388f72..0b275b9e8b8 100644
--- a/x11-plugins/wmmon/Manifest
+++ b/x11-plugins/wmmon/Manifest
@@ -1,2 +1 @@
 DIST wmmon-1.2b1.tar.bz2 25610 SHA256 5b203ec46fe13d5fdee51ec878cf1856704bf650a8f5458416b9cf4585e7cac2 SHA512 359ff4024cdc606d3520445d31b9e59c79a957b081bf46dfabde7c970aecab8d640f789f34c1599e18e15e50a077248e06600151d7c1e66ef028215d6d88ff1f WHIRLPOOL 88ce15d0ca14b0f47cb23faa01372530ec3194678b04cb3e18516da0d50c014704003284cd21e1e4afa466aa806bf766eefa9cee296d60df478402240ea67999
-DIST wmmon-1_0b2.tar.gz 21589 SHA256 0d34003747b36d47c1f6361675eee982d6eaf458b33f8cf4ecb157e87cdde9bf SHA512 47d0924d03185241077a59df009ee47f1361e7cb8dac08e687583d32d64691c96f9308ade9979818fbf8434857439d38eb759a858298f8d2e44388f3c09ea978 WHIRLPOOL 0925e8c87868a689216768779ca611fa83803915283dd99c8cd7ce46304d506ef6243a1b19afe55b09a9300e9dc8283f3ad4c7c53ca2c3b7191ba8c4ec466add

diff --git a/x11-plugins/wmmon/files/wmmon-1.0_beta2-kernel26-v2.patch b/x11-plugins/wmmon/files/wmmon-1.0_beta2-kernel26-v2.patch
deleted file mode 100644
index 38182bb2a90..00000000000
--- a/x11-plugins/wmmon/files/wmmon-1.0_beta2-kernel26-v2.patch
+++ /dev/null
@@ -1,207 +0,0 @@
-*** wmmon.c	Tue May 19 14:13:16 1998
---- wmmon.c.patched	Tue May 10 12:31:40 2005
-***************
-*** 101,107 ****
-  /********************/
-  
-  char	*ProgName;
-! int	stat_current = 0; /* now global */
-  FILE	*fp_meminfo;
-  FILE	*fp_stat;
-  FILE	*fp_loadavg;
---- 101,108 ----
-  /********************/
-  
-  char	*ProgName;
-! int	stat_current  = 0; /* now global */
-! int	minus_buffers = 1; /* do we want to subtract buffers and cache from memory usage? */
-  FILE	*fp_meminfo;
-  FILE	*fp_stat;
-  FILE	*fp_loadavg;
-*************** void main(int argc, char *argv[]) {
-*** 146,151 ****
---- 147,155 ----
-  			case 's' :
-  				stat_current = 2;
-  				break;
-+ 			case 'b' :
-+ 				minus_buffers = 0;
-+ 				break;
-  			default:
-  				usage();
-  				exit(0);
-*************** void DrawActive(char *);
-*** 188,194 ****
-  void update_stat_cpu(stat_dev *);
-  void update_stat_io(stat_dev *);
-  void update_stat_mem(stat_dev *st, stat_dev *st2);
-- void update_stat_swp(stat_dev *);
-  
-  void wmmon_routine(int argc, char **argv) {
-  
---- 192,197 ----
-*************** void wmmon_routine(int argc, char **argv
-*** 298,304 ****
-  
-  		if(stat_current == 2) {
-  			update_stat_mem(&stat_device[2], &stat_device[3]);
-- //			update_stat_swp(&stat_device[3]);
-  		}
-  
-  		if (stat_current < 2) {
---- 301,306 ----
-*************** void wmmon_routine(int argc, char **argv
-*** 320,341 ****
-  			copyXPMArea(0, 64, 32, 12, 28+64, 4);
-  			copyXPMArea(0, 64, 32, 12, 28+64, 18);
-  
-! 			j = stat_device[2].rt_idle;
-! 			if (j != 0) {
-! 				j = (stat_device[2].rt_stat * 100) / j;
-! 			}
-! 			j = j * 0.32;
-! 			if (j > 32) j = 32;
-! 			copyXPMArea(32, 64, j, 12, 28+64, 4);
-! 			/*---------------------           ------------------*/
-! 			j = stat_device[3].rt_idle;
-! 			if (j != 0) {
-! 				j = (stat_device[3].rt_stat * 100) / j;
-  			}
-- 			j = j * 0.32;
-- 			if (j > 32) j = 32;
-- 			copyXPMArea(32, 64, j, 12, 28+64, 18);
-- 
-  			/*----------- online tijd neerzetten! ----------*/
-  			
-  			cnt_time = time(0) - ref_time + online_time;
---- 322,335 ----
-  			copyXPMArea(0, 64, 32, 12, 28+64, 4);
-  			copyXPMArea(0, 64, 32, 12, 28+64, 18);
-  
-! 			for (i = 2; i <= 3; i++) {
-! 				j = stat_device[i].rt_stat != 0
-! 					? 100 * ( stat_device[i].rt_stat - stat_device[i].rt_idle ) / stat_device[i].rt_stat
-! 					: 0 ;
-! 				j = j * 0.32;
-! 				if (j > 32) j = 32;
-! 				copyXPMArea(32, 64, j, 12, 28+64, 4+(14*(i-2)) );
-  			}
-  			/*----------- online tijd neerzetten! ----------*/
-  			
-  			cnt_time = time(0) - ref_time + online_time;
-*************** void wmmon_routine(int argc, char **argv
-*** 430,436 ****
-  						}
-  					case 1:
-  						stat_current++;
-- 						printf("current stat is :%d\n", stat_current);
-  						if (stat_current == stat_online)
-  							stat_current = 0;
-  
---- 424,429 ----
-*************** void update_stat_io(stat_dev *st) {
-*** 499,541 ****
-  
-  void update_stat_mem(stat_dev *st, stat_dev *st2) {
-  
-! 	char	temp[128];
-! 	unsigned long free, shared, buffers, cached;
-  
-  	freopen("/proc/meminfo", "r", fp_meminfo);
-  	while (fgets(temp, 128, fp_meminfo)) {
-! 		if (strstr(temp, "Mem:")) {
-! 			sscanf(temp, "Mem: %ld %ld %ld %ld %ld %ld",
-! 			       &st->rt_idle, &st->rt_stat,
-! 			       &free, &shared, &buffers, &cached);
-! 			st->rt_idle >>= 10;
-! 			st->rt_stat -= buffers+cached;
-! 			st->rt_stat >>= 10;
-! //			break;
-  		}
-! 		if (strstr(temp, "Swap:")) {
-! 			sscanf(temp, "Swap: %ld %ld", &st2->rt_idle, &st2->rt_stat);
-! 			st2->rt_idle >>= 10;
-! 			st2->rt_stat >>= 10;
-! 			break;
-  		}
-! 	}
-! }
-! 
-! void update_stat_swp(stat_dev *st) {
-! 
-! 	char	temp[128];
-! 
-! 	fseek(fp_meminfo, 0, SEEK_SET);
-! 	while (fgets(temp, 128, fp_meminfo)) {
-! 		if (strstr(temp, "Swap:")) {
-! 			sscanf(temp, "Swap: %ld %ld", &st->rt_idle, &st->rt_stat);
-! 			st->rt_idle >>= 10;
-! 			st->rt_stat >>= 10;
-! 			break;
-  		}
-  	}
-- 
-  }
-  
-  /*******************************************************************************\
---- 492,523 ----
-  
-  void update_stat_mem(stat_dev *st, stat_dev *st2) {
-  
-! 	char     temp[128], stat[20];
-! 	unsigned long amount;
-  
-  	freopen("/proc/meminfo", "r", fp_meminfo);
-+ 	st->rt_idle = 0; /* zero this out so we can +/- appropriately */
-  	while (fgets(temp, 128, fp_meminfo)) {
-! 		sscanf(temp, "%s %ld", &stat, &amount);
-! 		if      (! strcmp(stat, "MemFree:")  ) {
-! 			st->rt_idle  += (amount >> 10);
-  		}
-! 		else if (! strcmp(stat, "MemTotal:")   ) {
-! 			st->rt_stat  = (amount >> 10);
-  		}
-! 		else if (! strcmp(stat, "Buffers:") && minus_buffers ) {
-! 			st->rt_idle  += (amount >> 10);
-! 		}
-! 		else if (! strcmp(stat, "Cached:")  && minus_buffers ) {
-! 			st->rt_idle  += (amount >> 10);
-! 		}
-! 		else if (! strcmp(stat, "SwapFree:") ) {
-! 			st2->rt_idle = (amount >> 10);
-! 		}
-! 		else if (! strcmp(stat, "SwapTotal:")  ) {
-! 			st2->rt_stat = (amount >> 10);
-  		}
-  	}
-  }
-  
-  /*******************************************************************************\
-*************** int checksysdevs(void) {
-*** 599,605 ****
-  
-  	strcpy(stat_device[0].name, "cpu0");
-  	strcpy(stat_device[1].name, "i/o");
-! 	strcpy(stat_device[2].name, "sys");
-  
-  	return 3;
-  }
---- 581,588 ----
-  
-  	strcpy(stat_device[0].name, "cpu0");
-  	strcpy(stat_device[1].name, "i/o");
-! 	strcpy(stat_device[2].name, "mem");
-! 	strcpy(stat_device[3].name, "swap");
-  
-  	return 3;
-  }
-*************** void usage(void) {
-*** 724,729 ****
---- 707,713 ----
-  	fprintf(stderr, "\t-v\tprint the version number\n");
-  	fprintf(stderr, "\t-i\tstartup in DiskIO mode\n");
-  	fprintf(stderr, "\t-s\tstartup in SysInfo mode\n");
-+ 	fprintf(stderr, "\t-b\tdo not subtract buffer and cache from memory usage\n");
-  	fprintf(stderr, "\n");
-  }
-  

diff --git a/x11-plugins/wmmon/wmmon-1.0_beta2-r3.ebuild b/x11-plugins/wmmon/wmmon-1.0_beta2-r3.ebuild
deleted file mode 100644
index ab715a85115..00000000000
--- a/x11-plugins/wmmon/wmmon-1.0_beta2-r3.ebuild
+++ /dev/null
@@ -1,39 +0,0 @@
-# Copyright 1999-2010 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-inherit eutils
-
-S=${WORKDIR}/${PN}.app
-IUSE=""
-DESCRIPTION="Dockable system resources monitor applet for WindowMaker"
-WMMON_VERSION=1_0b2
-SRC_URI="http://rpig.dyndns.org/~anstinus/Linux/${PN}-${WMMON_VERSION}.tar.gz"
-HOMEPAGE="http://www.bensinclair.com/dockapp/"
-
-RDEPEND="x11-libs/libX11
-	x11-libs/libXext
-	x11-libs/libXpm"
-DEPEND="${RDEPEND}
-	x11-proto/xextproto
-	>=sys-apps/sed-4"
-
-SLOT="0"
-LICENSE="GPL-2"
-KEYWORDS="amd64 ~ppc sparc x86"
-
-src_unpack() {
-	unpack ${A}
-	cd "${S}"/${PN}
-	epatch "${FILESDIR}"/${P}-kernel26-v2.patch
-	sed -i -e "s|-O2|${CFLAGS}|" Makefile
-	sed -i -e "s|cc -o wmmon|cc ${LDFLAGS} -o wmmon|" Makefile
-}
-
-src_compile() {
-	emake -C ${PN} || die
-}
-
-src_install () {
-	dobin wmmon/wmmon
-	dodoc BUGS CHANGES HINTS README TODO
-}


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-09-01 11:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-04 12:57 [gentoo-commits] repo/gentoo:master commit in: x11-plugins/wmmon/files/, x11-plugins/wmmon/ Bernard Cafarelli
  -- strict thread matches above, loose matches on Subject: below --
2017-09-01 11:06 Bernard Cafarelli

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox