mirror of
https://github.com/curl/curl.git
synced 2026-08-24 20:43:47 +03:00
configure: conditionally enable pedantic-errors
Enable pedantic-errors for GCC >= 5 with --enable-werror. Before GCC 5, pedantic-errors was synonymous to -Werror=pedantic [0], which is still the case for clang [1]. With GCC 5, it became complementary [2]. Also fix a resulting error in acinclude.m4 as main's return type was missing, which is illegal in C99. [0] https://gcc.gnu.org/onlinedocs/gcc-4.9.0/gcc/Warning-Options.html [1] https://clang.llvm.org/docs/UsersManual.html#options-to-control-error-and-warning-messages [2] https://gcc.gnu.org/onlinedocs/gcc-5.1.0/gcc/Warning-Options.html Closes https://github.com/curl/curl/pull/2747
This commit is contained in:
parent
a829c4b25e
commit
d5c0351055
2 changed files with 8 additions and 1 deletions
|
|
@ -2158,7 +2158,7 @@ AC_DEFUN([CURL_VERIFY_RUNTIMELIBS], [
|
|||
dnl point also is available run-time!
|
||||
AC_MSG_CHECKING([run-time libs availability])
|
||||
CURL_RUN_IFELSE([
|
||||
main()
|
||||
int main()
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue