2 # Copyright (C) 2004 Free Software Foundation, Inc.
4 # This file is part of GNU Automake.
6 # GNU Automake is free software; you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation; either version 2, or (at your option)
11 # GNU Automake is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with Automake; see the file COPYING. If not, write to
18 # the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
19 # Boston, MA 02110-1301, USA.
21 # Check rules output for parser defined conditionally.
22 # Report from Roman Fietze.
24 required
='flex bison gcc'
29 cat >>configure.
in <<'EOF'
30 AM_CONDITIONAL([CASE_A], test -z "$case_B")
37 cat >>Makefile.am
<<'EOF'
40 BUILT_SOURCES = tparse.h
44 ta_SOURCES = ta.c tparse.h tscan.l tparse.y
48 tb_SOURCES = tb.c tparse.h tscan.l tparse.y
61 $AUTOMAKE --add-missing
63 test `grep tparse.h: Makefile.in | wc -l` = 1
65 cat > tscan.l
<< 'END'
70 cat > tparse.y
<< 'END'
72 void yyerror
(char
*s
) {}
76 foobar
: 'f' 'o' 'o' 'b' 'a' 'r' EOF
{};
92 .
/configure case_B
=yes