C++ Frontend Tales

All | Boost | General | Loki
« How to build Boost... | Main

20080130 Wednesday January 30, 2008

Boost and Sun Studio 12

The latest released version of Boost 1.34.1 can be compiled under 32-bit mode by Sun Studio 12 from scratch without necessity to apply any additional patches.

If you want to use Boost 1.34.1 under 64-bit mode you still have to apply a small fix to Boost build script.

Upcoming Boost 1.35 can be compiled by Sun Studio 12 under both 32/64-bit mode without any patches.

bjam toolset=sun stdlib=sun-stlport stage # 32-bit mode
bjam toolset=sun stdlib=sun-stlport address-model=64 stage # 64-bit mode

As for advantages over Studio 11 and/or gcc:


Permalink Comments [3]
Trackback URL: http://blogs.sun.com/sga/entry/boost_and_sun_studio_12
Comments:

I have tried to compile 1.34.1 under SunStudio 12 and am getting errors, such as, "libs/python/src/object/class.cpp", line 458: Error: Overloading ambiguity between "boost::python::api::getattr<boost::python::scope, char[11], boost::python::str>(const boost::python::scope&, const char(&)[11], const boost::python::str&)" and "boost::python::api::getattr(const boost::python::api::object&, const char*, const boost::python::api::object&)".
"libs/python/src/object/class.cpp", line 571: Warning: String literal converted to char* in formal argument format in call to PyObject_CallFunction(_object*, char*, ...).
"libs/python/src/object/class.cpp", line 581: Warning: String literal converted to char* in formal argument format in call to PyObject_CallFunction(_object*, char*, ...).
"libs/python/src/object/class.cpp", line 590: Warning: String literal converted to char* in formal argument format in call to PyObject_CallFunction(_object*, char*, ...).
"libs/python/src/object/class.cpp", line 599: Warning: String literal converted to char* in formal argument format in call to PyObject_CallFunction(_object*, char*, ...).
"libs/python/src/object/class.cpp", line 618: Warning: String literal converted to char* in initialization.
"libs/python/src/object/class.cpp", line 619: Warning: String literal converted to char* in initialization.
1 Error(s) and 15 Warning(s) detected.

"CC" -library=stlport4 -fast -mt -DBOOST_ALL_NO_LIB=1 -DBOOST_PYTHON_SOURCE -DBOOST_PYTHON_STATIC_LIB -DNDEBUG -I"." -I"/usr/include/python2.4" -c -o "bin.v2/libs/python/build/sun/release/link-static/stdlib-sun-stlport/threading-multi/class.o" "libs/python/src/object/class.cpp"

Are these errors normal, for which I need to fix?

Thanks,

Jim

Posted by Jim Langston on February 04, 2008 at 07:52 PM MSK #

This bug has been fixed in the patch-01 for Sun Studio 12.

Posted by Simon Atanasyan on February 04, 2008 at 09:43 PM MSK #

Thanks Simon, that did the trick, rebuilt, no errors

Posted by Jim Langston on February 04, 2008 at 10:43 PM MSK #

Post a Comment:

Name:
E-Mail:
URL:

Your Comment:

HTML Syntax: NOT allowed