Skip to content

Commit

Permalink
_build.sh: add missed picky warnings [ci skip]
Browse files Browse the repository at this point in the history
Found them in autotools builds. They were missing from
CMake in curl/libssh2. One of them was also missing from
autotools llvm/clang.

Ref: curl/curl#12324
Ref: libssh2/libssh2#1219
  • Loading branch information
vszakats committed Nov 15, 2023
1 parent 39c4ff2 commit 05a43f7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions _build.sh
Expand Up @@ -1095,9 +1095,9 @@ build_single_target() {
# builds with llvm/clang 15 and gcc 12.2:
# https://clang.llvm.org/docs/DiagnosticsReference.html
# https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html
_CFLAGS_GLOBAL_WPICKY='-pedantic -Wbad-function-cast -Wcast-align -Wconversion -Wdeclaration-after-statement -Wdouble-promotion -Wempty-body -Wendif-labels -Wenum-conversion -Wfloat-equal -Wignored-qualifiers -Winline -Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wno-format-nonliteral -Wno-long-long -Wno-multichar -Wno-sign-conversion -Wno-system-headers -Wpointer-arith -Wshadow -Wsign-compare -Wstrict-prototypes -Wtype-limits -Wundef -Wunused -Wunused-const-variable -Wvla -Wwrite-strings'
_CFLAGS_GLOBAL_WPICKY='-pedantic -Wbad-function-cast -Wcast-align -Wconversion -Wdeclaration-after-statement -Wdouble-promotion -Wempty-body -Wendif-labels -Wenum-conversion -Wfloat-equal -Wignored-qualifiers -Winline -Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wno-format-nonliteral -Wno-long-long -Wno-multichar -Wno-sign-conversion -Wno-system-headers -Wold-style-definition -Wpointer-arith -Wshadow -Wsign-compare -Wstrict-prototypes -Wtype-limits -Wundef -Wunused -Wunused-const-variable -Wvla -Wwrite-strings'
[ "${_CC}" = 'llvm' ] && _CFLAGS_GLOBAL_WPICKY+=' -Wassign-enum -Wcomma -Wextra-semi-stmt -Wmissing-variable-declarations -Wshift-sign-overflow -Wshorten-64-to-32'
[ "${_CC}" = 'gcc' ] && _CFLAGS_GLOBAL_WPICKY+=' -Walloc-zero -Warith-conversion -Warray-bounds=2 -Wduplicated-branches -Wduplicated-cond -Wformat-overflow=2 -Wformat-truncation=1 -Wformat=2 -Wmissing-parameter-type -Wno-pedantic-ms-format -Wnull-dereference -Wold-style-declaration -Wrestrict -Wshift-negative-value -Wshift-overflow=2 -Wstrict-aliasing=3 -fdelete-null-pointer-checks -ftree-vrp'
[ "${_CC}" = 'gcc' ] && _CFLAGS_GLOBAL_WPICKY+=' -Walloc-zero -Warith-conversion -Warray-bounds=2 -Wclobbered -Wduplicated-branches -Wduplicated-cond -Wformat-overflow=2 -Wformat-truncation=2 -Wformat=2 -Wmissing-parameter-type -Wno-pedantic-ms-format -Wnull-dereference -Wold-style-declaration -Wrestrict -Wshift-negative-value -Wshift-overflow=2 -Wstrict-aliasing=3 -fdelete-null-pointer-checks -ftree-vrp'

# for boringssl
export _STRIP_BINUTILS=''
Expand Down

0 comments on commit 05a43f7

Please sign in to comment.