autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: --with-foo= vs. FOO=${FOO:-foo_default}


From: Paul Eggert
Subject: Re: --with-foo= vs. FOO=${FOO:-foo_default}
Date: Sat, 7 Sep 2002 12:32:12 -0700 (PDT)

> From: Troy Cauble <address@hidden>
> Date: Fri, 06 Sep 2002 11:54:52 -0400

> I'm porting a large, full-featured, autoconf-based project to an
> embedded linux system where certain features cannot be supported.
> The C/C++ files will require a -D flag to control some ifdefs.  The
> Makefile.am's will require either ifeq statements or @MY_FLAGS@
> style substitutions.
> 
> Is the best way to trigger all this with --with, --enable, or something else?

What I would do is to leave the current project source alone as much
as possible.  You can do that by invoking its "configure" with the
proper environment.  For example, you could create a new file
"configure-embedded" that looks something like this:

#! /bin/sh
export ac_cv_func_fnmatch_gnu=yes
export ac_cv_func_setmode_dos=no
[etc...]
exec ./configure "$@"

and then run "./configure-embedded" rather than plain "./configure".

>From this point of view, there's really no difference between
environment variables and fancy "--with" options.  (It's just that the
environment variables conform to the GNU coding standards, and the
fancy "--with" options don't.  :-)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]