Forum Discussion
Altera_Forum
Honored Contributor
20 years agoC++ Standard Libraries
Hi! I have started working with C++ in my project. Creating classes and using own objects is no problem, Now I want to use objects of the standard library, e.g. class "string", but I get lots of...
Altera_Forum
Honored Contributor
20 years agoActually, eCos supports STL just fine; this is a function of GCC and not eCos. It's just that the "-nostdlib" flag makes it not link the standard C++ library by default.
You need to add the "-lstdc++" flag to your link command, and it needs to be after all your .o files and any other libraries that use the STL.