mirror of
https://github.com/curl/curl.git
synced 2026-04-14 22:41:40 +03:00
build: exclude clang prereleases from compiler warning options
Starting with clang 18, stable clang releases start with minor version 1. Exclude pre-releases with minor version 0 from the compiler warning options for that major version. This fixes the build with Android NDK r29, which uses a prerelease version of clang 21 that doesn't know the new options yet. Closes #19566
This commit is contained in:
parent
1b48c6148a
commit
e9a973c513
2 changed files with 9 additions and 9 deletions
|
|
@ -937,11 +937,11 @@ AC_DEFUN([CURL_SET_COMPILER_WARNING_OPTS], [
|
|||
CURL_ADD_COMPILER_WARNINGS([tmp_CFLAGS], [cast-function-type-strict]) # with Apple clang it requires 16.0 or above
|
||||
fi
|
||||
dnl clang 20 or later
|
||||
if test "$compiler_num" -ge "2000"; then
|
||||
if test "$compiler_num" -ge "2001"; then
|
||||
CURL_ADD_COMPILER_WARNINGS([tmp_CFLAGS], [array-compare])
|
||||
fi
|
||||
dnl clang 21 or later
|
||||
if test "$compiler_num" -ge "2100"; then
|
||||
if test "$compiler_num" -ge "2101"; then
|
||||
CURL_ADD_COMPILER_WARNINGS([tmp_CFLAGS], [c++-hidden-decl])
|
||||
tmp_CFLAGS="$tmp_CFLAGS -Wno-implicit-void-ptr-cast"
|
||||
CURL_ADD_COMPILER_WARNINGS([tmp_CFLAGS], [tentative-definition-compat])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue