On Fri, 30 Aug 2002, Steve Fink wrote: > On Fri, Aug 30, 2002 at 03:49:07PM -0400, Andy Dougherty wrote:
> > Thus what I'd really like to do here is generate two different makefile > > fragments, depending on whether or not the user is using bison or (yacc or > > byacc). With the current substitution-driven makefile.in system, it's not > > obvious to me how best to do that. Anyone have any suggestions? > > Well, you could extend the current system with something like the > attached patch. Ahh. This is quite clever. I'm going to file this away for possible future use. For cases (such as this) where we're trying to emulate a simple well-known interface (e.g. bison -o) with a clunkier multi-line version (e.g. yacc, with it's y.tab.? files) it makes a lot of sense. For more complex cases (e.g. perl5's building a shared libperl on OS/2 or cygwin) I'm less certain. In those cases, it might still be more convenient to conditionally include different fragments in a makefile. It was with an eye to such future issues that I posted my original question. The imcc issue just gave me a convenient concrete context. Of course, once parrot is self-bootstrapping, we merely need to ensure that its build command understands conditionals somewhat like GNU make's. For imcc, I think I'm going to suggest sidestepping the issue and just shipping the pre-generated files (longer message and associated patch in progress). -- Andy Dougherty [EMAIL PROTECTED] Dept. of Physics Lafayette College, Easton PA 18042