[Top][All Lists]

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

Re: AC_ARG_ENABLE and checking for unrecognized switches

From: Tom Tromey
Subject: Re: AC_ARG_ENABLE and checking for unrecognized switches
Date: Fri, 15 Mar 2019 07:02:31 -0600
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux)

>> I use AC_ARG_ENABLE to create a number of different --enable switches.
>> I noticed when I accidentally mistyped the <something> in --enable-
>> <something>, ./configure didn't bail on the unrecognized switch.

Eric> This is by design; the GNU Coding Standards wants projects to be
Eric> aggregatable, such that someone else could write a larger project that
Eric> uses yours as a subdirectory, and takes additional --enable switches
Eric> that some (but not all) of its subprojects understand.  Being able to
Eric> blindly pass down all of its switches to subprojects, without having to
Eric> worry about which projects care about which switches, makes this easier.

I think there are a few wrinkles:

My reading is that there *is* checking by default, but it is turned off
if you have a subdir configure, but then can be turned back on again by
the user.

Doing something better here would be nice (though maybe difficult) since
in my experience I often forget the exact spelling... like, is it
"--disable-multilib" or "--disable-multilibs"?  Or is it "--with-python"
or "--enable-python"?


reply via email to

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