[WIP] cpubits: initial crate
As discussed in #824, adds a crate with the intent of it providing heuristics for selecting whether 32-bit or 64-bit backends have optimal codegen for a given target, with optional overrides.
The intended use of this crate is in build-dependencies, where it can emit a cfg attribute (e.g. --cfg cpubits="64") if one hasn't been explicitly specified already, and all gating on 32-bit vs 64-bit backends can simply use the cfg attribute.
Wow, what is this (unrelated) failure in cpufeatures when building on macOS:
https://github.com/RustCrypto/utils/actions/runs/3868175503/jobs/6593444420#step:6:13
= note: ld: in /Users/runner/.rustup/toolchains/1.40.0-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libgetopts-1988d9ef7be544ff.rlib(rust.metadata.bin), archive member 'rust.metadata.bin' with length 198423 is not mach-o or llvm bitcode file '/Users/runner/.rustup/toolchains/1.40.0-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libgetopts-1988d9ef7be544ff.rlib'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Also this in zeroize:
https://github.com/RustCrypto/utils/actions/runs/3868175523/jobs/6593445047#step:7:13
= note: ld: in /Users/runner/.rustup/toolchains/1.51.0-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libgetopts-a912bc5fe101e362.rlib(lib.rmeta), archive member 'lib.rmeta' with length 203848 is not mach-o or llvm bitcode file '/Users/runner/.rustup/toolchains/1.51.0-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib/libgetopts-a912bc5fe101e362.rlib'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
@tarcieri Do you still plan to move forward with this PR? It got quite stale and we probably can close it.
Yes