Skip to content

Commit 48a2fe1

Browse files
committed
boringssl.sh: fix deprecation warning inside clang
``` /usr/lib/llvm-19/lib/clang/19/include/mm3dnow.h:16:2: error: "The <mm3dnow.h> header is deprecated, and 3dNow! intrinsics are unsupported. For other intrinsics, include <x86intrin.h>, instead." [-Werror,-W#warnings] 16 | #warning "The <mm3dnow.h> header is deprecated, and 3dNow! intrinsics are unsupported. For other intrinsics, include <x86intrin.h>, instead." | ^ 1 error generated. ``` https://github.com/curl/curl-for-win/actions/runs/11714432529/job/32629108727#step:3:4286
1 parent 992e8d2 commit 48a2fe1

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

boringssl.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ _VER="$1"
6666
[ "${CW_DEV_INCREMENTAL:-}" != '1' ] && rm -r -f "${_PKGDIR:?}" "${_BLDDIR:?}"
6767

6868
CFLAGS="-ffile-prefix-map=$(pwd)="
69+
CPPFLAGS=''
6970
LIBS='-lpthread' # for tests
7071
options=''
7172

@@ -107,6 +108,8 @@ _VER="$1"
107108
options+=' -DDISABLE_GO=ON'
108109
options+=' -DDISABLE_PERL=ON'
109110

111+
CPPFLAGS+=' -D_CLANG_DISABLE_CRT_DEPRECATION_WARNINGS'
112+
110113
# Patch out to avoid redefinition errors
111114
sed -i.bak 's/-D_WIN32_WINNT=_WIN32_WINNT_WIN7//g' ./CMakeLists.txt
112115
else
@@ -127,8 +130,8 @@ _VER="$1"
127130
# shellcheck disable=SC2086
128131
cmake -B "${_BLDDIR}" ${_CMAKE_GLOBAL} ${_CMAKE_CXX_GLOBAL} ${options} \
129132
'-DBUILD_SHARED_LIBS=OFF' \
130-
"-DCMAKE_C_FLAGS=${_CFLAGS_GLOBAL_CMAKE} ${_CFLAGS_GLOBAL} ${_CPPFLAGS_GLOBAL} ${CFLAGS} ${_LDFLAGS_GLOBAL} ${LIBS}" \
131-
"-DCMAKE_CXX_FLAGS=${_CFLAGS_GLOBAL_CMAKE} ${_CFLAGS_GLOBAL} ${_CPPFLAGS_GLOBAL} ${CFLAGS} ${_LDFLAGS_GLOBAL} ${LIBS} ${_CXXFLAGS_GLOBAL} ${_LDFLAGS_CXX_GLOBAL}"
133+
"-DCMAKE_C_FLAGS=${_CFLAGS_GLOBAL_CMAKE} ${_CFLAGS_GLOBAL} ${_CPPFLAGS_GLOBAL} ${CFLAGS} ${CPPFLAGS} ${_LDFLAGS_GLOBAL} ${LIBS}" \
134+
"-DCMAKE_CXX_FLAGS=${_CFLAGS_GLOBAL_CMAKE} ${_CFLAGS_GLOBAL} ${_CPPFLAGS_GLOBAL} ${CFLAGS} ${CPPFLAGS} ${_LDFLAGS_GLOBAL} ${LIBS} ${_CXXFLAGS_GLOBAL} ${_LDFLAGS_CXX_GLOBAL}"
132135
fi
133136

134137
cmake --build "${_BLDDIR}" # --verbose

0 commit comments

Comments
 (0)