Re: Conditional AC_CHECK_HEADER

2023-02-06 Thread Sam James
> On 6 Feb 2023, at 06:00, Paul Eggert wrote: > > On 2023-02-04 09:26, Russ Allbery wrote: >> The principle that one should always use an AS_* construct if one exists >> rather than regular shell constructs could probably be documented more >> aggressively. > > I gave that a shot by installing

Re: Conditional AC_CHECK_HEADER

2023-02-05 Thread Florian Weimer
* Russ Allbery: > Florian Weimer writes: > >> I want to submit this upstream. Is there are some explanation somewhere >> why it's not permitted to invoke AC_CHECK_HEADER under shell conditional >> statement? I couldn't find it in the manual. > > It's documented under AS_IF: > > https://www.gnu.

Re: Conditional AC_CHECK_HEADER

2023-02-05 Thread Paul Eggert
On 2023-02-04 09:26, Russ Allbery wrote: The principle that one should always use an AS_* construct if one exists rather than regular shell constructs could probably be documented more aggressively. I gave that a shot by installing the attached.From 84e4582f534d5e1ded05547c54ca518e31604b1e Mon

Re: Conditional AC_CHECK_HEADER

2023-02-05 Thread Paul Eggert
On 2023-02-04 05:42, Florian Weimer wrote: Is there are some explanation somewhere why it's not permitted to invoke AC_CHECK_HEADER under shell conditional statement? I couldn't find it in the manual. The restriction is documented here: https://www.gnu.org/savannah-checkouts/gnu/autoconf/manu

Re: Conditional AC_CHECK_HEADER

2023-02-04 Thread Russ Allbery
Florian Weimer writes: > I want to submit this upstream. Is there are some explanation somewhere > why it's not permitted to invoke AC_CHECK_HEADER under shell conditional > statement? I couldn't find it in the manual. It's documented under AS_IF: https://www.gnu.org/savannah-checkouts/gnu/au

Re: Conditional AC_CHECK_HEADER

2023-02-04 Thread Sam James
> On 4 Feb 2023, at 13:42, Florian Weimer wrote: > > The x11vnc configure.ac script contains this: > > | if test "x$with_v4l" != "xno"; then > | AC_CHECK_HEADER(linux/videodev.h, > | [AC_DEFINE(HAVE_LINUX_VIDEODEV_H)],,) > | fi > > This is the point where all the default header check are inse

Conditional AC_CHECK_HEADER

2023-02-04 Thread Florian Weimer
The x11vnc configure.ac script contains this: | if test "x$with_v4l" != "xno"; then | AC_CHECK_HEADER(linux/videodev.h, | [AC_DEFINE(HAVE_LINUX_VIDEODEV_H)],,) | fi This is the point where all the default header check are inserted, so when the condition is false, they are not