From 7556c80474c154e2302610909ff84c2bff479b54 Mon Sep 17 00:00:00 2001 From: Hans de Goede Date: Tue, 25 Feb 2020 18:27:59 +0100 Subject: [PATCH] Fix compilation with gcc10 / -fno-commo gcc10 defaults to -fno-common, meaning that non static symbols can only be declared once. Make the declarations in camorama-globals.h extern and declare them as non extern in main.c to fix building with gcc10. Signed-off-by: Hans de Goede --- src/camorama-globals.h | 8 ++++---- src/main.c | 5 +++++ 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/src/camorama-globals.h b/src/camorama-globals.h index 6ca0d96..a123f58 100644 --- a/src/camorama-globals.h +++ b/src/camorama-globals.h @@ -29,10 +29,10 @@ G_BEGIN_DECLS -GtkWidget *prefswindow; -int frames, frames2, seconds; -GtkWidget *dentry, *entry2, *string_entry, *format_selection; -GtkWidget *host_entry, *protocol, *rdir_entry, *filename_entry; +extern GtkWidget *prefswindow; +extern int frames, frames2, seconds; +extern GtkWidget *dentry, *entry2, *string_entry, *format_selection; +extern GtkWidget *host_entry, *protocol, *rdir_entry, *filename_entry; G_END_DECLS #endif /* !CAMORAMA_GLOBALS_H */ diff --git a/src/main.c b/src/main.c index 6874568..2431c0f 100644 --- a/src/main.c +++ b/src/main.c @@ -13,6 +13,11 @@ #include #include +GtkWidget *prefswindow; +int frames, frames2, seconds; +GtkWidget *dentry, *entry2, *string_entry, *format_selection; +GtkWidget *host_entry, *protocol, *rdir_entry, *filename_entry; + static int ver = 0, max = 0, min; static int half = 0, use_read = 0, debug = 0; static gchar *video_dev = NULL; -- 2.25.1