Bug 1686646 - In mozconfigs, don't set paths to tools configure can now find on its own. r=firefox-build-system-reviewers,dmajor

Differential Revision: https://phabricator.services.mozilla.com/D101721
This commit is contained in:
Mike Hommey 2021-01-15 04:33:09 +00:00
parent 4ed35480e2
commit 5552bc3c4a
32 changed files with 10 additions and 184 deletions

View File

@ -9,8 +9,6 @@ ac_add_options --enable-valgrind
. $topsrcdir/build/unix/mozconfig.asan
ac_add_options --disable-elf-hack
export DUMP_SYMS="${MOZ_FETCHES_DIR}/dump_syms/dump_syms"
# Package js shell.
export MOZ_PACKAGE_JSSHELL=1

View File

@ -13,8 +13,6 @@ ac_add_options --enable-valgrind
. $topsrcdir/build/unix/mozconfig.asan
ac_add_options --disable-elf-hack
export DUMP_SYMS="${MOZ_FETCHES_DIR}/dump_syms/dump_syms"
ac_add_options --disable-sandbox
ac_add_options --disable-profiling
ac_add_options --disable-warnings-as-errors

View File

@ -19,8 +19,6 @@ ac_add_options --enable-fuzzing
# globally in mozconfig.asan because it requires an unstable -Z flag.
export RUSTFLAGS="$RUSTFLAGS -Zsanitizer=address"
export DUMP_SYMS="${MOZ_FETCHES_DIR}/dump_syms/dump_syms"
# Include 'SourceRepository' in application.ini which
# is used by Pernosco to locate source
export MOZ_INCLUDE_SOURCE_INFO=1

View File

@ -7,10 +7,6 @@ ac_add_options --enable-debug
. $topsrcdir/build/mozconfig.wasm-sandboxing
# Use Clang as specified in manifest
export CC="$MOZ_FETCHES_DIR/clang/bin/clang"
export CXX="$MOZ_FETCHES_DIR/clang/bin/clang++"
# Save rust analysis (this requires unlocking the unstable features,
# which is done in the taskcluster task definition via RUSTC_BOOTSTRAP)
export RUSTFLAGS="-Zsave-analysis"

View File

@ -6,10 +6,6 @@ ac_add_options --enable-debug
. $topsrcdir/build/mozconfig.wasm-sandboxing
# Use Clang as specified in manifest
export CC="$MOZ_FETCHES_DIR/clang/bin/clang"
export CXX="$MOZ_FETCHES_DIR/clang/bin/clang++"
# Add the static checker
ac_add_options --enable-clang-plugin

View File

@ -14,8 +14,6 @@ ac_add_options --disable-elf-hack
# globally in mozconfig.asan because it requires an unstable -Z flag.
export RUSTFLAGS="$RUSTFLAGS -Zsanitizer=address"
export DUMP_SYMS="${MOZ_FETCHES_DIR}/dump_syms/dump_syms"
# Piggybacking UBSan for now since only a small subset of checks are enabled.
# A new build can be created when appropriate.
ac_add_options --enable-undefined-sanitizer

View File

@ -17,8 +17,6 @@ ac_add_options --disable-elf-hack
# globally in mozconfig.asan because it requires an unstable -Z flag.
export RUSTFLAGS="$RUSTFLAGS -Zsanitizer=address"
export DUMP_SYMS="${MOZ_FETCHES_DIR}/dump_syms/dump_syms"
# gold is required for libFuzzer to work properly
ac_add_options --enable-linker=gold

View File

@ -1,10 +0,0 @@
CARGO="${MOZ_FETCHES_DIR}/rustc/bin/cargo"
RUSTC="${MOZ_FETCHES_DIR}/rustc/bin/rustc"
RUSTDOC="${MOZ_FETCHES_DIR}/rustc/bin/rustdoc"
RUSTFMT="${MOZ_FETCHES_DIR}/rustc/bin/rustfmt"
CBINDGEN="${MOZ_FETCHES_DIR}/cbindgen/cbindgen"
NASM="${MOZ_FETCHES_DIR}/nasm/nasm"
CC="${MOZ_FETCHES_DIR}/clang/bin/clang"
CXX="${MOZ_FETCHES_DIR}/clang/bin/clang++"

