I am currently trying to compile a crate on a centos7 machine and I get the following error:
error: unknown codegen option: `embed-bitcode`
error: could not compile `env_logger`
(My first report: here, but it has nothing to do with the env_logger crate)
Apparently, the rust compiler gets an argument --embed-bitcode=no which it does not understand. This happens with rustc 1.48.0 and 1.47.0. I am not cross-compiling anything.
I'm getting the xact same error while trying to cross compile FIrefox on Ubuntu for Solaris SPARC. The error pops up while executing mach build but I can reproduce it by executing that one command directly from the command line:
michele@michele-VirtualBox:/usr/sparcv9-solaris/solaris/cross/bin$ /home/michele/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/bin/rustc - --crate-name ___ --print=file-names -C opt-level=2 -C debuginfo=2 --cap-lints warn -C -Cembed-bitcode=yes -C codegen-units=1 --target sparcv9-sun-solaris --crate-type bin --crate-type rlib --crate-type dylib --crate-type cdylib --crate-type staticlib --crate-type proc-macro --print=sysroot --print=cfg
error: unknown codegen option: -Cembed-bitcode
michele@michele-VirtualBox:~/mozilla-unified$ rustc --version && cargo --version
rustc 1.49.0 (e1884a8e3 2020-12-29)
cargo 1.49.0 (d00d64df9 2020-12-05)
I note that if I remove the "-C" immediately before "-Cembed-bitcode" the command works. What does this -C do? Any ideas?