• malff/marcsql@weblab.(none)'s avatar
    Bug#21029 (Dependencies between sql_yacc.cc and dependent headers not detected) · 3ae384d0
    malff/marcsql@weblab.(none) authored
    The build scripts in general, using automake, autoconf, etc, contain several
    special commands and work around all related to the way the bison code in the
    parser is built, for sql/sql_yacc.yy. These work arounds, accumulated over
    time during development, ultimately cause the build scripts to be unstable
    and cause build defects by not enforcing dependencies.
    
    This fix simplifies the build process and aligns it with the automake tooling,
    which provides native support for bison and *.yy files.
    
    In particular, the following problem have been fixed:
    - dependencies with sql_yacc.cc were not honored (Bug 21029), leading to
      corrupted builds,
    - the work around introduced by Bug 24557, to cleanup the generated files
      sql_yacc.h and sql_yacc.cc, has been removed,
    - the generated makefile, in a source distribution, used to destroy the files
      sql_yacc.h and sql_yacc.cc on a 'make clean' target. This has been fixed:
      these files are now removed by make maintainer-clean.
    - The root cause of the problem found with gcc 4.1 (see Bug 24619) has been
      clearly documented, and the "sed" hack has been replaced by a cleaner
      work around, when building the code with bison 1.875.
    - Removed the file sql/sql_yacc.yy.bak, added by WL 3031 by accident.
    - Removed the unnecessary AM_YFLAG= --debug introduced by WL 3432, since
      the compiling option DBUG_OFF takes precedence when setting YYDEBUG.
    3ae384d0
sql_yacc.yy 305 KB