aboutsummaryrefslogtreecommitdiffstats
path: root/sysutils
diff options
context:
space:
mode:
authormadpilot <madpilot@FreeBSD.org>2018-11-29 18:33:29 +0800
committermadpilot <madpilot@FreeBSD.org>2018-11-29 18:33:29 +0800
commitc300449c4ba77bff62197f37141231eadbf81dc3 (patch)
tree2cf86c3f0b35f3e3d98c4d01ecc3f54a925e19d3 /sysutils
parented639c697e715997dd9474e78bbcb8a85cb60e9b (diff)
downloadfreebsd-ports-gnome-c300449c4ba77bff62197f37141231eadbf81dc3.tar.gz
freebsd-ports-gnome-c300449c4ba77bff62197f37141231eadbf81dc3.tar.zst
freebsd-ports-gnome-c300449c4ba77bff62197f37141231eadbf81dc3.zip
Fix build with GCC-based architectures.
Fix changes the name of a variable to avoid clash with a function name defined in an include file used by GCC. PR: 233616 Submitted by: Piotr Kubaj <pkubaj@anongoth.pl>
Diffstat (limited to 'sysutils')
-rw-r--r--sysutils/conky/files/patch-src_freebsd.cc23
1 files changed, 23 insertions, 0 deletions
diff --git a/sysutils/conky/files/patch-src_freebsd.cc b/sysutils/conky/files/patch-src_freebsd.cc
new file mode 100644
index 000000000000..ced6803b86c5
--- /dev/null
+++ b/sysutils/conky/files/patch-src_freebsd.cc
@@ -0,0 +1,23 @@
+--- src/freebsd.cc.orig 2018-11-28 18:50:47 UTC
++++ src/freebsd.cc
+@@ -78,7 +78,7 @@ std::mutex kvm_proc_mutex;
+ __attribute__((gnu_inline)) inline void
+ proc_find_top(struct process **cpu, struct process **mem, struct process **time);
+
+-static short cpu_setup = 0;
++static short conky_cpu_setup = 0;
+
+ static int getsysctl(const char *name, void *ptr, size_t len)
+ {
+@@ -338,9 +338,9 @@ int update_cpu_usage(void)
+ extern void* global_cpu;
+
+ /* add check for !info.cpu_usage since that mem is freed on a SIGUSR1 */
+- if ((cpu_setup == 0) || (!info.cpu_usage)) {
++ if ((conky_cpu_setup == 0) || (!info.cpu_usage)) {
+ get_cpu_count();
+- cpu_setup = 1;
++ conky_cpu_setup = 1;
+ }
+
+ if (!global_cpu) {