[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Bison and automake together
From: |
Paulo J. Matos |
Subject: |
Re: Bison and automake together |
Date: |
Sat, 06 Nov 2010 16:37:26 +0000 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) |
address@hidden (Paulo J. Matos) writes:
>
> I understand your opinion, unfortunately it then means that there's no
> support for Bison in C++ mode from the automake side which is
> unfortunate. :-/
I decided to forget automake support and instead go for my own:
So, I removed AC_PROG_YACC from configure.ac and added:
,----
| AC_PATH_PROG([BISON], [bison])
`----
Then in Makefile.am:
,----
| BISON_HEADER = scgparser.tab.hh
| BISON_GENERATED = scgparser.tab.cc $(BISON_HEADER)
| COMMON_OBJS = scgparser-driver.cc scgparser.yy scglexer.l \
| $(BISON_GENERATED)
|
| bin_PROGRAMS = scgc scgdoc scgmc
|
| scgc_SOURCES = scgc.cc $(COMMON_OBJS)
|
| $(BISON_GENERATED): scgparser.yy
| $(BISON) --defines=$(BISON_HEADER) $<
`----
But then I get this annoying:
,----
| Makefile.am: Yacc (C++) source seen but `YACC' is undefined
| Makefile.am: The usual way to define `YACC' is to add `AC_PROG_YACC'
| Makefile.am: to `configure.ac' and run `autoconf' again.
| make: *** [Makefile.in] Error 1
`----
Does someone confirm that there is a bug here?
Bison in C++ mode with -y compatibility mode generates a file which
includes y.tab.h. ylwrap _cannot_ rename the file or compilation will
fail. If C++ is supported there's a problem with ylwrap. If it's not
supported then Yacc shouldn't display the error and abort the build.
Am I right?
--
PMatos
- Re: Bison and automake together, Pippijn van Steenhoven, 2010/11/01
- Re: Bison and automake together, Paulo J. Matos, 2010/11/01
- Re: Bison and automake together, Paulo J. Matos, 2010/11/01
- Re: Bison and automake together, Philip Herron, 2010/11/01
- Re: Bison and automake together, Paulo J. Matos, 2010/11/02
- Re: Bison and automake together, Philip Herron, 2010/11/02
- Re: Bison and automake together, Andrew W. Nosenko, 2010/11/02
- Re: Bison and automake together, Paulo J. Matos, 2010/11/06
- Re: Bison and automake together,
Paulo J. Matos <=
- Re: Bison and automake together, Pippijn van Steenhoven, 2010/11/06
- Re: Bison and automake together, Philip Herron, 2010/11/06