diff options
Diffstat (limited to 'testing/firefox/fix-rust-target.patch')
-rw-r--r-- | testing/firefox/fix-rust-target.patch | 36 |
1 files changed, 22 insertions, 14 deletions
diff --git a/testing/firefox/fix-rust-target.patch b/testing/firefox/fix-rust-target.patch index c1b48d54bc..7dd760ca1d 100644 --- a/testing/firefox/fix-rust-target.patch +++ b/testing/firefox/fix-rust-target.patch @@ -1,16 +1,24 @@ --- a/build/moz.configure/rust.configure +++ b/build/moz.configure/rust.configure -@@ -127,10 +127,10 @@ - ('x86_64', 'OpenBSD'): 'x86_64-unknown-openbsd', - # Linux - ('aarch64', 'Linux'): 'aarch64-unknown-linux-gnu', -- ('arm', 'Linux'): 'armv7-unknown-linux-gnueabihf', -+ ('arm', 'Linux'): 'armv6-alpine-linux-musleabihf', - ('sparc64', 'Linux'): 'sparc64-unknown-linux-gnu', -- ('x86', 'Linux'): 'i686-unknown-linux-gnu', -- ('x86_64', 'Linux'): 'x86_64-unknown-linux-gnu', -+ ('x86', 'Linux'): 'i686-alpine-linux-musl', -+ ('x86_64', 'Linux'): 'x86_64-alpine-linux-musl', - # OS X - ('x86', 'OSX'): 'i686-apple-darwin', - ('x86_64', 'OSX'): 'x86_64-apple-darwin', +@@ -181,9 +181,11 @@ + die("Don't know how to translate {} for rustc".format( + host_or_target.alias)) + ++ fixed_alias = rustc_target.alias.replace("-unknown-", "-alpine-").replace("-gnu", "-musl") ++ + # Check to see whether our rustc has a reasonably functional stdlib + # for our chosen target. +- target_arg = '--target=' + rustc_target.alias ++ target_arg = '--target=' + fixed_alias + in_fd, in_path = mkstemp(prefix='conftest', suffix='.rs') + out_fd, out_path = mkstemp(prefix='conftest', suffix='.rlib') + os.close(out_fd) +@@ -220,7 +222,7 @@ + os.remove(out_path) + + # This target is usable. +- return rustc_target.alias ++ return fixed_alias + + return rust_target + |