e4745f7c5e
...as required by clang-cl: > [build CXX] avmedia/source/framework/modeltools.cxx > In file included from C:/lo64/core/avmedia/source/framework/modeltools.cxx:29: > In file included from C:/lo64/core/external/boost/include\boost/exception/diagnostic_information.hpp:23: > In file included from C:/lo64/core/workdir/UnpackedTarball/boost\boost/exception/diagnostic_information.hpp:17: > C:/lo64/core/workdir/UnpackedTarball/boost\boost/exception/info.hpp(103,13): error: 'boost::exception_detail::error_info_container_impl' has virtual functions but non-virtual destructor [-Werror,-Wnon-virtual-dtor] > ~error_info_container_impl() throw() > ^ > C:/lo64/core/workdir/UnpackedTarball/boost\boost/exception/info.hpp(172,21): error: delete called on non-final 'boost::exception_detail::error_info_container_impl' that has virtual functions but non-virtual destructor [-Werror,-Wdelete-non-virtual-dtor] > delete this; > ^ > 2 errors generated. Change-Id: I026f7e72d027becb68ac9118616ed6d8f2ecbf80 Reviewed-on: https://gerrit.libreoffice.org/41225 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
63 lines
2.3 KiB
Bash
Executable file
63 lines
2.3 KiB
Bash
Executable file
#!/bin/bash
|
|
#
|
|
# This file is part of the LibreOffice project.
|
|
#
|
|
# This Source Code Form is subject to the terms of the Mozilla Public
|
|
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
#
|
|
|
|
# generate a bunch of dummy headers that wrap the crappy boost headers and
|
|
# suppress a myriad of warnings; requires GCC's #include_next extension
|
|
|
|
set -euo pipefail
|
|
IFS=$'\n\t'
|
|
|
|
GENDIR=${SRCDIR}/external/boost/include
|
|
|
|
rm -rf ${GENDIR}
|
|
mkdir ${GENDIR}
|
|
|
|
# note: clucene contains a copy of half of boost, so ignore it too
|
|
# note: firebird contains a copy of half of boost, so ignore it too
|
|
|
|
cat <(cd ${SRCDIR} && git grep -h '^# *include') \
|
|
<(find ${WORKDIR}/UnpackedTarball/ -mindepth 1 -maxdepth 1 -type d \
|
|
| grep -v boost \
|
|
| grep -v clucene \
|
|
| grep -v firebird \
|
|
| xargs grep -hr '^# *include') \
|
|
| grep -o '\bboost.*\.\(h\|hpp\|ipp\)' \
|
|
| sort | uniq \
|
|
| while read -r HEADER; do
|
|
mkdir -p "$(dirname ${GENDIR}/${HEADER})"
|
|
cat > "${GENDIR}/${HEADER}" << _EOF
|
|
/* generated by $0, do not edit! */
|
|
#pragma once
|
|
#pragma GCC diagnostic push
|
|
#pragma GCC diagnostic ignored "-Wunknown-pragmas" /* first! for clang */
|
|
#pragma GCC diagnostic ignored "-Wpragmas" /* second! for GCC */
|
|
#pragma GCC diagnostic ignored "-Wunknown-warning-option" // third! for Clang 5
|
|
#pragma GCC diagnostic ignored "-Wdelete-non-virtual-dtor"
|
|
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
|
#pragma GCC diagnostic ignored "-Wextra"
|
|
#pragma GCC diagnostic ignored "-Wignored-qualifiers"
|
|
#pragma GCC diagnostic ignored "-Wimplicit-fallthrough"
|
|
#pragma GCC diagnostic ignored "-Winvalid-constexpr"
|
|
#pragma GCC diagnostic ignored "-Wnon-virtual-dtor"
|
|
#pragma GCC diagnostic ignored "-Wplacement-new"
|
|
#pragma GCC diagnostic ignored "-Wreturn-type"
|
|
#pragma GCC diagnostic ignored "-Wshadow"
|
|
#pragma GCC diagnostic ignored "-Wstrict-aliasing"
|
|
#pragma GCC diagnostic ignored "-Wtautological-constant-out-of-range-compare"
|
|
#pragma GCC diagnostic ignored "-Wtype-limits"
|
|
#pragma GCC diagnostic ignored "-Wundef"
|
|
#pragma GCC diagnostic ignored "-Wunused-local-typedefs"
|
|
#pragma GCC diagnostic ignored "-Wunused-macros"
|
|
#pragma GCC diagnostic ignored "-Wunused-parameter"
|
|
#pragma GCC diagnostic ignored "-Wunused-variable"
|
|
#include_next <${HEADER}>
|
|
#pragma GCC diagnostic pop
|
|
_EOF
|
|
done
|
|
|