From 107710e61831cf53f5549f9be23e2dcddc972daa Mon Sep 17 00:00:00 2001 From: Nikita Mikhaylov Date: Wed, 8 Sep 2021 15:06:15 +0000 Subject: [PATCH] save --- debian/rules | 4 ++-- docker/packager/binary/Dockerfile | 15 ++++----------- docker/packager/deb/Dockerfile | 12 ++++-------- docker/packager/packager | 2 +- docs/en/development/build-osx.md | 2 +- docs/ru/development/build-osx.md | 2 +- tests/ci/ci_config.json | 8 ++++---- 7 files changed, 17 insertions(+), 28 deletions(-) diff --git a/debian/rules b/debian/rules index 73d1f3d3b34..4562d24bec4 100755 --- a/debian/rules +++ b/debian/rules @@ -36,8 +36,8 @@ endif CMAKE_FLAGS += -DENABLE_UTILS=0 -DEB_CC ?= $(shell which gcc-10 gcc-9 gcc | head -n1) -DEB_CXX ?= $(shell which g++-10 g++-9 g++ | head -n1) +DEB_CC ?= $(shell which gcc-11 gcc-10 gcc-9 gcc | head -n1) +DEB_CXX ?= $(shell which g++-11 g++-10 g++-9 g++ | head -n1) ifdef DEB_CXX DEB_BUILD_GNU_TYPE := $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) diff --git a/docker/packager/binary/Dockerfile b/docker/packager/binary/Dockerfile index f5d496ce97f..05d1c565eed 100644 --- a/docker/packager/binary/Dockerfile +++ b/docker/packager/binary/Dockerfile @@ -41,8 +41,6 @@ RUN apt-get update \ ccache \ cmake \ curl \ - g++-10 \ - gcc-10 \ gdb \ git \ gperf \ @@ -104,15 +102,10 @@ RUN wget -nv "https://developer.arm.com/-/media/Files/downloads/gnu-a/8.3-2019.0 # Download toolchain for FreeBSD 11.3 RUN wget -nv https://clickhouse-datasets.s3.yandex.net/toolchains/toolchains/freebsd-11.3-toolchain.tar.xz -# NOTE: For some reason we have outdated version of gcc-10 in ubuntu 20.04 stable. -# Current workaround is to use latest version proposed repo. Remove as soon as -# gcc-10.2 appear in stable repo. -RUN echo 'deb http://archive.ubuntu.com/ubuntu/ focal-proposed restricted main multiverse universe' > /etc/apt/sources.list.d/proposed-repositories.list - -RUN apt-get update \ - && apt-get install gcc-10 g++-10 --yes - -RUN rm /etc/apt/sources.list.d/proposed-repositories.list && apt-get update +# NOTE: Seems like gcc-11 is too new for ubuntu20 repository +RUN add-apt-repository ppa:ubuntu-toolchain-r/test --yes \ + && apt-get update \ + && apt-get install gcc-11 g++-11 --yes COPY build.sh / diff --git a/docker/packager/deb/Dockerfile b/docker/packager/deb/Dockerfile index 22bba94f250..bcab87c925e 100644 --- a/docker/packager/deb/Dockerfile +++ b/docker/packager/deb/Dockerfile @@ -57,15 +57,11 @@ RUN apt-get update \ tzdata \ --yes --no-install-recommends -# NOTE: For some reason we have outdated version of gcc-10 in ubuntu 20.04 stable. -# Current workaround is to use latest version proposed repo. Remove as soon as -# gcc-10.2 appear in stable repo. -RUN echo 'deb http://archive.ubuntu.com/ubuntu/ focal-proposed restricted main multiverse universe' > /etc/apt/sources.list.d/proposed-repositories.list +# NOTE: Seems like gcc-11 is too new for ubuntu20 repository +RUN add-apt-repository ppa:ubuntu-toolchain-r/test --yes \ + && apt-get update \ + && apt-get install gcc-11 g++-11 --yes -RUN apt-get update \ - && apt-get install gcc-10 g++-10 --yes --no-install-recommends - -RUN rm /etc/apt/sources.list.d/proposed-repositories.list && apt-get update # This symlink required by gcc to find lld compiler RUN ln -s /usr/bin/lld-${LLVM_VERSION} /usr/bin/ld.lld diff --git a/docker/packager/packager b/docker/packager/packager index f37d64e9949..5bea9fafd12 100755 --- a/docker/packager/packager +++ b/docker/packager/packager @@ -205,7 +205,7 @@ if __name__ == "__main__": parser.add_argument("--build-type", choices=("debug", ""), default="") parser.add_argument("--compiler", choices=("clang-11", "clang-11-darwin", "clang-11-darwin-aarch64", "clang-11-aarch64", "clang-12", "clang-12-darwin", "clang-12-darwin-aarch64", "clang-12-aarch64", - "clang-11-freebsd", "clang-12-freebsd", "gcc-10"), default="clang-12") + "clang-11-freebsd", "clang-12-freebsd", "gcc-11"), default="clang-12") parser.add_argument("--sanitizer", choices=("address", "thread", "memory", "undefined", ""), default="") parser.add_argument("--unbundled", action="store_true") parser.add_argument("--split-binary", action="store_true") diff --git a/docs/en/development/build-osx.md b/docs/en/development/build-osx.md index 687e0179e07..91e4902d0d2 100644 --- a/docs/en/development/build-osx.md +++ b/docs/en/development/build-osx.md @@ -76,7 +76,7 @@ cd ClickHouse rm -rf build mkdir build cd build -cmake -DCMAKE_C_COMPILER=$(brew --prefix gcc)/bin/gcc-10 -DCMAKE_CXX_COMPILER=$(brew --prefix gcc)/bin/g++-10 -DCMAKE_BUILD_TYPE=RelWithDebInfo .. +cmake -DCMAKE_C_COMPILER=$(brew --prefix gcc)/bin/gcc-11 -DCMAKE_CXX_COMPILER=$(brew --prefix gcc)/bin/g++-11 -DCMAKE_BUILD_TYPE=RelWithDebInfo .. cmake --build . --config RelWithDebInfo cd .. ``` diff --git a/docs/ru/development/build-osx.md b/docs/ru/development/build-osx.md index 8d5d06a544c..bdc80322f34 100644 --- a/docs/ru/development/build-osx.md +++ b/docs/ru/development/build-osx.md @@ -74,7 +74,7 @@ $ /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/ $ rm -rf build $ mkdir build $ cd build - $ cmake -DCMAKE_C_COMPILER=$(brew --prefix gcc)/bin/gcc-10 -DCMAKE_CXX_COMPILER=$(brew --prefix gcc)/bin/g++-10 -DCMAKE_BUILD_TYPE=RelWithDebInfo -DENABLE_JEMALLOC=OFF .. + $ cmake -DCMAKE_C_COMPILER=$(brew --prefix gcc)/bin/gcc-11 -DCMAKE_CXX_COMPILER=$(brew --prefix gcc)/bin/g++-11 -DCMAKE_BUILD_TYPE=RelWithDebInfo -DENABLE_JEMALLOC=OFF .. $ cmake --build . --config RelWithDebInfo $ cd .. ``` diff --git a/tests/ci/ci_config.json b/tests/ci/ci_config.json index 26c8d560312..cbae9a86fdf 100644 --- a/tests/ci/ci_config.json +++ b/tests/ci/ci_config.json @@ -22,7 +22,7 @@ "with_coverage": false }, { - "compiler": "gcc-10", + "compiler": "gcc-11", "build-type": "", "sanitizer": "", "package-type": "binary", @@ -82,7 +82,7 @@ "with_coverage": false }, { - "compiler": "gcc-10", + "compiler": "gcc-11", "build-type": "", "sanitizer": "", "package-type": "deb", @@ -347,7 +347,7 @@ }, "Functional stateless tests (unbundled)": { "required_build_properties": { - "compiler": "gcc-10", + "compiler": "gcc-11", "package_type": "deb", "build_type": "relwithdebuginfo", "sanitizer": "none", @@ -551,7 +551,7 @@ }, "Unit tests release gcc": { "required_build_properties": { - "compiler": "gcc-10", + "compiler": "gcc-11", "package_type": "binary", "build_type": "relwithdebuginfo", "sanitizer": "none",