我正在创建我自己的工具链与我的铁锈构建。我需要将它与iOS架构交叉编译。当试图设置默认工具链或覆盖当前目录的工具链时,我将收到一个有关工具链名称的错误。以下是我创建这个新工具链所采取的步骤:
$ rustup show
Default host: x86_64-apple-darwin
error: toolchain 'ios' does not support components
info: caused by: invalid toolchain name: 'ios'我尝试过其他符合工具链命名约定的名称,但都没有效果:
$ rustup toolchain link stable-2016-07-19-x86_64-apple-ios $HOME/rustc-ios
error: invalid custom toolchain name: 'stable-2016-07-19-x86_64-apple-ios'
$ rustup toolchain link stable-x86_64-apple-ios $HOME/rustc-ios
error: invalid custom toolchain name: 'stable-x86_64-apple-ios'
$ rustup toolchain link x86_64-apple-ios $HOME/rustc-ios更新
至于方法2,当我进行货物构建时,我仍然看到编译器将Arm库与我为rustup工具链安装的目标(即,我在/user/test-user/src/test-生锈-lib/target/中为#1安装的目标)连接起来:
rustc src/lib.rs
--crate-name test-rust-crate
--crate-type staticlib
-g
--cfg
feature=\"no_network\"
--out-dir /Users/test-user/src/test-rust-lib/target/armv7-apple-ios/debug
--emit=dep-info,link
--target armv7-apple-ios
-L dependency=/Users/test-user/src/test-rust-lib/target/armv7-apple-ios/debug
-L dependency=/Users/test-user/src/test-rust-lib/target/armv7-apple-ios/debug/deps
--extern serde_json=/Users/test-user/src/test-rust-lib/target/armv7-apple-ios/debug/deps/libserde_json-55921106e25a0359.rlib
--extern serde=/Users/test-user/src/test-rust-lib/target/armv7-apple-ios/debug/deps/libserde-e281201342afb4d4.rlib
--extern time=/Users/test-user/src/test-rust-lib/target/armv7-apple-ios/debug/deps/libtime-750bfdd52feafcb7.rlib
--extern libc=/Users/test-user/src/test-rust-lib/target/armv7-apple-ios/debug/deps/liblibc-1f3392fe1afd1313.rlib
--extern murmur3=/Users/test-user/src/test-rust-lib/target/armv7-apple-ios/debug/deps/libmurmur3-ab9a44fb20fb9fad.rlib
--extern quick_error=/Users/test-user/src/test-rust-lib/target/armv7-apple-ios/debug/deps/libquick_error-729eced693f2612d.rlib
--extern url=/Users/test-user/src/test-rust-lib/target/armv7-apple-ios/debug/deps/liburl-4690728b1e11fab3.rlib难道不应该把Arm库从我建造的铁锈中拉出来吗?
发布于 2016-07-20 18:38:35
我怀疑您在rustup show中看到的行为是与该特定命令相关的rustup中的一个bug。我要提出了一个问题去调查它。
在使用rustup link和rustup override配置自定义工具链之后尝试使用自定义工具链进行构建时会发生什么?
https://stackoverflow.com/questions/38466493
复制相似问题