View File

@ -7,8 +7,6 @@ ac_add_options --enable-optimize="-O2 -gline-tables-only"
. $topsrcdir/build/unix/mozconfig.tsan
ac_add_options --disable-elf-hack
export DUMP_SYMS="${MOZ_FETCHES_DIR}/dump_syms/dump_syms"
# Package js shell.
export MOZ_PACKAGE_JSSHELL=1

View File

@ -1,7 +0,0 @@
CARGO="${MOZ_FETCHES_DIR}/rustc/bin/cargo"
RUSTC="${MOZ_FETCHES_DIR}/rustc/bin/rustc"
RUSTDOC="${MOZ_FETCHES_DIR}/rustc/bin/rustdoc"
RUSTFMT="${MOZ_FETCHES_DIR}/rustc/bin/rustfmt"
CBINDGEN="${MOZ_FETCHES_DIR}/cbindgen/cbindgen"
NASM="${MOZ_FETCHES_DIR}/nasm/nasm"

View File

@ -19,24 +19,13 @@ export UPX="${MOZ_FETCHES_DIR}/upx-3.95-win64/upx.exe"
if [ -f "${UPX}" ]; then
chmod +x "${UPX}"
fi
export WINE=${MOZ_FETCHES_DIR}/wine/bin/wine64
mk_add_options "export PATH=${VSPATH}/VC/bin/Hostx64/x86:${MOZ_FETCHES_DIR}/nsis-3.01:${PATH}"
unset VC_PATH
fi
export WINCHECKSEC="${MOZ_FETCHES_DIR}/winchecksec/winchecksec"
if [ ! -f "${WINCHECKSEC}" ]; then
export WINCHECKSEC="${MOZ_FETCHES_DIR}/winchecksec/winchecksec.exe"
if [ ! -f "${WINCHECKSEC}" ]; then
unset WINCHECKSEC
fi
fi
export PDBSTR="${MOZ_FETCHES_DIR}/pdbstr/pdbstr.exe"
if [ -f "${PDBSTR}" ]; then
chmod +x "${PDBSTR}"
else
unset PDBSTR
pdbstr="${MOZ_FETCHES_DIR}/pdbstr/pdbstr.exe"
if [ -f "${pdbstr}" ]; then
chmod +x "${pdbstr}"
fi

View File

@ -13,9 +13,6 @@
# --enable-js-shell
# build/mozconfig.automation
# MOZ_AUTOMATION_ flags
# build/mozconfig.rust
# RUSTC
# CARGO
. "$topsrcdir/browser/config/mozconfigs/common"
export MOZ_PACKAGE_JSSHELL=1

View File

@ -19,7 +19,6 @@ export UPX="${MOZ_FETCHES_DIR}/upx-3.95-win64/upx.exe"
if [ -f "${UPX}" ]; then
chmod +x "${UPX}"
fi
export WINE=${MOZ_FETCHES_DIR}/wine/bin/wine64
mk_add_options "export PATH=${VSPATH}/VC/bin/Hostx64/arm64:${MOZ_FETCHES_DIR}/nsis-3.01:${PATH}"
mk_add_options "export WINEPATH=${VSPATH}/VC/bin/Hostx64/x64"
@ -27,17 +26,7 @@ unset VC_PATH
fi
export WINCHECKSEC="${MOZ_FETCHES_DIR}/winchecksec/winchecksec"
if [ ! -f "${WINCHECKSEC}" ]; then
export WINCHECKSEC="${MOZ_FETCHES_DIR}/winchecksec/winchecksec.exe"
if [ ! -f "${WINCHECKSEC}" ]; then
unset WINCHECKSEC
fi
fi
export PDBSTR="${MOZ_FETCHES_DIR}/pdbstr/pdbstr.exe"
if [ -f "${PDBSTR}" ]; then
chmod +x "${PDBSTR}"
else
unset PDBSTR
pdbstr="${MOZ_FETCHES_DIR}/pdbstr/pdbstr.exe"
if [ -f "${pdbstr}" ]; then
chmod +x "${pdbstr}"
fi

