This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Configuration/Makefile cleanups


On Fri, Nov 24, 2000 at 06:36:22PM -0800, Mark Mitchell wrote:
> In this case, neither the cost, nor the benefit is very high.  In my
> opinion, the cost is, however, greater than the benefit.  Therefore,
> it's my opinion that we needn't have Makefile gunk to support byacc.
> I don't think that cost is worth the marginal benefits of a) saving
> BSD people the trouble of building Bison, or b) finding latent bugs in
> our parsers that are somehow not exposed by Bison.

Note that the Makefile gunk is atrociously simple: you just need to 
make sure you have 
BISON=bison
somewhere in that Makefile

AND a second variable for java, like
REALLY_BISON=bison

People who want to build with yacc can then just write
make BISON=yacc
and be done with it, *UNLESS* you have LOTS more of gunk to foobar make 
variables (like cygnus configure may tend to do).

The only other thing that needs to be done is to use bison's -o option, or
bison -b option to decide the name of the output file, so that it is fully 
compatible with byacc.
I don't believe that something like:

parser.c: parser.y
	$(BISON) -o $@ parser.y

or like:
parser.c: parser.y
	$(BISON) -b parser parser.y

is utterly unreadable, do you ?

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]