ports/96369: [patch] misc/gkrellmbgchg2 (build fix)
Martin Wilke
freebsd at unixfreunde.de
Wed Apr 26 16:50:16 UTC 2006
>Number: 96369
>Category: ports
>Synopsis: [patch] misc/gkrellmbgchg2 (build fix)
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: maintainer-update
>Submitter-Id: current-users
>Arrival-Date: Wed Apr 26 16:50:14 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator: Martin Wilke
>Release: FreeBSD 7.0-CURRENT i386
>Organization:
>Environment:
System: FreeBSD 7.0-CURRENT #135: Thu Apr 20 17:57:52 CEST 2006
root at mwilke.ath.cx:/usr/obj/usr/src/sys/BSDBOX
>Description:
- this patch fixes the build problem under Freebsd 4.X
- Thx Andreas Kohn for help.
>How-To-Repeat:
>Fix:
--- gkrellmbgchg2.diff begins here ---
diff -ruN /usr/ports/misc/gkrellmbgchg2/Makefile ports/misc/gkrellmbgchg2/Makefile
--- /usr/ports/misc/gkrellmbgchg2/Makefile Wed Apr 26 18:36:06 2006
+++ ports/misc/gkrellmbgchg2/Makefile Wed Apr 26 18:39:42 2006
@@ -23,10 +23,6 @@
.include <bsd.port.pre.mk>
-.if ${OSVERSION} < 500000
-BROKEN= Does not compile
-.endif
-
post-patch:
@${REINPLACE_CMD} -e 's|-O3||g' ${WRKSRC}/Makefile
diff -ruN /usr/ports/misc/gkrellmbgchg2/files/patch-gkrellmbgchg.c ports/misc/gkrellmbgchg2/files/patch-gkrellmbgchg.c
--- /usr/ports/misc/gkrellmbgchg2/files/patch-gkrellmbgchg.c Thu Jan 1 01:00:00 1970
+++ ports/misc/gkrellmbgchg2/files/patch-gkrellmbgchg.c Wed Apr 26 17:54:18 2006
@@ -0,0 +1,39 @@
+--- gkrellmbgchg.c.orig Wed Apr 26 17:41:54 2006
++++ gkrellmbgchg.c Wed Apr 26 17:54:17 2006
+@@ -114,7 +114,9 @@
+ {
+ FILE *file;
+ gchar *tmp;
+-
++#if !defined(WIN32)
++ struct stat buf;
++#endif
+ if( filename ) {
+ if( !strncmp( filename, "~/", MIN(2, strlen(filename)) ) )
+ tmp = g_strdup_printf( "%s/%s", g_get_home_dir(), filename+2 );
+@@ -125,7 +127,6 @@
+
+ #if !defined(WIN32)
+ /* don't load if no force and not modified */
+- struct stat buf;
+ if( stat( tmp, &buf ) == -1 ) {
+ /* something went wrong, we just don't care what for now */
+ GKBG_debug("stat: error on `%s'", tmp);
+@@ -223,6 +224,9 @@
+ gint num=1;
+ FILE *idb_file;
+ struct idb_entry *idb_e;
++#if !defined(WIN32)
++ struct stat buf;
++#endif
+
+ if((idb_file = open_imagelist( bgmon.idb, force )) == NULL) return 1;
+
+@@ -261,7 +265,6 @@
+ #if !defined(WIN32)
+ /* ignore the file if we stat returns -1 (error) and the user wants
+ * us to */
+- struct stat buf;
+ if( bgmon.ignore && (stat( tmp, &buf ) == -1) ) {
+ GKBG_debug( "ignoring `%s'", tmp );
+ } else {
--- gkrellmbgchg2.diff ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list