diff --git a/mesa-fix-yylex-2.patch b/mesa-fix-yylex-2.patch new file mode 100644 index 0000000..405f935 --- /dev/null +++ b/mesa-fix-yylex-2.patch @@ -0,0 +1,60 @@ +From 3f95ff8bfeaf839ec6c70dbed95d68f9e44861e2 Mon Sep 17 00:00:00 2001 +From: Dave Airlie +Date: Fri, 14 Sep 2012 19:59:54 +1000 +Subject: [PATCH] glcpp: fix abuse of yylex + +So glcpp tried to workaround yylex its own way, but failed, +do it properly. + +This fixes another crash found after fixing the first crash. + +this is a candidate for 9.0 and stable branches + +Signed-off-by: Dave Airlie +--- + src/glsl/glcpp/Makefile.am | 2 +- + src/glsl/glcpp/glcpp-parse.y | 8 -------- + 2 files changed, 1 insertion(+), 9 deletions(-) + +diff --git a/src/glsl/glcpp/Makefile.am b/src/glsl/glcpp/Makefile.am +index 7a95b68..87affce 100644 +--- a/src/glsl/glcpp/Makefile.am ++++ b/src/glsl/glcpp/Makefile.am +@@ -31,7 +31,7 @@ AM_CFLAGS = \ + $(LIBRARY_DEFINES) \ + $(API_DEFINES) + +-AM_YFLAGS = -v -d ++AM_YFLAGS = -v -d -p "glcpp_parser_" + AM_LFLAGS = --nounistd -o$(LEX_OUTPUT_ROOT).c + + noinst_LTLIBRARIES = libglcpp.la +diff --git a/src/glsl/glcpp/glcpp-parse.y b/src/glsl/glcpp/glcpp-parse.y +index bf6f3ad..fb9bc58 100644 +--- a/src/glsl/glcpp/glcpp-parse.y ++++ b/src/glsl/glcpp/glcpp-parse.y +@@ -133,8 +133,6 @@ _glcpp_parser_skip_stack_change_if (glcpp_parser_t *parser, YYLTYPE *loc, + static void + _glcpp_parser_skip_stack_pop (glcpp_parser_t *parser, YYLTYPE *loc); + +-#define yylex glcpp_parser_lex +- + static int + glcpp_parser_lex (YYSTYPE *yylval, YYLTYPE *yylloc, glcpp_parser_t *parser); + +@@ -1197,12 +1195,6 @@ glcpp_parser_create (const struct gl_extensions *extensions, int api) + return parser; + } + +-int +-glcpp_parser_parse (glcpp_parser_t *parser) +-{ +- return yyparse (parser); +-} +- + void + glcpp_parser_destroy (glcpp_parser_t *parser) + { +-- +1.7.11.4 + diff --git a/mesa.spec b/mesa.spec index 36a6d60..a2021f3 100644 --- a/mesa.spec +++ b/mesa.spec @@ -36,7 +36,7 @@ Summary: Mesa graphics libraries Name: mesa Version: 8.1 -Release: 0.20%{?dist} +Release: 0.21%{?dist} License: MIT Group: System Environment/Libraries URL: http://www.mesa3d.org @@ -58,6 +58,7 @@ Patch13: mesa-no-libkms.patch # fix yylex collision Patch14: mesa-fix-yylex.patch +Patch15: mesa-fix-yylex-2.patch # Courtesy of Mageia cauldron: # Fix undefined syms: http://svnweb.mageia.org/packages/cauldron/mesa/current/SOURCES/0001-Fix-undefined-symbols-in-libOSMesa-and-libglapi.patch?revision=278531&view=co @@ -288,6 +289,7 @@ Mesa shared glapi %patch12 -p1 -b .16bpp %patch13 -p1 -b .no-libkms %patch14 -p1 -b .yylex +%patch15 -p1 -b .yylex2 %patch101 -p1 -b .syms %build @@ -583,6 +585,9 @@ rm -rf $RPM_BUILD_ROOT %endif %changelog +* Fri Sep 14 2012 Dave Airlie 8.1-0.21 +- why fix one yylex when you can fix two + * Fri Sep 14 2012 Dave Airlie 8.1-0.20 - fix yylex collision reported on irc by hughsie