overdrivenpotato / rust-psp

Rust on PSP. Panic and allocation support. Access PSP system libraries.
Other
589 stars 31 forks source link

linking with `rust-lld`failed #102

Closed FloVanGH closed 2 years ago

FloVanGH commented 2 years ago

Hi,

I'm currently working on a PR to bump up the embedded-graphics version to 0.7.1. I tried to compile the embedded-graphics example with cargo psp on macOS and on manjaro linux. On both I get the error linking with rust-lld failed ... rust-lld: error undefined ymbol: fmodf.

overdrivenpotato commented 2 years ago

Hi, thanks for reporting this issue. Oddly I can't replicate it on my end (macOS Big Sur, rust nightly 2021-08-05). In order to debug this:

  1. What's your rustc --version?
  2. Make sure you test like this to confirm everything is fresh: git clone ... && cd rust-psp/examples/embedded-graphics && cargo psp (note the cargo psp subcommand)
FloVanGH commented 2 years ago

Thanks for your response.

What's your rustc --version?

rustc 1.56.0-nightly (2f07ae408 2021-08-05)

Make sure you test like this to confirm everything is fresh: git clone ... && cd rust-psp/examples/embedded-graphics && cargo psp (note the cargo psp subcommand)

That's exactly how I have done it.

FloVanGH commented 2 years ago

The same issue also on Windows 10

FloVanGH commented 2 years ago

I checked now also the repo without my changes and it works. It looks like it has to do with the updated embedded-graphics crate.

FloVanGH commented 2 years ago

The compiler has only this issue if there a .draw call inside of the code.

FloVanGH commented 2 years ago

Code to test: https://github.com/FloVanGH/rust-psp

FloVanGH commented 2 years ago

fixed, was an issue with embedded-graphics