cc-rs
cc-rs copied to clipboard
Not sourcing `target-cpu`
If TARGET = Some(thumbv7em-none-eabihf) then it is correctly mapped to:
https://github.com/rust-lang/cc-rs/blob/1ca8b2af7a19faa4d090cc5deba3f7a0cd721174/src/lib.rs#L2406-L2412
However, if there is a provided CARGO_ENCODED_RUSTFLAGS = Some(-Ctarget-cpu=cortex-m7) then the aforementioned cc flags are wrong and should be -march=armv7e-m+fp.dp -mfloat-abi=hard -mfpu=auto.
I would accept a PR to fix this
It's a bit more complicated now that I've looked into it, but I'll try and put something together.