GonoszTopi, thanks for the quick fix

I tried to add "const" to fix key issue #1, but failed:
"StatTree.h", line 243: Error: Could not find a match for std::list<CStatTreeItemBase*>::sort(bool(const CStatTreeItemBase*,const CStatTreeItemBase*)) needed in CStatTreeItemBase::ReSortChildren().
The answer from Sun Studio guy is as below:
"The sort member function is missing from the list template in the default libCstd. Use STLport if you need better conformance to the C++ standard. Or modify the code to use the global sort function instead.
More details in the C++ FAQ:
http://docs.sun.com/source/820-4155/c++_faq.html#LibComp5See Questions 3, 4, 5, and 6 in section D."
I feel that it's not easy to use STLport now as that means all the C++ libraries will need to build with it. btw, this comment also applies to the key issue #2.
To address your comments in the last post:
1. The comment from Sun Studio guy: "Similar problem as above. In this case, vector::assign is supposed to be a template, but is not a template in libCstd. If you use STLport the code should compile. " I change the code to:
+ const CServer** lbegin = result.begin();
+ CInternalList::const_iterator sbegin = m_servers.begin();
+ for (int i = 0; i < m_servers.size(); i++, lbegin++, sbegin++)
+ result.insert(lbegin, *sbegin);
The similar issue is with vector::insert:
"DownloadQueue.cpp", line 1468: Error: Could not find a match for std::vector<CPartFile*>::insert(CPartFile**, std::deque<CPartFile*>::iterator, std::deque<CPartFile*>::iterator) needed in CDownloadQueue::ObserverAdded(CObserver<CQueueEvent<CPartFile*>>*). Also update it as the attached patch.
How do you think of this?
2. Here is a link to explain the detail of the difference between libCstd and libstlport:
http://developers.sun.com/solaris/articles/cmp_stlport_libCstd.html. Example of the build error is as below:
"/opt/SUNWspro/prod/include/CC/Cstd/./map", line 251: Error: Multiple declaration for std::map<const std::string, CUPnPArgument*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPArgument*>>>::insert(const std::pair<const std::string, CUPnPArgument*>&).
"UPnPBase.h", line 161: Where: While specializing "std::map<const std::string, CUPnPArgument*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPArgument*>>>".
"UPnPBase.h", line 161: Where: Specialized in CXML_List<CUPnPArgument, &s_argument, &s_argumentList>.
"UPnPBase.h", line 301: Where: Specialized in non-template code.
"/opt/SUNWspro/prod/include/CC/Cstd/./map", line 251: Error: Multiple declaration for std::map<const std::string, CUPnPAllowedValue*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPAllowedValue*>>>::insert(const std::pair<const std::string, CUPnPAllowedValue*>&).
"UPnPBase.h", line 161: Where: While specializing "std::map<const std::string, CUPnPAllowedValue*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPAllowedValue*>>>".
"UPnPBase.h", line 161: Where: Specialized in CXML_List<CUPnPAllowedValue, &s_allowedValue, &s_allowedValueList>.
"UPnPBase.h", line 344: Where: Specialized in non-template code.
"/opt/SUNWspro/prod/include/CC/Cstd/./map", line 251: Error: Multiple declaration for std::map<const std::string, CUPnPAction*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPAction*>>>::insert(const std::pair<const std::string, CUPnPAction*>&).
"UPnPBase.h", line 161: Where: While specializing "std::map<const std::string, CUPnPAction*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPAction*>>>".
"UPnPBase.h", line 161: Where: Specialized in CXML_List<CUPnPAction, &s_action, &s_actionList>.
"UPnPBase.h", line 374: Where: Specialized in non-template code.
"/opt/SUNWspro/prod/include/CC/Cstd/./map", line 251: Error: Multiple declaration for std::map<const std::string, CUPnPStateVariable*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPStateVariable*>>>::insert(const std::pair<const std::string, CUPnPStateVariable*>&).
"UPnPBase.h", line 161: Where: While specializing "std::map<const std::string, CUPnPStateVariable*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPStateVariable*>>>".
"UPnPBase.h", line 161: Where: Specialized in CXML_List<CUPnPStateVariable, &s_stateVariable, &s_serviceStateTable>.
"UPnPBase.h", line 375: Where: Specialized in non-template code.
"/opt/SUNWspro/prod/include/CC/Cstd/./map", line 251: Error: Multiple declaration for std::map<const std::string, CUPnPDevice*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPDevice*>>>::insert(const std::pair<const std::string, CUPnPDevice*>&).
"UPnPBase.h", line 161: Where: While specializing "std::map<const std::string, CUPnPDevice*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPDevice*>>>".
"UPnPBase.h", line 161: Where: Specialized in CXML_List<CUPnPDevice, &s_device, &s_deviceList>.
"UPnPBase.h", line 482: Where: Specialized in non-template code.
"/opt/SUNWspro/prod/include/CC/Cstd/./map", line 251: Error: Multiple declaration for std::map<const std::string, CUPnPService*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPService*>>>::insert(const std::pair<const std::string, CUPnPService*>&).
"UPnPBase.h", line 161: Where: While specializing "std::map<const std::string, CUPnPService*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPService*>>>".
"UPnPBase.h", line 161: Where: Specialized in CXML_List<CUPnPService, &s_service, &s_serviceList>.
"UPnPBase.h", line 483: Where: Specialized in non-template code.
"/opt/SUNWspro/prod/include/CC/Cstd/./map", line 251: Error: Multiple declaration for std::map<const std::string, CUPnPRootDevice*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPRootDevice*>>>::insert(const std::pair<const std::string, CUPnPRootDevice*>&).
"UPnPBase.h", line 561: Where: While specializing "std::map<const std::string, CUPnPRootDevice*, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPRootDevice*>>>".
"UPnPBase.h", line 561: Where: Specialized in non-template code.
"/opt/SUNWspro/prod/include/CC/Cstd/./map", line 251: Error: Multiple declaration for std::map<const std::string, CUPnPPortMapping, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPPortMapping>>>::insert(const std::pair<const std::string, CUPnPPortMapping>&).
"UPnPBase.h", line 563: Where: While specializing "std::map<const std::string, CUPnPPortMapping, std::less<const std::string>, std::allocator<std::pair<const std::string, CUPnPPortMapping>>>".
"UPnPBase.h", line 563: Where: Specialized in non-template code.
Also found another build error for "amulesig_out.AddLine(wxT(VERSION " " SVNDATE));" in amule.cpp. Not sure how to fix that.
Anyway, attachment is all the changes I did to make it compile.