View File

@ -19,24 +19,13 @@ export UPX="${MOZ_FETCHES_DIR}/upx-3.95-win64/upx.exe"
if [ -f "${UPX}" ]; then
chmod +x "${UPX}"
fi
export WINE=${MOZ_FETCHES_DIR}/wine/bin/wine64
mk_add_options "export PATH=${VSPATH}/VC/bin/Hostx64/x64:${MOZ_FETCHES_DIR}/nsis-3.01:${PATH}"
unset VC_PATH
fi
export WINCHECKSEC="${MOZ_FETCHES_DIR}/winchecksec/winchecksec"
if [ ! -f "${WINCHECKSEC}" ]; then
export WINCHECKSEC="${MOZ_FETCHES_DIR}/winchecksec/winchecksec.exe"
if [ ! -f "${WINCHECKSEC}" ]; then
unset WINCHECKSEC
fi
fi
export PDBSTR="${MOZ_FETCHES_DIR}/pdbstr/pdbstr.exe"
if [ -f "${PDBSTR}" ]; then
chmod +x "${PDBSTR}"
else
unset PDBSTR
export pdbstr="${MOZ_FETCHES_DIR}/pdbstr/pdbstr.exe"
if [ -f "${pdbstr}" ]; then
chmod +x "${pdbstr}"
fi

View File

@ -13,9 +13,6 @@
# --enable-js-shell
# build/mozconfig.automation
# MOZ_AUTOMATION_ flags
# build/mozconfig.rust
# RUSTC
# CARGO
. "$topsrcdir/browser/config/mozconfigs/common"
export MOZ_PACKAGE_JSSHELL=1

View File

@ -1,14 +1,3 @@
export DUMP_SYMS="${MOZ_FETCHES_DIR}/dump_syms/dump_syms.exe"
RUSTC="${MOZ_FETCHES_DIR}/rustc/bin/rustc"
CARGO="${MOZ_FETCHES_DIR}/rustc/bin/cargo"
RUSTDOC="${MOZ_FETCHES_DIR}/rustc/bin/rustdoc"
RUSTFMT="${MOZ_FETCHES_DIR}/rustc/bin/rustfmt"
CBINDGEN="${MOZ_FETCHES_DIR}/cbindgen/cbindgen"
NASM="${MOZ_FETCHES_DIR}/nasm/nasm.exe"
WINCHECKSEC="${MOZ_FETCHES_DIR}/winchecksec/winchecksec.exe"
ac_add_options --target=x86_64-pc-mingw32
. $topsrcdir/build/win64/mozconfig.vs-latest

View File

@ -18,8 +18,6 @@ mk_add_options "export LD_LIBRARY_PATH=$MOZ_FETCHES_DIR/clang/lib"
# `browser/config/tooltool-manifests/macosx64/cross-releng.manifest`.
CROSS_SYSROOT=$topsrcdir/MacOSX10.12.sdk
export CC="$MOZ_FETCHES_DIR/clang/bin/clang"
export CXX="$MOZ_FETCHES_DIR/clang/bin/clang++"
export CFLAGS="$CFLAGS -fcrash-diagnostics-dir=${UPLOAD_PATH}"
export CXXFLAGS="$CXXFLAGS -fcrash-diagnostics-dir=${UPLOAD_PATH}"
export DSYMUTIL=$topsrcdir/build/macosx/llvm-dsymutil
@ -27,7 +25,6 @@ mk_add_options "export REAL_DSYMUTIL=$MOZ_FETCHES_DIR/llvm-dsymutil/bin/dsymutil
export MKFSHFS=$MOZ_FETCHES_DIR/hfsplus-tools/newfs_hfs
export DMG_TOOL=$MOZ_FETCHES_DIR/dmg/dmg
export HFS_TOOL=$MOZ_FETCHES_DIR/dmg/hfsplus
export DUMP_SYMS="$MOZ_FETCHES_DIR/dump_syms/dump_syms"
export HOST_CFLAGS="-g"
export HOST_CXXFLAGS="-g"

View File

@ -6,8 +6,6 @@
if [ -d "$MOZ_FETCHES_DIR/clang" ]; then
# mozilla-central based build
export CC=$MOZ_FETCHES_DIR/clang/bin/clang
export CXX=$MOZ_FETCHES_DIR/clang/bin/clang++
export DSYMUTIL=$MOZ_FETCHES_DIR/clang/bin/llvm-dsymutil
# Use an updated linker.
ldflags="-B$MOZ_FETCHES_DIR/cctools/bin"
@ -28,5 +26,3 @@ fi
if [ -z "$CXX" ]; then
export CXX=clang++
fi
export DUMP_SYMS="$MOZ_FETCHES_DIR/dump_syms/dump_syms"

View File

@ -6,7 +6,6 @@ fi
if [ -z "$USE_ARTIFACT" ]; then
if [ -n "$TASKCLUSTER_PGO_PROFILE_USE" ]; then
export LLVM_PROFDATA="$MOZ_FETCHES_DIR/clang/bin/llvm-profdata"
export MOZ_LTO=cross
ac_add_options --enable-profile-use=cross
ac_add_options --with-pgo-jarlog=${MOZ_FETCHES_DIR}/en-US.log

View File

@ -76,7 +76,7 @@ if test -n "$bucket"; then
# instruct sccache to fetch the credentials from the Auth service's awsS3Credentials endpoint, via the Taskcluster proxy.
mk_add_options "export AWS_IAM_CREDENTIALS_URL=http://taskcluster/auth/v1/aws/s3/read-write/${bucket}/?format=iam-role-compat"
fi
export CCACHE="$MOZ_FETCHES_DIR/sccache/sccache"
export CCACHE="sccache"
export SCCACHE_VERBOSE_STATS=1
# Workaround for https://github.com/mozilla/sccache/issues/459#issuecomment-618756635
mk_add_options "export SCCACHE_MAX_FRAME_LENGTH=50000000"

View File

@ -23,7 +23,6 @@ MOZ_REQUIRE_SIGNING=${MOZ_REQUIRE_SIGNING-0}
ac_add_options --enable-js-shell
. "$topsrcdir/build/mozconfig.nasm"
. "$topsrcdir/build/mozconfig.automation"
. "$topsrcdir/build/mozconfig.rust"
. "$topsrcdir/build/mozconfig.cache"

View File

@ -1,12 +0,0 @@
# 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/.
case "$(uname -s)" in
MINGW*)
export NASM=$MOZ_FETCHES_DIR/nasm/nasm.exe
;;
*)
export NASM=$MOZ_FETCHES_DIR/nasm/nasm
;;
esac

View File

@ -12,16 +12,9 @@ unset CXX
unset HOST_CC
unset HOST_CXX
unset LINKER
unset RUSTC
unset RUSTFLAGS
unset CARGO
unset RUSTDOC
unset RUSTFMT
unset CBINDGEN
unset DUMP_SYMS
unset TOOLCHAIN_PREFIX
unset BINDGEN_CFLAGS
unset LLVM_PROFDATA
unset ENABLE_CLANG_PLUGIN
unset MACOS_SDK_DIR
unset MACOS_PRIVATE_FRAMEWORKS_DIR
@ -33,16 +26,8 @@ unset MOZ_LTO
unset MOZ_STDCXX_COMPAT
unset MOZ_NO_PIE_COMPAT
unset NASM
# Don't unset this on Linux artifact builds so the artifact builds correctly
# package any Wasm sandboxed shared libraries.
if test `uname -s` != Linux; then
unset WASM_SANDBOXED_LIBRARIES
fi
unset WASM_CC
unset WASM_CXX
unset LUCETC
unset WASI_SYSROOT
unset PDBSTR
unset WINCHECKSEC

