Page 1 of 1
Anyone of STLport working
Posted: Thu Sep 15, 2005 11:16 am
by yulius
I'm trying to port an app that requires STL.
I've tried using the STL used by gcc and it barfs on me during link time because of the libstdc++.a is missing a bunch of stuff from libc.a
I'm currently trying to use STLport with no luck either.
Has anyone got any advice for me on how to get STL working?
Thanks for your time.
yulius
Posted: Sat Sep 17, 2005 3:48 am
by yulius
Nevermind. I got it working. I had to add an implementation of mblen, mbcstowcs, wcstombcs, mbctowc, and wctombc. If anyone needs to help just PM me. Thanks.
Posted: Sun Sep 18, 2005 3:56 pm
by yulius
ciddi3d asked me to post what i did to get stl working.
stlport is actually checked into the ps2dev subversion tree.
Code: Select all
% cd /usr/local/ps2dev/ps2sdk/ports
% svn co svn://svn.ps2dev.org/ps2/trunk/ps2sdk-ports/stlport
I had to edit my Makefile to add the following
Code: Select all
CFLAGS += -D_NOTHREADS -D_STLP_NO_EXCEPTIONS -D_STLP_USE_NEWALLOC -D_STLP_HAS_WCHAR_T -D_STLP_NO_IOSTREAMS -Dwint_t=int
INCLUDES = -I$(PS2SDK)/ports/stlport/stlport ....
If you don't need std::wstring support, you don't need _STLP_HAS_WCHAR_T. It was important for me to put the stlport include line in the front of all the includes.
After that, I had to implement multibye to wchar_t conversion functions. (wcstombs, etc...).
If anyone needs more detail let me know.