summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app-misc/ckb/files/ckb-0.4.2-gcc10.patch')
-rw-r--r--app-misc/ckb/files/ckb-0.4.2-gcc10.patch28
1 files changed, 28 insertions, 0 deletions
diff --git a/app-misc/ckb/files/ckb-0.4.2-gcc10.patch b/app-misc/ckb/files/ckb-0.4.2-gcc10.patch
new file mode 100644
index 00000000000..e070471cdc0
--- /dev/null
+++ b/app-misc/ckb/files/ckb-0.4.2-gcc10.patch
@@ -0,0 +1,28 @@
+From a9f41cd8b8f5b04c0c66c6d94f96a9725943831e Mon Sep 17 00:00:00 2001
+From: Erik Zeek <zeekec@gmail.com>
+Date: Tue, 12 May 2020 09:56:49 -0600
+Subject: [PATCH] Fix gcc-10/-fno-common error
+
+gcc-10 now defaults to -fno-common and does not automatically add extern
+to variables declared in headers.
+
+https://gcc.gnu.org/gcc-10/porting_to.html
+
+Signed-off-by: Erik Zeek <zeekec@gmail.com>
+---
+ src/daemon/devnode.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/daemon/devnode.h b/src/daemon/devnode.h
+index a0b3a931..349e778d 100644
+--- a/src/daemon/devnode.h
++++ b/src/daemon/devnode.h
+@@ -5,7 +5,7 @@
+ #include "usb.h"
+
+ /// Device path base ("/dev/input/ckb" or "/var/run/ckb")
+-const char *const devpath;
++extern const char *const devpath;
+
+ /// Group ID for the control nodes. -1 to give read/write access to everybody
+ extern long gid;