View File

@ -1,10 +1 @@
# Options to enable rust in automation builds.
# Tell configure to use the tooltool rustc.
RUSTC="$MOZ_FETCHES_DIR/rustc/bin/rustc"
CARGO="$MOZ_FETCHES_DIR/rustc/bin/cargo"
RUSTDOC="$MOZ_FETCHES_DIR/rustc/bin/rustdoc"
RUSTFMT="$MOZ_FETCHES_DIR/rustc/bin/rustfmt"
CBINDGEN="$MOZ_FETCHES_DIR/cbindgen/cbindgen"
ac_add_options --enable-rust-simd

View File

@ -5,9 +5,5 @@ base-toolchains*)
;;
*)
export WASM_SANDBOXED_LIBRARIES=graphite,ogg
export WASM_CC="${MOZ_FETCHES_DIR}/clang/bin/clang --target=wasm32-wasi"
export WASM_CXX="${MOZ_FETCHES_DIR}/clang/bin/clang++ --target=wasm32-wasi"
export LUCETC="${MOZ_FETCHES_DIR}/lucetc/lucetc"
export WASI_SYSROOT="${MOZ_FETCHES_DIR}/wasi-sysroot/share/wasi-sysroot"
;;
esac

View File

@ -2,8 +2,6 @@
# 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/.
export DUMP_SYMS="${MOZ_FETCHES_DIR}/dump_syms/dump_syms"
if [ -z "$USE_ARTIFACT" ]; then
if [ -n "$TASKCLUSTER_PGO_PROFILE_USE" ]; then
export MOZ_LTO=cross

View File

@ -1,7 +1,5 @@
. "$topsrcdir/build/unix/mozconfig.unix"
export DUMP_SYMS="${MOZ_FETCHES_DIR}/dump_syms/dump_syms"
case "$PERFHERDER_EXTRA_OPTIONS" in
base-toolchains*)
# We don't build against wayland for base-toolchain builds.

View File

@ -9,9 +9,6 @@ if [ -n "$FORCE_GCC" ]; then
mk_add_options "export PATH=$MOZ_FETCHES_DIR/gcc/bin:$PATH"
ac_add_options --with-clang-path=$MOZ_FETCHES_DIR/clang/bin/clang
else
CC="$MOZ_FETCHES_DIR/clang/bin/clang"
CXX="$MOZ_FETCHES_DIR/clang/bin/clang++"
# For some builds we don't want to have Clang based static-analysis activated
if [ -z "$DISABLE_CLANG_PLUGIN" ]; then
export ENABLE_CLANG_PLUGIN=1
@ -33,7 +30,6 @@ else
ac_add_options --enable-profile-use=cross
ac_add_options --with-pgo-jarlog=${MOZ_FETCHES_DIR}/en-US.log
ac_add_options --with-pgo-profile-path=${MOZ_FETCHES_DIR}/merged.profdata
export LLVM_PROFDATA="$MOZ_FETCHES_DIR/clang/bin/llvm-profdata"
fi
fi

View File

@ -10,8 +10,3 @@ ac_add_options --enable-application=browser
ac_add_options --enable-js-shell
. $topsrcdir/js/src/devtools/rootAnalysis/mozconfig.common
if [ -n "$AUTOMATION" ]; then
export CBINDGEN="${MOZ_FETCHES_DIR}/cbindgen/cbindgen"
export NASM="${MOZ_FETCHES_DIR}/nasm/nasm"
fi

View File

