Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to Compile due to linking to stdc++ #1

Open
Moadao opened this issue Mar 21, 2024 · 3 comments
Open

Unable to Compile due to linking to stdc++ #1

Moadao opened this issue Mar 21, 2024 · 3 comments

Comments

@Moadao
Copy link

Moadao commented Mar 21, 2024

Context:
I've been tinkering with STM32 devices lately and diving into compiling CXX code in an environment without the standard library (no std). This repository had a promising example, but I hit a snag during compilation.

Problem:
As I followed the example in the repository for running CXX code on STM32 devices without the standard library, I ran into a little hiccup. The compilation process threw up an error message that said:

rust-lld: error: unable to find library -lstdc++

It seems like the linker (rust-lld) is having a tough time tracking down the standard C++ library (libstdc++). My guess is there might be a small hiccup in the configuration somewhere causing it to slip through the cracks.

Additional Information:

  • Compiler Version: 1.72.0
@libesz
Copy link
Owner

libesz commented Mar 21, 2024

Hey! Unfortunately you are right. This repository is a demo of this compilation issue. 😢 I have no any promising updates.
The repo is referred here: dtolnay/cxx#1286

@Moadao
Copy link
Author

Moadao commented Mar 22, 2024

That's disappointing. It seems like the cxx team might not be aware of this issue. Perhaps by raising the problem again, they'll release an update that enables cxx to function in a no_std environment. I'll do my best to shed some light on this and keep you posted if there's any progress. 😊

@libesz
Copy link
Owner

libesz commented Mar 22, 2024

Sounds good! Thanks. 🤞

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants