summaryrefslogtreecommitdiffstats
path: root/build/moz.configure
diff options
context:
space:
mode:
Diffstat (limited to 'build/moz.configure')
-rw-r--r--build/moz.configure/headers.configure1
-rw-r--r--build/moz.configure/init.configure9
-rw-r--r--build/moz.configure/rust.configure7
-rw-r--r--build/moz.configure/toolchain.configure6
-rw-r--r--build/moz.configure/warnings.configure15
5 files changed, 13 insertions, 25 deletions
diff --git a/build/moz.configure/headers.configure b/build/moz.configure/headers.configure
index 5332c7365f..a50a911c4b 100644
--- a/build/moz.configure/headers.configure
+++ b/build/moz.configure/headers.configure
@@ -8,6 +8,7 @@
check_header("stdint.h")
have_inttypes = check_header("inttypes.h")
+
# Assume we have ansi C header files available.
set_define("STDC_HEADERS", True)
diff --git a/build/moz.configure/init.configure b/build/moz.configure/init.configure
index 87120573a0..bfb878aebb 100644
--- a/build/moz.configure/init.configure
+++ b/build/moz.configure/init.configure
@@ -739,11 +739,10 @@ def real_target(value, host, shell, project, application):
project = project[0]
if not value:
if project == "mobile/android":
- target_cpu, target_system = (
- ("aarch64", "android")
- if host.cpu == "aarch64"
- else ("arm", "androideabi")
- )
+ target_cpu, target_system = {
+ "aarch64": ("aarch64", "android"),
+ "x86_64": ("x86_64", "android"),
+ }.get(host.cpu, ("arm", "androideabi"))
return split_triplet(f"{target_cpu}-unknown-linux-{target_system}")
if project == "mobile/ios":
return split_triplet("aarch64-apple-ios")
diff --git a/build/moz.configure/rust.configure b/build/moz.configure/rust.configure
index 7a2fd1ae70..acac34ec05 100644
--- a/build/moz.configure/rust.configure
+++ b/build/moz.configure/rust.configure
@@ -766,17 +766,14 @@ def cargo_incremental(
set_config("CARGO_INCREMENTAL", cargo_incremental)
-@depends(rust_compile_flags, "--enable-warnings-as-errors", rustc_info)
-def rust_flags(compile_flags, warnings_as_errors, rustc_info):
+@depends(rust_compile_flags, "--enable-warnings-as-errors")
+def rust_flags(compile_flags, warnings_as_errors):
warning_flags = []
# Note that cargo passes --cap-lints warn to rustc for third-party code, so
# we don't need a very complicated setup.
if warnings_as_errors:
warning_flags.append("-Dwarnings")
- # Work around https://github.com/rust-lang/rust/issues/84428
- if rustc_info.version >= "1.52":
- warning_flags.append("-Aproc-macro-back-compat")
else:
warning_flags.extend(("--cap-lints", "warn"))
diff --git a/build/moz.configure/toolchain.configure b/build/moz.configure/toolchain.configure
index 5ab79daf24..0d0249b215 100644
--- a/build/moz.configure/toolchain.configure
+++ b/build/moz.configure/toolchain.configure
@@ -100,7 +100,7 @@ with only_when(host_is_osx | target_is_osx):
)
def mac_sdk_min_version():
- return "14.2"
+ return "14.4"
@depends(
"--with-macos-sdk",
@@ -782,9 +782,7 @@ def msvs_version(vc_compiler_version):
# be set for GYP on Windows.
if vc_compiler_version >= Version("19.30"):
return "2022"
- if vc_compiler_version >= Version("19.20"):
- return "2019"
- configure_error("Only Visual Studio 2019 or newer are supported")
+ configure_error("Only Visual Studio 2022 or newer are supported")
return ""
diff --git a/build/moz.configure/warnings.configure b/build/moz.configure/warnings.configure
index 9340c9e6ab..b33ede9fbb 100644
--- a/build/moz.configure/warnings.configure
+++ b/build/moz.configure/warnings.configure
@@ -36,9 +36,6 @@ add_warning("-W3", when=depends(c_compiler)(lambda c: c.type == "clang-cl"))
# catch implicit truncation of enum values assigned to smaller bit fields
check_and_add_warning("-Wbitfield-enum-conversion")
-# catches deprecated implicit capture of `this` in lambdas.
-check_and_add_warning("-Wdeprecated-this-capture", cxx_compiler)
-
# catches bugs, e.g. "if (c); foo();", few false positives
add_warning("-Wempty-body")
@@ -98,19 +95,15 @@ check_and_add_warning("-Wno-range-loop-analysis")
# Enable some C++20 compat warnings. We can remove these flags after we compile
# as C++20 (bug 1768116), because they will be enabled by default:
-check_and_add_warning("-Wc++2a-compat", cxx_compiler)
check_and_add_warning("-Wcomma-subscript", cxx_compiler)
check_and_add_warning("-Wenum-compare-conditional")
check_and_add_warning("-Wenum-float-conversion")
check_and_add_warning("-Wvolatile", cxx_compiler)
-# Downgrade some C++20 warnings-as-errors to warnings that we can fix after we
-# compile as C++20 (bug 1768116). They don't need to block upgrading to C++20.
-check_and_add_warning("-Wno-error=deprecated", cxx_compiler)
-check_and_add_warning("-Wno-error=deprecated-anon-enum-enum-conversion", cxx_compiler)
-check_and_add_warning("-Wno-error=deprecated-enum-enum-conversion", cxx_compiler)
-check_and_add_warning("-Wno-error=deprecated-pragma", cxx_compiler)
-check_and_add_warning("-Wno-error=deprecated-this-capture", cxx_compiler)
+# Disable some C++20 errors to be fixed in bugs 1791958, 1791955, and 1775161.
+check_and_add_warning("-Wno-deprecated-anon-enum-enum-conversion", cxx_compiler)
+check_and_add_warning("-Wno-deprecated-enum-enum-conversion", cxx_compiler)
+check_and_add_warning("-Wno-deprecated-this-capture", cxx_compiler)
# catches possible misuse of the comma operator
check_and_add_warning("-Wcomma", cxx_compiler)