smlinux/heavybuilds/firefox/fix-rust-target.patch
PktSurf b84f8a4a14 Upgraded base/chrony to version 4.4
Upgraded base/cmake to version 3.27.7
Upgraded base/glib to 2.78.1
Upgraded base/libvpx to 1.10.0
Added AMDGPU and BPF build targets to base/llvm
Added a patch to extra/ffmpegthumbnailer for fixing a build error against ffmpeg 5.X versions
Upgraded gtk/libwnck3 to 3.36.0
Upgraded heavybuilds/firefox to 115.5.0
Added some patches to base/wpa-supplicant
Added glslang to xorg
2023-12-10 23:23:41 +05:30

31 lines
913 B
Diff

Allow us to just set RUST_TARGEt ourselves instead of hacking around in mozilla's
weird custom build system...
--- a/build/moz.configure/rust.configure
+++ b/build/moz.configure/rust.configure
@@ -225,7 +225,9 @@
data.setdefault(key, []).append(namespace(rust_target=t, target=info))
return data
-
+@imports('os')
+@imports(_from='mozbuild.util', _import='ensure_unicode')
+@imports(_from='mozbuild.util', _import='system_encoding')
def detect_rustc_target(
host_or_target, compiler_info, arm_target, rust_supported_targets
):
@@ -340,13 +342,13 @@
return None
- rustc_target = find_candidate(candidates)
+ rustc_target = os.environ['RUST_TARGET']
if rustc_target is None:
die("Don't know how to translate {} for rustc".format(host_or_target.alias))
- return rustc_target
+ return ensure_unicode(rustc_target, system_encoding)
@imports('os')