@ -37,10 +37,5 @@ CPPFLAGS="$CPPFLAGS $ANALYSIS_EXTRA_CFLAGS"
CXXFLAGS="$CXXFLAGS $ANALYSIS_EXTRA_CFLAGS"
if [ -n "$AUTOMATION" ]; then
export CARGO="${MOZ_FETCHES_DIR}/rustc/bin/cargo"
export RUSTC="${MOZ_FETCHES_DIR}/rustc/bin/rustc"
export RUSTDOC="${MOZ_FETCHES_DIR}/rustc/bin/rustdoc"
export RUSTFMT="${MOZ_FETCHES_DIR}/rustc/bin/rustfmt"
ac_add_options --with-clang-path="${MOZ_FETCHES_DIR}/clang/bin/clang"
fi

View File

@ -13,11 +13,6 @@ ac_add_options --enable-application=js
ac_add_options --enable-nspr-build
if [ -n "$AUTOMATION" ]; then
export CARGO="${MOZ_FETCHES_DIR}/rustc/bin/cargo"
export RUSTC="${MOZ_FETCHES_DIR}/rustc/bin/rustc"
export RUSTDOC="${MOZ_FETCHES_DIR}/rustc/bin/rustdoc"
export RUSTFMT="${MOZ_FETCHES_DIR}/rustc/bin/rustfmt"
mk_add_options MOZ_OBJDIR="${HAZARD_SHELL_OBJDIR}"
ac_add_options --with-clang-path="${MOZ_FETCHES_DIR}/clang/bin/clang"
fi

View File

@ -4,32 +4,18 @@
. "$topsrcdir/build/mozconfig.common"
# For Android builds in TaskCluster, the system image is Debian, and
# we use the Java JRE/JDK from the system. We use a custom clang for
# the host compiler. Make sure clang uses the c++ headers included with
# clang, rather than the system headers which leads to incompatibility
# later (when linking against the clang-provided libstdc++).
HOST_CC="$MOZ_FETCHES_DIR/clang/bin/clang --gcc-toolchain=$MOZ_FETCHES_DIR/clang"
HOST_CXX="$MOZ_FETCHES_DIR/clang/bin/clang++ --gcc-toolchain=$MOZ_FETCHES_DIR/clang"
# Build Fennec
ac_add_options --enable-application=mobile/android
ac_add_options --with-android-sdk="$MOZ_FETCHES_DIR/android-sdk-linux"
ac_add_options --with-gradle="$MOZ_FETCHES_DIR/android-gradle-dependencies/gradle-dist/bin/gradle"
export GRADLE_MAVEN_REPOSITORIES="file://$MOZ_FETCHES_DIR/android-gradle-dependencies/google","file://$MOZ_FETCHES_DIR/android-gradle-dependencies/jcenter","file://$MOZ_FETCHES_DIR/android-gradle-dependencies/gradle-plugins"
if [ -z "$NO_NDK" -a -z "$USE_ARTIFACT" ]; then
# We use our own clang instead of the NDK's clang.
CC="$MOZ_FETCHES_DIR/clang/bin/clang"
CXX="$MOZ_FETCHES_DIR/clang/bin/clang++"
CFLAGS="$CFLAGS -fcrash-diagnostics-dir=${UPLOAD_PATH}"
CXXFLAGS="$CXXFLAGS -fcrash-diagnostics-dir=${UPLOAD_PATH}"
ac_add_options --with-android-ndk="$MOZ_FETCHES_DIR/android-ndk"
# Make sure that any host binaries we build use whatever libraries clang
# linked against, rather than what's on the system.
mk_add_options "export LD_LIBRARY_PATH=$MOZ_FETCHES_DIR/clang/lib"
export DUMP_SYMS="$MOZ_FETCHES_DIR/dump_syms/dump_syms"
# Enable static analysis plugin
export ENABLE_CLANG_PLUGIN=1
fi
@ -42,7 +28,6 @@ ac_add_options --with-mozilla-api-keyfile=/builds/mozilla-fennec-geoloc-api.key
if [ -n "$TASKCLUSTER_PGO_PROFILE_USE" -a -z "$USE_ARTIFACT" ]; then
export MOZ_LTO=cross
export LLVM_PROFDATA="$MOZ_FETCHES_DIR/clang/bin/llvm-profdata"
ac_add_options --enable-profile-use=cross