c++ - automake 1.12 changes bison/yacc output names, backwards incompatible change? -


i have posted repository @ https://github.com/habbie/autoyacc-problem demonstrate issue.

with automake 1.11 , below, using ac_prog_yacc in configure.ac , am_yflags=-d in makefile.am, parser.yy gets turned parser.cc , parser.h. automake 1.12, parser.cc , parser.hh. because mybin.cc has include "parser.h", means 1.12 breaks build.

i have feeling backwards incompatible change, feel there should sane way deal this.

to demonstrate:

git clone https://github.com/habbie/autoyacc-problem.git cd autoyacc-problem/ autoreconf -i ./configure make 

result automake 1.11: mybin gets built. result automake 1.12:

mybin.cc:1:20: error: parser.h: no such file or directory 

help!

note: there no actual c++ code in example real issue need g++.

i aint no expert; given how depending on undocumented behaviour in older versions of automake (see zhenech) can either require newer version of automake (so can depend on defined behaviour); or make sure expected file generated automake.

given default output extension ".hh" can make generates .hh file out of .h file (for older versions of automake) simple make instruction .h.hh:

    cp $< $@ 

if prefer generate .h files out of .hh files may want turn around definitions, , depending on specifics of lex/yacc processing of autotools infamilar with, might want add generated file built_sources


Comments

Popular posts from this blog

node.js - Bad Request - node js ajax post -

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -