[mscgen] Fixes FTBFS, rhbh#1106246

dwrobel dwrobel at fedoraproject.org
Mon Jun 9 09:06:13 UTC 2014


commit 4b54067897313bc9f8e83e778b7fae7159b97b71
Author: Damian Wrobel <dwrobel at ertelnet.rybnik.pl>
Date:   Mon Jun 9 11:06:04 2014 +0200

    Fixes FTBFS, rhbh#1106246

 mscgen-0.20-language.patch |   25 +++++++++++++++++++++++++
 mscgen.spec                |    9 ++++++++-
 2 files changed, 33 insertions(+), 1 deletions(-)
---
diff --git a/mscgen-0.20-language.patch b/mscgen-0.20-language.patch
new file mode 100644
index 0000000..5457eed
--- /dev/null
+++ b/mscgen-0.20-language.patch
@@ -0,0 +1,25 @@
+Description: Use %parse-param to ensure that yyparse is generated
+ with the proper prototype.
+
+diff --git a/src/language.y b/src/language.y
+index 1b6db52..d2c466f 100644
+--- a/src/language.y
++++ b/src/language.y
+@@ -48,7 +48,7 @@ int yylex_destroy(void);
+  *  Error handling function.  The TOK_XXX names are substituted for more
+  *  understandable values that make more sense to the user.
+  */
+-void yyerror(const char *str)
++void yyerror(void *unused, const char *str)
+ {
+     static const char *tokNames[] = { "TOK_OCBRACKET",          "TOK_CCBRACKET",
+                                       "TOK_OSBRACKET",          "TOK_CSBRACKET",
+@@ -224,6 +224,8 @@ Msc MscParse(FILE *in)
+ 
+ %}
+ 
++%parse-param {void *YYPARSE_PARAM}
++
+ %token TOK_STRING TOK_QSTRING TOK_EQUAL TOK_COMMA TOK_SEMICOLON TOK_OCBRACKET TOK_CCBRACKET
+        TOK_OSBRACKET TOK_CSBRACKET TOK_MSC
+        TOK_ATTR_LABEL TOK_ATTR_URL TOK_ATTR_ID TOK_ATTR_IDURL
diff --git a/mscgen.spec b/mscgen.spec
index 6592339..c1d6e24 100644
--- a/mscgen.spec
+++ b/mscgen.spec
@@ -1,6 +1,6 @@
 Name:           mscgen
 Version:        0.20
-Release:        10%{?dist}
+Release:        11%{?dist}
 Group:          Development/Tools
 Summary:        Message Sequence Chart rendering program
 License:        GPLv2+
@@ -16,6 +16,9 @@ Patch0:         %{name}-0.20-escape.patch
 # http://code.google.com/p/mscgen/issues/detail?id=73
 Patch1:         %{name}-0.20-uninitialized-ymax.patch
 
+# Fixes language.c:464:5: error: conflicting types for 'yyparse'
+# https://code.google.com/p/mscgen/issues/detail?id=83
+Patch2:         %{name}-0.20-language.patch
 
 %global test_with_valgrind %{?_with_valgrind:1}%{!?_with_valgrind:0}
 
@@ -50,6 +53,7 @@ transformed into common image formats for display or printing.
 %setup -q
 %patch0 -p1 -b .escape
 %patch1 -p1 -b .initialization
+%patch2 -p1 -b .language
 #this ensures that they get regenerated
 rm -f src/language.{c,h} src/lexer.c
 
@@ -83,6 +87,9 @@ cp -p TODO %{buildroot}%{_defaultdocdir}/%{name}/
 
 
 %changelog
+* Mon Jun 09 2014 Damian Wrobel <dwrobel at ertelnet.rybnik.pl> - 0.20-11
+- Fixes FTBFS, rhbh#1106246.
+
 * Sat Jun 07 2014 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.20-10
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
 


More information about the scm-commits mailing list