diff --git a/gjs-gcc11.patch b/gjs-gcc11.patch new file mode 100644 index 0000000..b0ca9d9 --- /dev/null +++ b/gjs-gcc11.patch @@ -0,0 +1,26 @@ +diff --git a/gjs/error-types.cpp b/gjs/error-types.cpp +index 86cb878..7045260 100644 +--- a/gjs/error-types.cpp ++++ b/gjs/error-types.cpp +@@ -31,7 +31,7 @@ G_DEFINE_QUARK(gjs-js-error-quark, gjs_js_error) + // clang-format on + + GType gjs_js_error_get_type(void) { +- static volatile GType g_type_id; ++ static GType g_type_id; + + if (g_once_init_enter(&g_type_id)) { + static GEnumValue errors[] = { +diff --git a/libgjs-private/gjs-util.c b/libgjs-private/gjs-util.c +index d4f7470..e420c78 100644 +--- a/libgjs-private/gjs-util.c ++++ b/libgjs-private/gjs-util.c +@@ -56,7 +56,7 @@ gjs_format_int_alternative_output(int n) + GType + gjs_locale_category_get_type(void) + { +- static volatile size_t g_define_type_id__volatile = 0; ++ static size_t g_define_type_id__volatile = 0; + if (g_once_init_enter(&g_define_type_id__volatile)) { + static const GEnumValue v[] = { + { GJS_LOCALE_CATEGORY_ALL, "GJS_LOCALE_CATEGORY_ALL", "all" }, diff --git a/gjs.spec b/gjs.spec index 5664c83..3a632b0 100644 --- a/gjs.spec +++ b/gjs.spec @@ -5,7 +5,7 @@ Name: gjs Version: 1.66.1 -Release: 2%{?dist} +Release: 3%{?dist} Summary: Javascript Bindings for GNOME # The following files contain code from Mozilla which @@ -15,6 +15,7 @@ Summary: Javascript Bindings for GNOME License: MIT and (MPLv1.1 or GPLv2+ or LGPLv2+) URL: https://wiki.gnome.org/Projects/Gjs Source0: https://download.gnome.org/sources/%{name}/1.66/%{name}-%{version}.tar.xz +Patch0: %{name}-gcc11.patch BuildRequires: cairo-gobject-devel BuildRequires: dbus-daemon @@ -94,6 +95,9 @@ the functionality of the installed gjs package. %{_datadir}/installed-tests/ %changelog +* Sat Oct 31 2020 Jeff Law - 1.66.1-3 +- Fix bogus volatiles caught by gcc-11 + * Mon Oct 19 2020 Frantisek Zatloukal - 1.66.1-2 - Rebuild against mozjs78-78.4.0-1