Looks like some build systems (like libgphoto2 one) doesn't enable it by default. Maybe would be interesting to enabling always if the option is available in configure
Thanks a lot
Not sure if it's a good idea to enable this by default, because there may be additional configure scripts in subdirectories:
"Source trees often contain multiple packages with a top-level configure script that uses the AC_CONFIG_SUBDIRS macro (see Subdirectories). Because the packages generally support different --with-package and --enable-feature options, the GNU Coding Standards say they must accept unrecognized options without halting. Even a warning message is undesirable here, so AC_CONFIG_SUBDIRS automatically disables the warnings."
And, how is that currently being handled for the other configure options that are being passed when available (like dependency-tracking options if I don't misremember)?
Or are you referring to the warnings that would be shown for that additional configure scripts under subdirs?
(In reply to Pacho Ramos from comment #2)
> Or are you referring to the warnings that would be shown for that additional
> configure scripts under subdirs?
Yes, this one. How can we know that it wouldn't cause spurious warnings for such subdir configure scripts?
Well, currently that is the case for a lot of ebuilds :/ --enable-option-checking is the default for most of them. Even, the QA warning about that errors relies on that behavior and, then, we need to set QA_CONFIGURE_OPTIONS
This is a problem, indeed, I am not sure if QA_CONFIGURE_OPTIONS could be included in eapi or we should have a way to ignore (regarding QA warnings) them when they come from other configure than main one :|
But, currently, the situation in the tree is pretty inconsistent: most of packages default to show warnings and, then, we go with QA_CONFIGURE_OPTIONS when we find false-positives... but a few packages don't enable that checks and, then, QA warnings won't be shown and that info will be lost :(
Not sure if would be possible to pass "--enable-option-checking" when the option is found in main configure AND no other configure is found in sources directory :/
I don't think we ought to do this. Reading 'info autoconf':
1. the thing is on by default,
2. it gets disabled automatically when you use AC_CONFIG_SUBDIRS (the case ulm considered),
3. it can be explicitly disabled via AC_DISABLE_OPTION_CHECKING.
So I'd dare say it gets disabled only when there's a reason for it. Those should not be common cases so you may try to re-enable them per-package.
Forcing it on by default would likely need copying most of the auto-disable logic from autoconf which is just pointless :).
Closing, because I believe that --enable-option-checking is not suitable as a general default.
If you disagree, please discuss it in the -dev mailing list.