[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How can Autoconf help with the transition to stricter compilation de
From: |
Bruno Haible |
Subject: |
Re: How can Autoconf help with the transition to stricter compilation defaults? |
Date: |
Thu, 17 Nov 2022 22:35:44 +0100 |
Paul Eggert wrote:
> > AC_CHECK_FUNC *should not* just probe for linkability of a symbol
>
> ... Autoconf cannot
> be expected to know every signature of every function in every library.
Clang will surely not acquire knowledge about "every library", right,
only about the C library according to relevant standards (ISO C, POSIX)?
> ... In the meantime if
> Clang becomes pickier by default it would be helpful if there were a
> well-defined way to shut off Clang's pickiness.
To me it seems the problem is not Clang's pickiness, but rather the
assumptions that it makes about the target environment. There is a
documented way to ask Clang and GCC "assume a free-standing implementation,
not an environment that has the ISO C / POSIX / LSB / ... functions":
1) -ffreestanding [1][2]
2) -fno-builtin
Can we assume that these options will continue to work?
If so, all Autoconf needs to do is to pass these options to the compiler
in AC_CHECK_FUNC checks. Then we don't need to add knowledge about each
of the hundreds of standard libc functions into Autoconf.
Bruno
[1] https://clang.llvm.org/docs/ClangCommandLineReference.html
[2] https://gcc.gnu.org/onlinedocs/gcc-12.2.0/gcc/C-Dialect-Options.html
- Re: How can Autoconf help with the transition to stricter compilation defaults?, (continued)
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Sam James, 2022/11/16
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Michael Matz, 2022/11/16
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Jonathan Wakely, 2022/11/16
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Michael Matz, 2022/11/16
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Jonathan Wakely, 2022/11/16
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Paul Eggert, 2022/11/16
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Jeffrey Walton, 2022/11/16
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Paul Eggert, 2022/11/17
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Zack Weinberg, 2022/11/16
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Paul Eggert, 2022/11/17
- Re: How can Autoconf help with the transition to stricter compilation defaults?,
Bruno Haible <=
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Paul Eggert, 2022/11/17
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Michael Matz, 2022/11/17
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Aaron Ballman, 2022/11/15
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Sam James, 2022/11/15
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Zack Weinberg, 2022/11/15
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Sam James, 2022/11/15
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Bob Friesenhahn, 2022/11/15
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Paul Eggert, 2022/11/12
- Re: How can Autoconf help with the transition to stricter compilation defaults?, Jason Merrill, 2022/11/17
Re: How can Autoconf help with the transition to stricter compilation defaults?, Sam James, 2022/11/11