From 8aa31bcf4bcfc934bea05bcb2c0ba9b7f5dc490b Mon Sep 17 00:00:00 2001 From: Andrey Lushnikov Date: Wed, 3 Aug 2022 09:52:54 -0700 Subject: [PATCH] devops: fix Firefox build on Ubuntu 22.04 arm64 (#16212) Turns out the weird compilation error is fixed if we use Clang 14 to compile. This is the same clang that would've been shipped in mozilla build toolchain. --- browser_patches/docker_build.sh | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/browser_patches/docker_build.sh b/browser_patches/docker_build.sh index 9a84c27a6b..519ccb6294 100755 --- a/browser_patches/docker_build.sh +++ b/browser_patches/docker_build.sh @@ -137,8 +137,9 @@ function ensure_docker_container { gcc \ unzip - # We will use clang-12 for all arm64 native builds. - if [[ "${BUILD_FLAVOR}" == *"-arm64" ]]; then + if [[ "${BUILD_FLAVOR}" == "firefox-ubuntu-22.04-arm64" ]]; then + apt-get install -y clang-14 + elif [[ "${BUILD_FLAVOR}" == *"-arm64" ]]; then apt-get install -y clang-12 fi @@ -208,6 +209,9 @@ elif [[ "$2" == "compile" ]]; then if [[ "${BUILD_FLAVOR}" == "webkit-ubuntu-18.04" ]]; then export CC=/usr/bin/gcc-8 export CXX=/usr/bin/g++-8 + elif [[ "${BUILD_FLAVOR}" == "firefox-ubuntu-22.04-arm64" ]]; then + export CC=/usr/bin/clang-14 + export CXX=/usr/bin/clang++-14 elif [[ "${BUILD_FLAVOR}" == *"-arm64" ]]; then export CC=/usr/bin/clang-12 export CXX=/usr/bin/clang++-12