Closed
Description
I'm new to the rust embedded world and I am trying to get the example provided in the docs working. After running xargo rustc --target msp430-none-elf -- -C link-arg=-nostartfiles -C link-arg=-Tlink.x
I get the error:
Compiling mymsp v0.1.0 (/home/matthew/personalProjects/rust/msp/mymsp)
error: linking with `msp430-elf-gcc` failed: exit code: 1
|
= note: "msp430-elf-gcc" "-Wl,--eh-frame-hdr" "-L" "/home/matthew/.xargo/lib/rustlib/msp430-none-elf/lib" "/home/matthew/personalProjects/rust/msp/mymsp/target/msp430-none-elf/debug/deps/mymsp-5e8f1dc7e4a97be6.17zmi0j3rsei05y0.rcgu.o" "-o" "/home/matthew/personalProjects/rust/msp/mymsp/target/msp430-none-elf/debug/deps/mymsp-5e8f1dc7e4a97be6" "-Wl,--gc-sections" "-nodefaultlibs" "-L" "/home/matthew/personalProjects/rust/msp/mymsp/target/msp430-none-elf/debug/deps" "-L" "/home/matthew/personalProjects/rust/msp/mymsp/target/debug/deps" "-L" "/home/matthew/personalProjects/rust/msp/mymsp/target/msp430-none-elf/debug/build/msp430-rt-1543454d2d69ddf3/out" "-L" "/home/matthew/.xargo/lib/rustlib/msp430-none-elf/lib" "-Wl,--start-group" "-Wl,-Bstatic" "/home/matthew/personalProjects/rust/msp/mymsp/target/msp430-none-elf/debug/deps/libpanic_msp430-009ff554b3c69afe.rlib" "/home/matthew/personalProjects/rust/msp/mymsp/target/msp430-none-elf/debug/deps/libmsp430_rt-b547c370e166624e.rlib" "/home/matthew/personalProjects/rust/msp/mymsp/target/msp430-none-elf/debug/deps/libr0-077d58e20f73b032.rlib" "/home/matthew/personalProjects/rust/msp/mymsp/target/msp430-none-elf/debug/deps/libmsp430-c6aa6fbcc43ff67f.rlib" "/home/matthew/personalProjects/rust/msp/mymsp/target/msp430-none-elf/debug/deps/libbare_metal-5d885d7e97dad07e.rlib" "/home/matthew/.xargo/lib/rustlib/msp430-none-elf/lib/libcore-f34c7f19eb54f014.rlib" "-Wl,--end-group" "/home/matthew/.xargo/lib/rustlib/msp430-none-elf/lib/libcompiler_builtins-735d55bb87ed4287.rlib" "-nostartfiles" "-Tlink.x" "-Wl,-Bdynamic"
= note: /opt/msp430-gcc/bin/../lib/gcc/msp430-elf/9.2.0/../../../../msp430-elf/bin/ld: unrecognized option '--eh-frame-hdr'
/opt/msp430-gcc/bin/../lib/gcc/msp430-elf/9.2.0/../../../../msp430-elf/bin/ld: use the --help option for usage information
collect2: error: ld returned 1 exit status
error: aborting due to previous error
error: could not compile `mymsp`.
To learn more, run the command again with --verbose.
As far as I can tell this flag is not supported by msp430-elf-gcc but I also cannot find what code is adding this flag so I could attempt to remove it.
My msp430-elf-gcc --version is:
msp430-elf-gcc (Mitto Systems Limited - msp430-gcc 9.2.0.50) 9.2.0
My active toolchain is:
nightly-x86_64-unknown-linux-gnu (default)
rustc 1.46.0-nightly (346aec9b0 2020-07-11)
Metadata
Metadata
Assignees
Labels
No labels