View | Details | Raw Unified | Return to bug 164893
Collapse All | Expand All

(-)conky/files/patch-configure (-1 / +101 lines)
Lines 1-6 Link Here
1
--- configure.orig
1
--- configure.orig
2
+++ configure
2
+++ configure
3
@@ -11645,7 +11645,7 @@
3
@@ -1002,6 +1002,7 @@
4
 enable_xft
5
 enable_nvidia
6
 enable_alsa
7
+enable_inotify
8
 enable_debug
9
 enable_testing
10
 enable_profiling
11
@@ -1729,6 +1730,7 @@
12
   --enable-nvidia         enable if you want nvidia support [default=no]
13
   --disable-alsa          disable if you do not want ALSA support
14
                           [default=yes]
15
+  --enable-inotify        enable if you want inotify support [default=no]
16
   --enable-debug          compile with debug symbols [default=no]
17
   --enable-testing        use strict compiler flags for testing [default=no]
18
   --enable-profiling      specify compiler flags for use with gprof and gcov
19
@@ -11647,7 +11649,7 @@
4
 
20
 
5
 
21
 
6
 if test x$want_apcupsd = xyes; then
22
 if test x$want_apcupsd = xyes; then
Lines 18-20 Link Here
18
       { $as_echo "$as_me:${as_lineno-$LINENO}: iostats not supported on $uname... disabling" >&5
34
       { $as_echo "$as_me:${as_lineno-$LINENO}: iostats not supported on $uname... disabling" >&5
19
 $as_echo "$as_me: iostats not supported on $uname... disabling" >&6;}
35
 $as_echo "$as_me: iostats not supported on $uname... disabling" >&6;}
20
       want_iostats="not supported on $uname"
36
       want_iostats="not supported on $uname"
37
@@ -16071,20 +16073,65 @@
38
 
39
 done
40
 
41
-# check if we have inotify support
42
-for ac_header in sys/inotify.h
43
-do :
44
-  ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
45
-if test "x$ac_cv_header_sys_inotify_h" = x""yes; then :
46
-  cat >>confdefs.h <<_ACEOF
47
-#define HAVE_SYS_INOTIFY_H 1
48
-_ACEOF
49
 
50
+# Check whether --enable-inotify was given.
51
+if test "${enable_inotify+set}" = set; then :
52
+  enableval=$enable_inotify; want_inotify="$enableval"
53
+else
54
+  want_inotify=no
55
 fi
56
 
57
-done
58
+if test x$want_inotify = xyes; then
59
+    ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
60
+if test "x$ac_cv_header_sys_inotify_h" = xyes; then :
61
+ 
62
+else
63
+  want_inotify=no
64
+fi
65
 
66
 
67
+fi
68
+if test x$want_inotify = xyes; then
69
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inotify_init in -linotify" >&5
70
+$as_echo_n "checking for inotify_init in -linotify... " >&6; }
71
+if ${ac_cv_lib_inotify_inotify_init+:} false; then :
72
+  $as_echo_n "(cached) " >&6
73
+else
74
+  ac_check_lib_save_LIBS=$LIBS
75
+LIBS="-linotify  $LIBS"
76
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77
+/* end confdefs.h.  */
78
+
79
+#include <sys/inotify.h>
80
+
81
+char inotify_init ();
82
+int
83
+main ()
84
+{
85
+return inotify_init ();
86
+  ;
87
+  return 0;
88
+}
89
+_ACEOF
90
+if ac_fn_c_try_link "$LINENO"; then :
91
+  ac_cv_lib_inotify_inotify_init=yes
92
+else
93
+  ac_cv_lib_inotify_inotify_init=no
94
+fi
95
+rm -f core conftest.err conftest.$ac_objext \
96
+    conftest$ac_exeext conftest.$ac_ext
97
+LIBS=$ac_check_lib_save_LIBS
98
+fi
99
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_inotify_inotify_init" >&5
100
+$as_echo "$ac_cv_lib_inotify_inotify_init" >&6; }
101
+if test "x$ac_cv_lib_inotify_inotify_init" = xyes; then :
102
+  conky_LIBS="$conky_LIBS -linotify"
103
+else
104
+  want_inotify=yes
105
+fi
106
+
107
+fi
108
+
109
 
