commit 3b78e920ab0a0f2d7e9c661bdd5f96fc5dda1423
Author: leigh123linux <leigh123linux(a)googlemail.com>
Date: Sun Mar 26 11:13:09 2017 +0100
Fix build issues (use fedora compiler flags)
...not-a-string-literal-and-no-format-argume.patch | 79 ++++++++++++++++++++++
gmameui.spec | 28 ++++++--
2 files changed, 100 insertions(+), 7 deletions(-)
---
diff --git a/fix-format-not-a-string-literal-and-no-format-argume.patch
b/fix-format-not-a-string-literal-and-no-format-argume.patch
new file mode 100644
index 0000000..f956220
--- /dev/null
+++ b/fix-format-not-a-string-literal-and-no-format-argume.patch
@@ -0,0 +1,79 @@
+From 3de89a2abd3360c39fe2e569c0a24c9f6e145f29 Mon Sep 17 00:00:00 2001
+From: leigh123linux <leigh123linux(a)googlemail.com>
+Date: Sun, 26 Mar 2017 10:51:12 +0100
+Subject: [PATCH] fix format not a string literal and no format arguments
+
+---
+ src/common.c | 4 ++--
+ src/game_list.c | 2 +-
+ src/gmameui-main-win.c | 2 +-
+ src/gmameui.c | 4 ++--
+ 4 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/src/common.c b/src/common.c
+index dbb855a..fc6dbb0 100644
+--- a/src/common.c
++++ b/src/common.c
+@@ -44,7 +44,7 @@ gmameui_message (GtkDialogFlags type,
+ GTK_DIALOG_DESTROY_WITH_PARENT,
+ type,
+ GTK_BUTTONS_CLOSE,
+- my_args);
++ "%s", my_args);
+ g_free (my_args);
+ gtk_dialog_run (GTK_DIALOG (dialog));
+ gtk_widget_destroy (dialog);
+@@ -72,7 +72,7 @@ gmameui_dialog_create (GtkDialogFlags type,
+ GTK_DIALOG_DESTROY_WITH_PARENT,
+ type,
+ GTK_BUTTONS_CLOSE,
+- my_args);
++ "%s", my_args);
+ g_free (my_args);
+
+ return dialog;
+diff --git a/src/game_list.c b/src/game_list.c
+index 12aaa0d..eb2a90d 100644
+--- a/src/game_list.c
++++ b/src/game_list.c
+@@ -713,7 +713,7 @@ gamelist_check (MameExec *exec)
+ _("Rebuild gamelist"), GTK_RESPONSE_YES,
+ NULL);
+ gtk_message_dialog_format_secondary_text (GTK_MESSAGE_DIALOG (dialog),
+- message);
++ "%s", message);
+ result = gtk_dialog_run (GTK_DIALOG (dialog));
+ gtk_widget_destroy (dialog);
+
+diff --git a/src/gmameui-main-win.c b/src/gmameui-main-win.c
+index 0365299..1159e0f 100644
+--- a/src/gmameui-main-win.c
++++ b/src/gmameui-main-win.c
+@@ -1058,7 +1058,7 @@ on_help_activate (GtkAction *action, gpointer user_data)
+ NULL,
+ _("There was an error opening the Help file"));
+ gtk_message_dialog_format_secondary_text (GTK_MESSAGE_DIALOG (helperr_dlg),
+- error->message);
++ "%s", error->message);
+ gtk_dialog_run (GTK_DIALOG (helperr_dlg));
+ gtk_widget_destroy (helperr_dlg);
+ g_error_free (error);
+diff --git a/src/gmameui.c b/src/gmameui.c
+index 89d8b46..e33947d 100644
+--- a/src/gmameui.c
++++ b/src/gmameui.c
+@@ -408,9 +408,9 @@ launch_emulation (MameRomEntry *rom,
+ for (node = g_list_first (extra_output); node; node = node->next) {
+ secmessage = g_strconcat (secmessage, node->data, "\n", NULL);
+ }
+- dialog = gmameui_dialog_create (ERROR, NULL, title);
++ dialog = gmameui_dialog_create (ERROR, NULL, "%s", title);
+ gtk_message_dialog_format_secondary_text (GTK_MESSAGE_DIALOG (dialog),
+- secmessage);
++ "%s", secmessage);
+
+ gtk_dialog_run (GTK_DIALOG (dialog));
+ gtk_widget_destroy (dialog);
+--
+2.12.1
+
diff --git a/gmameui.spec b/gmameui.spec
index 1159bbf..c47652b 100644
--- a/gmameui.spec
+++ b/gmameui.spec
@@ -7,7 +7,7 @@
Summary: Frontend for MAME
Name: gmameui
Version: 0.2.13
-Release: 0.8%{?gver}%{?dist}
+Release: 0.9%{?gver}%{?dist}
License: GPLv3+
Group: Applications/Emulators
URL:
http://gmameui.sourceforge.net/
@@ -15,12 +15,17 @@ URL:
http://gmameui.sourceforge.net/
#
https://github.com/sergiomb2/gmameui
Source0: gmameui-%{version}-%{snapshot}.tar.bz2
Source1: gmameui-localsnapshot.sh
+Patch0: fix-format-not-a-string-literal-and-no-format-argume.patch
+
+BuildRequires: desktop-file-utils
BuildRequires: gtk2-devel >= 2.10
#BuildRequires: libgnome-devel
BuildRequires: expat-devel
#BuildRequires: libglade2-devel
-BuildRequires: gettext, bison
-BuildRequires: intltool, perl(XML::Parser)
+BuildRequires: gettext
+BuildRequires: bison
+BuildRequires: intltool
+BuildRequires: perl(XML::Parser)
BuildRequires: libarchive-devel
BuildRequires: libvtemm-devel
BuildRequires: gnome-doc-utils
@@ -56,16 +61,16 @@ It contains a number of enhancements over GXMame:
%prep
-%setup -q
+%autosetup -p1
%build
./autogen.sh
%configure --enable-debug
-%{__make} %{?_smp_mflags}
+%make_build CFLAGS="$RPM_OPT_FLAGS" LDFLAGS="$RPM_LD_FLAGS"
%install
-%{__make} install DESTDIR=%{buildroot}
+%make_install
%find_lang %{name}
# clean empty files
@@ -79,8 +84,12 @@ gmameui-emblem-unknown.png gmameui-emblem-played.png
gmameui-emblem-sound.png \
%{buildroot}%{_datadir}/gmameui/
popd
+desktop-file-install \
+ --delete-original \
+ --dir $RPM_BUILD_ROOT/%{_datadir}/applications \
+ $RPM_BUILD_ROOT/%{_datadir}/applications/gmameui.desktop
+
%files -f %{name}.lang
-%defattr(-,root,root,-)
%doc %{_docdir}
%{_bindir}/gmameui
%{_datadir}/applications/gmameui.desktop
@@ -91,6 +100,11 @@ popd
%{_mandir}/man6/gmameui.6*
%changelog
+* Sun Mar 26 2017 Leigh Scott <leigh123linux(a)googlemail.com> -
0.2.13-0.9.20150124git7bac32a
+- Fix build issues (use fedora compiler flags)
+- Fix compile issue
+- Validate desktop file
+
* Sat Mar 25 2017 RPM Fusion Release Engineering <kwizart(a)rpmfusion.org> -
0.2.13-0.8.20150124git7bac32a
- Rebuilt for
https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild