Repository navigation
Nightly fails to compile core with Xargo on thumbv6m due to missing AtomicPtr #45802
Copy link
Copy link
Closed
Closed
Copy link
Labels
C-bugCategory: This is a bug.Category: This is a bug.E-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.O-ArmTarget: 32-bit Arm processors (armv6, armv7, thumb...), including 64-bit Arm in AArch32 stateTarget: 32-bit Arm processors (armv6, armv7, thumb...), including 64-bit Arm in AArch32 stateT-libs-api[DEPRECATED; DO NOT USE][DEPRECATED; DO NOT USE]
Description
Here is the verbose output:
RUSTFLAGS="-C`` link-arg=-Tlayout_lpc1114.ld" xargo build --release --target thumbv6m-none-eabi --features "lpc1114" --verbose
+ "rustc" "--print" "sysroot"
+ "rustc" "--print" "target-list"
+ RUSTFLAGS="-C link-arg=-Tlayout_lpc1114.ld --sysroot /home/juergen/.xargo -Z force-unstable-if-unmarked"
+ "cargo" "build" "--release" "--manifest-path" "/tmp/xargo.jJOPpAK3kHEu/Cargo.toml" "--target" "thumbv6m-none-eabi" "-v" "-p" "core"
Compiling core v0.0.0 (file:///home/juergen/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/src/libcore)
Running `rustc --crate-name core /home/juergen/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/src/libcore/lib.rs --crate-type lib --emit=dep-info,link -C opt-level=3 -C metadata=30eb9fdc2904bb34 -C extra-filename=-30eb9fdc2904bb34 --out-dir /tmp/xargo.jJOPpAK3kHEu/target/thumbv6m-none-eabi/release/deps --target thumbv6m-none-eabi -L dependency=/tmp/xargo.jJOPpAK3kHEu/target/thumbv6m-none-eabi/release/deps -L dependency=/tmp/xargo.jJOPpAK3kHEu/target/release/deps -C link-arg=-Tlayout_lpc1114.ld --sysroot /home/juergen/.xargo -Z force-unstable-if-unmarked`
error[E0412]: cannot find type `AtomicPtr` in this scope
--> /home/juergen/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/src/libcore/sync/atomic.rs:931:26
|
931 | impl<T> From<*mut T> for AtomicPtr<T> {
| ^^^^^^^^^ not found in this scope
error: aborting due to previous error
error: Could not compile `core`.
Caused by:
process didn't exit successfully: `rustc --crate-name core /home/juergen/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/src/libcore/lib.rs --crate-type lib --emit=dep-info,link -C opt-level=3 -C metadata=30eb9fdc2904bb34 -C extra-filename=-30eb9fdc2904bb34 --out-dir /tmp/xargo.jJOPpAK3kHEu/target/thumbv6m-none-eabi/release/deps --target thumbv6m-none-eabi -L dependency=/tmp/xargo.jJOPpAK3kHEu/target/thumbv6m-none-eabi/release/deps -L dependency=/tmp/xargo.jJOPpAK3kHEu/target/release/deps -C link-arg=-Tlayout_lpc1114.ld --sysroot /home/juergen/.xargo -Z force-unstable-if-unmarked` (exit code: 101)
error: `"cargo" "build" "--release" "--manifest-path" "/tmp/xargo.jJOPpAK3kHEu/Cargo.toml" "--target" "thumbv6m-none-eabi" "-v" "-p" "core"` failed with exit code: Some(101)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
C-bugCategory: This is a bug.Category: This is a bug.E-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.O-ArmTarget: 32-bit Arm processors (armv6, armv7, thumb...), including 64-bit Arm in AArch32 stateTarget: 32-bit Arm processors (armv6, armv7, thumb...), including 64-bit Arm in AArch32 stateT-libs-api[DEPRECATED; DO NOT USE][DEPRECATED; DO NOT USE]
Activity
kennytm commentedon Nov 6, 2017
cc @strake #45610
All the
impl From<T> for Atomic<T>needs to have#[cfg(target_has_atomic)].Freyskeyd commentedon Nov 6, 2017
If @strake is busy I can try it.
kennytm commentedon Nov 7, 2017
(Note: affects msp430 as well)
fix core for targets with max-atomic-width = 0
japaric commentedon Nov 8, 2017
I saw no open PR to fix this so I opened #45882. (I hope no one minds)
work around rust-lang/rust#45802
work around rust-lang/rust#45802
Rollup merge of rust-lang#45882 - japaric:gh45802, r=kennytm