Salome HOME
merge from master
[tools/sat_salome.git] / products / patches / doxygen_compatibility_flex260.patch
1 diff -rupN doxygen_old/src/code.l doxygen_new/src/code.l
2 --- doxygen_old/src/code.l      2013-01-05 16:17:40.000000000 +0100
3 +++ doxygen_new/src/code.l      2016-07-18 09:58:52.775994675 +0200
4 @@ -3659,7 +3659,7 @@ void codeFreeScanner()
5  extern "C" { // some bogus code to keep the compiler happy
6    void codeYYdummy() { yy_flex_realloc(0,0); } 
7  }
8 -#elif YY_FLEX_SUBMINOR_VERSION<33
9 +#elif YY_FLEX_MINOR_VERSION<6 && YY_FLEX_SUBMINOR_VERSION<33
10  #error "You seem to be using a version of flex newer than 2.5.4 but older than 2.5.33. These versions do NOT work with doxygen! Please use version <=2.5.4 or >=2.5.33 or expect things to be parsed wrongly!"
11  #endif
12  
13 diff -rupN doxygen_old/src/commentscan.l doxygen_new/src/commentscan.l
14 --- doxygen_old/src/commentscan.l       2013-01-18 22:14:15.000000000 +0100
15 +++ doxygen_new/src/commentscan.l       2016-07-18 10:01:12.471994525 +0200
16 @@ -1049,8 +1049,8 @@ RCSTAG    "$"{ID}":"[^\n$]+"$"
17                                               // but we need to know the position in the input buffer where this 
18                                               // rule matched.
19                                               // for flex 2.5.33+ we should use YY_CURRENT_BUFFER_LVALUE
20 -#if YY_FLEX_MINOR_VERSION>=5 && YY_FLEX_SUBMINOR_VERSION>=33
21 -                                             inputPosition=prevPosition + (int)(yy_bp - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf);
22 +#if YY_FLEX_MINOR_VERSION>5 || YY_FLEX_MINOR_VERSION>=5 && YY_FLEX_SUBMINOR_VERSION>=33
23 +                                              inputPosition=prevPosition + (int)(yy_bp - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf);
24  #else
25                                               inputPosition=prevPosition + (int)(yy_bp - yy_current_buffer->yy_ch_buf);
26  #endif
27 @@ -1111,8 +1111,8 @@ RCSTAG    "$"{ID}":"[^\n$]+"$"
28                                            g_memberGroupHeader.resize(0);
29                                           parseMore=TRUE;
30                                            needNewEntry = TRUE;
31 -#if YY_FLEX_MINOR_VERSION>=5 && YY_FLEX_SUBMINOR_VERSION>=33
32 -                                         inputPosition=prevPosition + (int)(yy_bp - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf) + strlen(yytext);
33 +#if YY_FLEX_MINOR_VERSION>5 || YY_FLEX_MINOR_VERSION>=5 && YY_FLEX_SUBMINOR_VERSION>=33                                          
34 +                                         inputPosition=prevPosition + (int)(yy_bp - YY_CURRENT_BUFFER_LVALUE->yy_ch_buf) + strlen(yytext);
35  #else
36                                           inputPosition=prevPosition + (int)(yy_bp - yy_current_buffer->yy_ch_buf) + strlen(yytext);
37  #endif
38 diff -rupN doxygen_old/src/fortrancode.l doxygen_new/src/fortrancode.l
39 --- doxygen_old/src/fortrancode.l       2013-01-15 21:14:20.000000000 +0100
40 +++ doxygen_new/src/fortrancode.l       2016-07-18 10:01:55.319994479 +0200
41 @@ -1184,7 +1184,7 @@ void parseFortranCode(CodeOutputInterfac
42  extern "C" { // some bogus code to keep the compiler happy
43    void fcodeYYdummy() { yy_flex_realloc(0,0); } 
44  }
45 -#elif YY_FLEX_SUBMINOR_VERSION<33
46 +#elif YY_FLEX_MINOR_VERSION<6 && YY_FLEX_SUBMINOR_VERSION<33
47  #error "You seem to be using a version of flex newer than 2.5.4 but older than 2.5.33. These versions do NOT work with doxygen! Please use version <=2.5.4 or >=2.5.33 or expect things to be parsed wrongly!"
48  #else
49  extern "C" { // some bogus code to keep the compiler happy
50 diff -rupN doxygen_old/src/pycode.l doxygen_new/src/pycode.l
51 --- doxygen_old/src/pycode.l    2013-01-05 16:17:43.000000000 +0100
52 +++ doxygen_new/src/pycode.l    2016-07-18 10:19:39.687993338 +0200
53 @@ -1502,11 +1502,9 @@ void parsePythonCode(CodeOutputInterface
54  }
55  
56  
57 -#if !defined(YY_FLEX_SUBMINOR_VERSION) 
58 +#if YY_FLEX_MINOR_VERSION<6 && YY_FLEX_SUBMINOR_VERSION<33
59  extern "C" { // some bogus code to keep the compiler happy
60    void pycodeYYdummy() { yy_flex_realloc(0,0); } 
61  }
62 -#elif YY_FLEX_SUBMINOR_VERSION<33
63 -#error "You seem to be using a version of flex newer than 2.5.4. These are currently incompatible with 2.5.4, and do NOT work with doxygen! Please use version 2.5.4 or expect things to be parsed wrongly! A bug report has been submitted (#732132)."
64  #endif
65  
66 diff -rupN doxygen_old/src/vhdlcode.l doxygen_new/src/vhdlcode.l
67 --- doxygen_old/src/vhdlcode.l  2013-01-05 16:17:44.000000000 +0100
68 +++ doxygen_new/src/vhdlcode.l  2016-07-18 10:03:28.055994379 +0200
69 @@ -1606,7 +1606,7 @@ void codeFreeVhdlScanner()
70  extern "C" { // some bogus code to keep the compiler happy
71    void vhdlcodeYYdummy() { yy_flex_realloc(0,0); } 
72  }
73 -#elif YY_FLEX_SUBMINOR_VERSION<33
74 +#elif YY_FLEX_MINOR_VERSION<6 && YY_FLEX_SUBMINOR_VERSION<33
75  #error "You seem to be using a version of flex newer than 2.5.4 but older than 2.5.33. These versions do NOT work with doxygen! Please use version <=2.5.4 or >=2.5.33 or expect things to be parsed wrongly!"
76  #endif
77