Blame SOURCES/0002-Drop-superfluous-global-variable-definitions.patch

3f7af7
From 924bd2da3a00e030e29d82b74ef82900bd50b475 Mon Sep 17 00:00:00 2001
3f7af7
From: =?UTF-8?q?Ond=C5=99ej=20Lyson=C4=9Bk?= <olysonek@redhat.com>
3f7af7
Date: Mon, 3 Feb 2020 13:18:33 +0100
3f7af7
Subject: [PATCH 2/3] Drop superfluous global variable definitions
3f7af7
3f7af7
The only place where the EXTERN macro mechanism is used to define the
3f7af7
global variables 'vt_outmap' and 'vt_inmap' is minicom.c (by defining
3f7af7
an empty EXTERN macro and including the minicom.h header). The file
3f7af7
vt100.c already defines these variables. The vt100.o object file is
3f7af7
always linked to minicom.o. Thus it is safe not to define the
3f7af7
variables in minicom.c and only declare them in the minicom.h header.
3f7af7
3f7af7
This fixes linking with gcc 10 which uses -fno-common by default,
3f7af7
disallowing multiple global variable definitions.
3f7af7
---
3f7af7
 src/minicom.h | 2 +-
3f7af7
 1 file changed, 1 insertion(+), 1 deletion(-)
3f7af7
3f7af7
diff --git a/src/minicom.h b/src/minicom.h
3f7af7
index 061c013..0f9693b 100644
3f7af7
--- a/src/minicom.h
3f7af7
+++ b/src/minicom.h
3f7af7
@@ -141,7 +141,7 @@ EXTERN int sbcolor;     /* Status Bar Background Color */
3f7af7
 EXTERN int st_attr;	/* Status Bar attributes. */
3f7af7
 
3f7af7
 /* jl 04.09.97 conversion tables */
3f7af7
-EXTERN unsigned char vt_outmap[256], vt_inmap[256];
3f7af7
+extern unsigned char vt_outmap[256], vt_inmap[256];
3f7af7
 
3f7af7
 /* MARK updated 02/17/95 - history buffer */
3f7af7
 EXTERN int num_hist_lines;  /* History buffer size */
3f7af7
-- 
3f7af7
2.24.1
3f7af7