Is there a way to represent arm64e in cfg(...)?

⚓ Rust    📅 2025-04-29    👤 surdeus    👁️ 4      

surdeus

Warning

This post was published 114 days ago. The information described in this article may have changed.

I found that arm64e-apple-* triplet is NOT representable for cfg(...) in config.toml. For example, to config apple platform but NOT arm64e abi/env/arch using

[target.`cfg(all(target_vendor="apple",not(target_arch="arm64e")))`] 

is invalid.
No matter target_{arch,env,abi}="arm64e" is used.

arm64e is an arch/env/abi?

arm64e-apple-darwin means arch arm64e, vendor apple, os darwin; but searching for arm64e definition which saying it's NOT arch but an apple-specific arm64 abi specification with some extension. So it should be treated like gnu/musl abi/env?

How to represent arm64e accurately in cfg(...) target?

1 post - 1 participant

Read full topic

🏷️ rust_feed