I'd like to report a possible bug/limitation in automake and it's use with flex. It seems that ylwrap strips out or otherwise does not recognize the --header-file=foo.h option provided in AM_LFLAGS. My successful useage under 1.9 has been (obviously since ylwrap was not called due to there only being one parser):

BUILT_SOURCES = grammar.h

AM_YFLAGS = -d -p foo_parser_

AM_LFLAGS= -Pfoo_parser_ -olex.yy.c --header-file=rules.h

foo_SOURCES = \
        rules.ll \
        grammar.yy

make...

/bin/sh ../config/ylwrap rules.ll lex.yy.c rules.cc -- flex - Ppass_parser_ -olex.yy.c --header-file=rules.h
...
grammar.yy:15:21: error: rules.h: No such file or directory

Is this a bug? Or am i using automake incorrectly here?

Thanks,
Mike Tegtmeyer


Reply via email to