| | |
STL on Solaris with Forte 7.0 compiler
Please support our C++ advertiser: Intel Parallel Studio Home
![]() |
Hi,
I've been experimenting with STL on solaris with the 7.0 sun compiler. I am able to write programs using string, map, vector, list, etc. however, I am trying to use hash_map and can't get the most basic (ie hash_map<string,string> h; ) to compile. It appears that hash_map is not part of the regular include path, and I've tried to find it in other places in the compiler's directories. While I've found it, it doesn't seem to compile. Does anyone have any ideas about this (understandably obscure/solaris specific) problem?
CC -V
CC: Forte Developer 7 C++ 5.4 2002/03/09
Compile attempt:
I get the following warnings (many more, all roughly the same)
<< moderator edit: added [code][/code] tags -- though I'm not 100% sure about where I put them >>
I've been experimenting with STL on solaris with the 7.0 sun compiler. I am able to write programs using string, map, vector, list, etc. however, I am trying to use hash_map and can't get the most basic (ie hash_map<string,string> h; ) to compile. It appears that hash_map is not part of the regular include path, and I've tried to find it in other places in the compiler's directories. While I've found it, it doesn't seem to compile. Does anyone have any ideas about this (understandably obscure/solaris specific) problem?
CC -V
CC: Forte Developer 7 C++ 5.4 2002/03/09
C++ Syntax (Toggle Plain Text)
#include <algorithm> #include <hash_map> #include <string> using namespace std; int main() { hash_map<string,string> myMap; return 0; }
C++ Syntax (Toggle Plain Text)
155 |/export/SUNWspro> find . -name 'hash_map*' -print ./prod/include/CC/stlport4/hash_map.SUNWCCh ./prod/include/CC/stlport4/hash_map
C++ Syntax (Toggle Plain Text)
56 |/export/SUNWspro> find . -name '*stl*' -print ./prod/lib/stlport4 ./prod/lib/stlport4/libp/libstlport.a ./prod/lib/stlport4/libstlport.a ./prod/lib/stlport4/libstlport_dbg.a ./prod/lib/stlport4/libstlport.so.1 ./prod/lib/stlport4/v9/libstlport.so.1 ./prod/lib/stlport4/v9/libp/libstlport.a ./prod/lib/stlport4/v9/libstlport.a ./prod/lib/stlport4/v9/libstlport_dbg.a ./prod/include/CC/stlport4 ./prod/include/CC/stlport4/config/stl_confix.h ./prod/include/CC/stlport4/config/stl_solaris.h ./prod/include/CC/stlport4/config/stl_sunpro.h ./prod/include/CC/stlport4/config/stlcomp.h ./prod/include/CC/stlport4/stl ./prod/include/CC/stlport4/stl_user_config.h ./inventory/v10n1/SPROstl4h ./inventory/v10n1/SPROstl4a ./inventory/v10n1/SPROstl4o ./inventory/v10n1/SPROstl4x ./inventory/v10n1/SPROstl4y ./lib/stlport4 ./lib/stlport4/libstlport.so ./lib/stlport4/libstlport.so.1 ./lib/stlport4/v9/libstlport.so ./lib/stlport4/v9/libstlport.so.1
Compile attempt:
C++ Syntax (Toggle Plain Text)
/export/SUNWspro/bin/CC -w -c -I./ -I../libs -I/export/SUNWspro/prod/include/CC/stlport4 -g -D_DEBUG -D__SUNOS__ -c *.cpp /export/SUNWspro/bin/CC -Bdynamic -lsocket -lnsl -L/export/SUNWspro/lib/stlport4 -lstlport -lhoff *.o -o Test
I get the following warnings (many more, all roughly the same)
C++ Syntax (Toggle Plain Text)
ld: warning: symbol `std::basic_stringbuf<char,std::char_traits<char>,std::allocator<char> >::__vtbl' has differing sizes: (file /export/SUNWspro/lib/stlport4/libstlport.so value=0x40; file /export/SUNWspro/lib/libCstd.so value=0x3c); /export/SUNWspro/lib/stlport4/libstlport.so definition taken ld: warning: symbol `std::time_get_byname<wchar_t,std::istreambuf_iterator<wchar_t,std::char_traits<wchar_t> > >::__vtbl' has differing sizes: (file /export/SUNWspro/lib/stlport4/libstlport.so value=0x24; file /export/SUNWspro/lib/libCstd.so value=0x2c); /export/SUNWspro/lib/stlport4/libstlport.so definition taken ld: warning: symbol `std::num_get<char,std::istreambuf_iterator<char,std::char_traits<char> > >::__vtbl' has differing sizes: (file /export/SUNWspro/lib/stlport4/libstlport.so value=0x38; file /export/SUNWspro/lib/libCstd.so value=0x40); /export/SUNWspro/lib/stlport4/libstlport.so definition taken ld: warning: symbol `std::moneypunct_byname<char,false>::__vtbl' has differing sizes: (file /export/SUNWspro/lib/stlport4/libstlport.so value=0x30; file /export/SUNWspro/lib/libCstd.so value=0x38); /export/SUNWspro/lib/stlport4/libstlport.so definition taken ld: warning: symbol `std::ctype<char>::__vtbl' has differing sizes: (file /export/SUNWspro/lib/stlport4/libstlport.so value=0x2c; file /export/SUNWspro/lib/libCstd.so value=0x34); /export/SUNWspro/lib/stlport4/libstlport.so definition taken ld: warning: symbol `std::codecvt_byname<char,char,__mbstate_t>::__vtbl' has differing sizes: (file /export/SUNWspro/lib/stlport4/libstlport.so value=0x28; file /export/SUNWspro/lib/libCstd.so value=0x30); /export/SUNWspro/lib/stlport4/libstlport.so definition taken ld: warning: symbol `std::clog' has differing sizes: (file /export/SUNWspro/lib/stlport4/libstlport.so value=0x68; file /export/SUNWspro/lib/libCstd.so value=0x60);
![]() |
Similar Threads
- [C++] Opening functions for editing? (C++)
- What is the use of #define _REENTRANT in my code? (C++)
- Hopefully easy question about linking... (C++)
- 2038 Problem (C++)
- Problem with basic templates on GCC (C++)
- strtok_r() error on solaris 8 (C)
Other Threads in the C++ Forum
- Previous Thread: please help me
- Next Thread: Programming Prolog in C++
| Thread Tools | Search this Thread |
api array based beginner binary bitmap c++ c/c++ calculator char char* class code coding compile compiler console conversion count database delete deploy developer dll download dynamic dynamiccharacterarray email encryption error file forms fstream function functions game getline givemetehcodez google graph gui homeworkhelp homeworkhelper iamthwee ifstream input int java lib linkedlist linker list loop looping loops map math matrix memory multiple news node number numbertoword output parameter pointer problem program programming project proxy python random read recursion recursive reference rpg sorting string strings temperature template test text text-file tree url variable vector video visual visualstudio win32 windows winsock word wordfrequency wxwidgets






