summaryrefslogtreecommitdiff
blob: e070471cdc026816a33bdb7a8b7a9270e8bb192c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
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;