[packages/gnugo] - rel 5; build fixed
arekm
arekm at pld-linux.org
Sat Dec 12 13:32:44 CET 2015
commit c60ba028a0425ec8e02f89ea6a8a85f73a4bdc7a
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date: Sat Dec 12 13:32:40 2015 +0100
- rel 5; build fixed
gnugo-3.8-format-security.patch | 60 +++++++++++++++++++++++++++++++++++++++++
gnugo-info.patch | 26 ++++++++++++++++++
gnugo.spec | 4 ++-
3 files changed, 89 insertions(+), 1 deletion(-)
---
diff --git a/gnugo.spec b/gnugo.spec
index 24b0751..befd033 100644
--- a/gnugo.spec
+++ b/gnugo.spec
@@ -2,13 +2,14 @@ Summary: GNU GO
Summary(pl.UTF-8): Wersja GNU gry w GO
Name: gnugo
Version: 3.8
-Release: 4
+Release: 5
License: GPL v3
Group: Applications/Games
Source0: ftp://ftp.gnu.org/gnu/gnugo/%{name}-%{version}.tar.gz
# Source0-md5: 6db0a528df58876d2b0ef1659c374a9a
Patch0: %{name}-info.patch
Patch1: %{name}-tinfo.patch
+Patch2: gnugo-3.8-format-security.patch
URL: http://www.gnu.org/software/gnugo/
BuildRequires: autoconf
BuildRequires: automake
@@ -42,6 +43,7 @@ CGoban (wymagający X Window System).
%setup -q
%patch0 -p1
%patch1 -p1
+%patch2 -p1
%build
%{__aclocal}
diff --git a/gnugo-3.8-format-security.patch b/gnugo-3.8-format-security.patch
new file mode 100644
index 0000000..7828187
--- /dev/null
+++ b/gnugo-3.8-format-security.patch
@@ -0,0 +1,60 @@
+diff --git a/patterns/dfa.c b/patterns/dfa.c
+index 3689616..2d2f8c6 100644
+--- a/patterns/dfa.c
++++ b/patterns/dfa.c
+@@ -279,7 +279,7 @@ resize_dfa(dfa_t *pdfa, int max_states, int max_indexes)
+ * dump a dfa (debugging purpose).
+ */
+
+-static const char *line =
++static const char line[] =
+ "----------------------------------------------------\n";
+
+ void
+diff --git a/patterns/mkpat.c b/patterns/mkpat.c
+index 70a6964..5f1f1dd 100644
+--- a/patterns/mkpat.c
++++ b/patterns/mkpat.c
+@@ -1419,7 +1419,7 @@ generate_autohelper_code(int funcno, int number_of_params, int *labels)
+ /* A common case. Just use the labels as parameters. */
+ switch (number_of_params) {
+ case 0:
+- code_pos += sprintf(code_pos, autohelper_functions[funcno].code);
++ code_pos += sprintf(code_pos, "%s", autohelper_functions[funcno].code);
+ break;
+ case 1:
+ code_pos += sprintf(code_pos, autohelper_functions[funcno].code,
+diff --git a/patterns/uncompress_fuseki.c b/patterns/uncompress_fuseki.c
+index 3290b05..c67a733 100644
+--- a/patterns/uncompress_fuseki.c
++++ b/patterns/uncompress_fuseki.c
+@@ -224,9 +224,9 @@ main(int argc, char *argv[])
+
+ assert(boardsize > 0);
+ if (boardsize > MAX_BOARD) {
+- printf(output_strings[PREAMBLE]);
++ printf("%s", output_strings[PREAMBLE]);
+ printf(output_strings[HEADER], boardsize);
+- printf(output_strings[FOOTER]);
++ printf("%s", output_strings[FOOTER]);
+ return EXIT_SUCCESS;
+ }
+
+@@ -251,7 +251,7 @@ main(int argc, char *argv[])
+ board[k][boardsize + 1] = '|';
+ }
+
+- printf(output_strings[PREAMBLE]);
++ printf("%s", output_strings[PREAMBLE]);
+ printf(output_strings[HEADER], boardsize);
+
+
+@@ -308,7 +308,7 @@ main(int argc, char *argv[])
+ if (mode == C_OUTPUT)
+ write_pattern_c_code(NULL, board1d, NO_MOVE, 0, boardsize, -1);
+
+- printf(output_strings[FOOTER]);
++ printf("%s", output_strings[FOOTER]);
+
+ return EXIT_SUCCESS;
+ }
diff --git a/gnugo-info.patch b/gnugo-info.patch
index 5f012bc..8edcda3 100644
--- a/gnugo-info.patch
+++ b/gnugo-info.patch
@@ -12,3 +12,29 @@
@end direntry
@set EDITION 3.6
+Index: gnugo-3.8/doc/gnugo.texi
+===================================================================
+--- gnugo-3.8.orig/doc/gnugo.texi 2009-02-17 22:41:31.000000000 +0100
++++ gnugo-3.8/doc/gnugo.texi 2013-10-08 22:32:23.530377778 +0200
+@@ -26,7 +26,7 @@
+
+ @sp 1
+ @page
+- at title{GNU Go 3.8}
++ at title GNU Go 3.8
+ @vskip 0pt plus 1filll
+ Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
+ 2008 and 2009 @uref{http://www.fsf.org,Free Software Foundation}, Inc.
+Index: gnugo-3.8/doc/montecarlo.texi
+===================================================================
+--- gnugo-3.8.orig/doc/montecarlo.texi 2009-02-17 22:41:31.000000000 +0100
++++ gnugo-3.8/doc/montecarlo.texi 2013-10-08 22:33:54.363875500 +0200
+@@ -245,7 +245,7 @@
+ pattern to take effect. If contradictory properties are combined, the
+ pattern will never match.
+
+- at subsection Final Remarks
++ at section Final Remarks
+
+ @itemize
+ @item Move values are unsigned 32-bit integers. To avoid overflow in
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/gnugo.git/commitdiff/c60ba028a0425ec8e02f89ea6a8a85f73a4bdc7a
More information about the pld-cvs-commit
mailing list