Syntax errors building Mesa3D 9.0.2 on Windows (program_parse.tab.c)

Keith Kriewall <[email protected]>
Newsgroups gmane.comp.video.mesa3d.user
Message-ID <[email protected]>
In the following environment:
  Windows 7 (64-bit)
  Python 2.7.3 (32-bit)
  Scons 2.2.0
  Winflexbison (lex = GNU Flex 2.5.37, yacc =  GNU Bison 2.7)
  MS Dev Studio 2010
  Mesa3D 9.0.2 source

I run 'scons libgl-gdi' and get syntax errors in build\windows-x86-debug\mesa\program\program_parse.tab.c (see clips below).  I'm guessing this is due to my yacc/lex toolset.  Any help getting this to compile would be much appreciated!

Thanks,

-Keith

==== clip of build output
  Generating build\windows-x86-debug\mesa\program\program_parse.tab.c ...
glapi_dispatch.c
  Compiling src\mesa\program\program_parse_extra.c ...
program_parse_extra.c
  Compiling build\windows-x86-debug\mesa\program\program_parse.tab.c ...
program_parse.tab.c
F:\proj\Mesa-9.0.2\src\mapi\glapi/glapitemp.h(4320) : warning C4090: 'function': different 'const' qualifiers
F:\proj\Mesa-9.0.2\src\mapi\glapi/glapitemp.h(5921) : warning C4090: 'function': different 'const' qualifiers
  Compiling src\mesa\program\program.c ...
F:\proj\Mesa-9.0.2\src\mapi\glapi/glapitemp.h(7901) : warning C4090: 'function': different 'const' qualifiers
program.c
  Compiling src\mesa\main\readpix.c ...
readpix.c
  Archiving build\windows-x86-debug\mapi\glapi\glapi.lib ...
build\windows-x86-debug\mesa\program\program_parse.tab.c(1401) : error C2143: syntax error : missing ')' before '('
build\windows-x86-debug\mesa\program\program_parse.tab.c(1401) : error C2091: function returns function
build\windows-x86-debug\mesa\program\program_parse.tab.c(1401) : error C2059: syntax error : ')'
build\windows-x86-debug\mesa\program\program_parse.tab.c(1412) : error C2085: 'yy_location_print_' : not in formal parameter list
build\windows-x86-debug\mesa\program\program_parse.tab.c(1412) : error C2143: syntax error : missing ';' before '{'
build\windows-x86-debug\mesa\program\program_parse.tab.c(1414) : error C2065: 'yylocp' : undeclared identifier
build\windows-x86-debug\mesa\program\program_parse.tab.c(1414) : error C2223: left of '->last_column' must point to struct/union
build\windows-x86-debug\mesa\program\program_parse.tab.c(1414) : error C2065: 'yylocp' : undeclared identifier
build\windows-x86-debug\mesa\program\program_parse.tab.c(1414) : error C2223: left of '->last_column' must point to struct/union
03: unable to recover from previous error(s); stopping compilation
scons: *** [build\windows-x86-debug\mesa\program\program_parse.tab.obj] Error 2
==== end clip

==== clip of program_parse.tab.c source (lines 1401 and 1412 are highlighted blue)
/* YY_LOCATION_PRINT -- Print the location on the stream.
   This macro was not mandated originally: define only if we know
   we won't break user code: when these are the locations we know.  */

#ifndef YY_LOCATION_PRINT
# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL

/* Print *YYLOCP on YYO.  Private, do not rely on its existence. */

__attribute__((__unused__))
#if (defined __STDC__ || defined __C99__FUNC__ \
     || defined __cplusplus || defined _MSC_VER)
static unsigned
yy_location_print_ (FILE *yyo, YYLTYPE const * const yylocp)
#else
static unsigned
yy_location_print_ (yyo, yylocp)
    FILE *yyo;
    YYLTYPE const * const yylocp;
#endif
{
  unsigned res = 0;
  int end_col = 0 != yylocp->last_column ? yylocp->last_column - 1 : 0;
  if (0 <= yylocp->first_line)
    {
      res += fprintf (yyo, "%d", yylocp->first_line);
      if (0 <= yylocp->first_column)
        res += fprintf (yyo, ".%d", yylocp->first_column);
    }
  if (0 <= yylocp->last_line)
    {
      if (yylocp->first_line < yylocp->last_line)
        {
          res += fprintf (yyo, "-%d", yylocp->last_line);
          if (0 <= end_col)
            res += fprintf (yyo, ".%d", end_col);
        }
      else if (0 <= end_col && yylocp->first_column < end_col)
        res += fprintf (yyo, "-%d", end_col);
    }
  return res;
}

#  define YY_LOCATION_PRINT(File, Loc)          \
  yy_location_print_ (File, &(Loc))

# else
#  define YY_LOCATION_PRINT(File, Loc) ((void) 0)
# endif
#endif
==== end clip

Keith Kriewall
Software Developer
1500 Dexter Ave N
Seattle, WA 98109
206-217-7892
[email protected]
[Description: line]
[Description: Attachmate]<http://www.attachmate.com/>

_______________________________________________
mesa-users mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/mesa-users
image001.jpg (image/jpeg, 13 KB) - not displayed
image002.jpg (image/jpeg, 2.8 KB) - not displayed
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.