OpenSDE Packages Database (without history before r20070)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

111 lines
3.4 KiB

  1. # --- SDE-COPYRIGHT-NOTE-BEGIN ---
  2. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  3. #
  4. # Filename: package/.../flex/flex-2.5.37-bison-2.6.1-1.patch
  5. # Copyright (C) 2012 The OpenSDE Project
  6. #
  7. # More information can be found in the files COPYING and README.
  8. #
  9. # This patch file is dual-licensed. It is available under the license the
  10. # patched project is licensed under, as long as it is an OpenSource license
  11. # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
  12. # of the GNU General Public License as published by the Free Software
  13. # Foundation; either version 2 of the License, or (at your option) any later
  14. # version.
  15. # --- SDE-COPYRIGHT-NOTE-END ---
  16. Submitted By: Bruce Dubbs <bdubbs@linuxfromscratch.org>
  17. Date: 2012-08-20
  18. Initial Package Version: 2.5.36
  19. Origin: Redhat
  20. Description: This fixes two errors in the regression tests due to changes
  21. in bison.
  22. diff -up flex-2.5.36/tests/test-bison-yylloc/main.c~ flex-2.5.36/tests/test-bison-yylloc/main.c
  23. --- flex-2.5.36/tests/test-bison-yylloc/main.c~ 2002-06-25 21:37:06.000000000 +0200
  24. +++ flex-2.5.36/tests/test-bison-yylloc/main.c 2012-07-31 18:53:22.007394045 +0200
  25. @@ -21,8 +21,6 @@
  26. #include "parser.h"
  27. #include "scanner.h"
  28. -extern int testparse(yyscan_t);
  29. -
  30. int main ( int argc, char** argv )
  31. {
  32. yyscan_t scanner;
  33. diff -up flex-2.5.36/tests/test-bison-yylloc/parser.y~ flex-2.5.36/tests/test-bison-yylloc/parser.y
  34. --- flex-2.5.36/tests/test-bison-yylloc/parser.y~ 2002-07-25 02:43:47.000000000 +0200
  35. +++ flex-2.5.36/tests/test-bison-yylloc/parser.y 2012-08-01 01:06:53.093155586 +0200
  36. @@ -21,6 +21,8 @@
  37. * PURPOSE.
  38. */
  39. +%parse-param { void* scanner }
  40. +
  41. /*
  42. How to compile:
  43. bison --defines --output-file="parser.c" --name-prefix="test" parser.y
  44. @@ -32,10 +34,8 @@
  45. #include "config.h"
  46. #define YYERROR_VERBOSE 1
  47. -#define YYPARSE_PARAM scanner
  48. #define YYLEX_PARAM scanner
  49. -int yyerror(char* msg);
  50. extern int testget_lineno(void*);
  51. @@ -89,7 +89,7 @@ line:
  52. %%
  53. -int yyerror(char* msg) {
  54. +int yyerror(void* scanner, char* msg) {
  55. fprintf(stderr,"%s\n",msg);
  56. return 0;
  57. }
  58. diff -up flex-2.5.36/tests/test-bison-yylval/main.c~ flex-2.5.36/tests/test-bison-yylval/main.c
  59. --- flex-2.5.36/tests/test-bison-yylval/main.c~ 2002-06-25 21:37:06.000000000 +0200
  60. +++ flex-2.5.36/tests/test-bison-yylval/main.c 2012-08-01 01:10:02.015510280 +0200
  61. @@ -24,8 +24,6 @@
  62. #include "parser.h"
  63. #include "scanner.h"
  64. -extern int testparse(yyscan_t);
  65. -
  66. int main ( int argc, char** argv )
  67. {
  68. yyscan_t scanner;
  69. diff -up flex-2.5.36/tests/test-bison-yylval/parser.y~ flex-2.5.36/tests/test-bison-yylval/parser.y
  70. --- flex-2.5.36/tests/test-bison-yylval/parser.y~ 2002-06-25 21:37:06.000000000 +0200
  71. +++ flex-2.5.36/tests/test-bison-yylval/parser.y 2012-08-01 01:13:11.239867147 +0200
  72. @@ -25,6 +25,7 @@
  73. How to compile:
  74. bison --defines --output-file="parser.c" --name-prefix="test" parser.y
  75. */
  76. +%parse-param { void* scanner }
  77. %{
  78. #include <stdio.h>
  79. #include <stdlib.h>
  80. @@ -32,11 +33,8 @@
  81. #include "config.h"
  82. #define YYERROR_VERBOSE 1
  83. -#define YYPARSE_PARAM scanner
  84. #define YYLEX_PARAM scanner
  85. -int yyerror(char* msg);
  86. -
  87. /* A dummy function. A check against seg-faults in yylval->str. */
  88. int process_text(char* s) {
  89. @@ -76,7 +74,7 @@ starttag: LT TAGNAME GT { process_
  90. endtag: LTSLASH TAGNAME GT { process_text($2);free($2);} ;
  91. %%
  92. -int yyerror(char* msg) {
  93. +int yyerror(void* scanner, char* msg) {
  94. fprintf(stderr,"%s\n",msg);
  95. return 0;
  96. }