110
 
111
 $as_echo "#define DEFAULTNETDEV \"eth0\"" >>confdefs.h
112
@@ -16102,7 +16153,7 @@
113
 $as_echo "#define DEFAULT_TEXT_BUFFER_SIZE 256" >>confdefs.h
114
 
115
 
116
-$as_echo "#define MAX_NET_INTERFACES 16" >>confdefs.h
117
+$as_echo "#define MAX_NET_INTERFACES 64" >>confdefs.h
118
 
119
 
120
 
(-)conky/files/patch-src-ccurl_thread.c (+10 lines)
Line 0 Link Here
1
--- src/ccurl_thread.c.orig	2010-10-06 00:29:36.000000000 +0300
2
+++ src/ccurl_thread.c	2012-03-05 01:08:23.000000000 +0200
3
@@ -33,7 +33,6 @@
4
 #endif /* DEBUG */
5
 
6
 #include <curl/curl.h>
7
-#include <curl/types.h>
8
 #include <curl/easy.h>
9
 
10
 /*
(-)conky/files/patch-src-conky.c (-1 / +10 lines)
Lines 1-5 Link Here
1
--- src/conky.c.orig	2010-10-06 00:29:36.000000000 +0300
1
--- src/conky.c.orig	2010-10-06 00:29:36.000000000 +0300
2
+++ src/conky.c	2010-10-10 00:06:31.000000000 +0300
2
+++ src/conky.c	2012-03-05 01:03:43.000000000 +0200
3
@@ -119,7 +119,7 @@
4
 #include "openbsd.h"
5
 #endif
6
 
7
-#if defined(__FreeBSD_kernel__)
8
+#if defined(__FreeBSD_kernel__) && (__FreeBSD_kernel__ + 0)
9
 #include <bsd/bsd.h>
10
 #endif
11
 
3
@@ -2072,9 +2072,11 @@
12
@@ -2072,9 +2072,11 @@
4
 			OBJ(xmms2_percent) {
13
 			OBJ(xmms2_percent) {
5
 				snprintf(p, p_max_size, "%2.0f", cur->xmms2.progress * 100);
14
 				snprintf(p, p_max_size, "%2.0f", cur->xmms2.progress * 100);
(-)conky/files/patch-src-freebsd.c (-7 / +31 lines)
Lines 1-6 Link Here
1
--- src/freebsd.c.orig	2010-10-24 03:14:05.000000000 +0300
1
--- src/freebsd.c.orig	2010-10-06 00:29:36.000000000 +0300
2
+++ src/freebsd.c	2010-10-24 03:13:05.000000000 +0300
2
+++ src/freebsd.c	2012-03-05 01:02:25.000000000 +0200
3
@@ -266,7 +266,9 @@
3
@@ -38,6 +38,11 @@
4
 #include <sys/types.h>
5
 #include <sys/user.h>
6
 
7
+#if defined(__FreeBSD__) && (!defined(__FreeBSD_kernel__) || !(__FreeBSD_kernel__ + 0))
8
+# undef __FreeBSD_kernel__
9
+# define __FreeBSD_kernel__ __FreeBSD__
10
+#endif
11
+
12
 #include <net/if.h>
13
 #include <net/if_mib.h>
14
 #include <net/if_media.h>
15
@@ -266,7 +271,9 @@
4
 {
16
 {
5
 	int n_processes;
17
 	int n_processes;
6
 
18
 
Lines 10-24 Link Here
10
 
22
 
11
 	info.procs = n_processes;
23
 	info.procs = n_processes;
12
 	return 0;
24
 	return 0;
13
@@ -278,6 +280,7 @@
25
@@ -278,9 +285,10 @@
14
 	int n_processes;
26
 	int n_processes;
15
 	int i, cnt = 0;
27
 	int i, cnt = 0;
16
 
28
 
17
+	pthread_mutex_lock(&kvm_proc_mutex);
29
+	pthread_mutex_lock(&kvm_proc_mutex);
18
 	p = kvm_getprocs(kd, KERN_PROC_ALL, 0, &n_processes);
30
 	p = kvm_getprocs(kd, KERN_PROC_ALL, 0, &n_processes);
19
 	for (i = 0; i < n_processes; i++) {
31
 	for (i = 0; i < n_processes; i++) {
20
 #if (__FreeBSD__ < 5) && (__FreeBSD_kernel__ < 5)
32
-#if (__FreeBSD__ < 5) && (__FreeBSD_kernel__ < 5)
21
@@ -288,6 +291,7 @@
33
+#if (defined(__FreeBSD__) && (__FreeBSD__ < 5)) || (defined(__FreeBSD_kernel__) && (__FreeBSD_kernel__ < 5))
34
 		if (p[i].kp_proc.p_stat == SRUN) {
35
 #else
36
 		if (p[i].ki_stat == SRUN) {
37
@@ -288,6 +296,7 @@
22
 			cnt++;
38
 			cnt++;
23
 		}
39
 		}
24
 	}
40
 	}
Lines 26-32 Link Here
26
 
42
 
27
 	info.run_procs = cnt;
43
 	info.run_procs = cnt;
28
 	return 0;
44
 	return 0;
29
@@ -748,6 +752,7 @@
45
@@ -296,7 +305,6 @@
46
 void get_cpu_count(void)
47
 {
48
 	int cpu_count = 0;
49
-	size_t cpu_count_len = sizeof(cpu_count);
50
 
51
 	if (GETSYSCTL("hw.ncpu", cpu_count) == 0) {
52
 		info.cpu_count = cpu_count;
53
@@ -748,6 +756,7 @@
30
 		CRIT_ERR(NULL, NULL, "Cannot read sysctl \"vm.stats.vm.v_page_count\"");
54
 		CRIT_ERR(NULL, NULL, "Cannot read sysctl \"vm.stats.vm.v_page_count\"");
31
 	}
55
 	}
32
 
56
 
(-)conky/Makefile (-1 / +9 lines)
Lines 7-13 Link Here
7
7
8
PORTNAME=	conky
8
PORTNAME=	conky
9
PORTVERSION=	1.8.1
9
PORTVERSION=	1.8.1
10
PORTREVISION=	4
10
PORTREVISION=	5
11
CATEGORIES=	sysutils
11
CATEGORIES=	sysutils
12
MASTER_SITES=	SF
12
MASTER_SITES=	SF
13
13
Lines 39-44 Link Here
39
39
40
OPTIONS+=	APCUPSD "Enable APCUPSD support" Off \
40
OPTIONS+=	APCUPSD "Enable APCUPSD support" Off \
41
		AUDACIOUS "Enable Audacious support" Off \
41
		AUDACIOUS "Enable Audacious support" Off \
42
		INOTIFY "Enable inotify support" Off \
42
		MPD "Enable MPD support" Off \
43
		MPD "Enable MPD support" Off \
43
		NCURSES "Enable ncurses support" Off \
44
		NCURSES "Enable ncurses support" Off \
44
		RSS "Enable RSS support" Off \
45
		RSS "Enable RSS support" Off \
Lines 82-87 Link Here
82
CONFIGURE_ARGS+=	--disable-audacious
83
CONFIGURE_ARGS+=	--disable-audacious
83
.endif
84
.endif
84
85
86
.if defined(WITH_INOTIFY)
87
LIB_DEPENDS+=		inotify.0:${PORTSDIR}/devel/libinotify
88
CONFIGURE_ARGS+=	--enable-inotify
89
.else
90
CONFIGURE_ARGS+=	--disable-inotify
91
.endif
92
85
.if defined(WITH_LUA) || defined(WITH_LUA_CAIRO) || defined(WITH_LUA_IMLIB2)
93
.if defined(WITH_LUA) || defined(WITH_LUA_CAIRO) || defined(WITH_LUA_IMLIB2)
86
USE_LUA=		5.1+
94
USE_LUA=		5.1+
87
CONFIGURE_ARGS+=	--enable-lua
95
CONFIGURE_ARGS+=	--enable-lua

Return to bug 164893