Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --- /dev/null 2012-07-21 17:36:20.000000000 +0200
- +++ boost/tools/build/v2/tools/sun-stdcxx4.jam 2012-07-21 19:43:52.462932182 +0200
- @@ -0,0 +1,142 @@
- +# Copyright (C) Christopher Currie 2003. Permission to copy, use,
- +# modify, sell and distribute this software is granted provided this
- +# copyright notice appears in all copies. This software is provided
- +# "as is" without express or implied warranty, and with no claim as
- +# to its suitability for any purpose.
- +
- +import property ;
- +import generators ;
- +import os ;
- +import toolset : flags ;
- +import feature ;
- +import type ;
- +import common ;
- +
- +feature.extend toolset : sun-stdcxx4 ;
- +toolset.inherit sun-stdcxx4 : unix ;
- +generators.override sun-stdcxx4.prebuilt : builtin.lib-generator ;
- +generators.override sun-stdcxx4.prebuilt : builtin.prebuilt ;
- +generators.override sun-stdcxx4.searched-lib-generator : searched-lib-generator ;
- +
- +feature.extend stdlib : sun-stdcxx4 ;
- +feature.compose <stdlib>sun-stdcxx4
- + : <cxxflags>-library=stdcxx4 <linkflags>-library=stdcxx4
- + ;
- +
- +rule init ( version ? : command * : options * )
- +{
- + local condition = [
- + common.check-init-parameters sun-stdcxx4 : version $(version) ] ;
- +
- + command = [ common.get-invocation-command sun-stdcxx4 : CC
- + : $(command) : "/opt/SUNWspro/bin" ] ;
- +
- + # Even if the real compiler is not found, put CC to
- + # command line so that user see command line that would have being executed.
- + command ?= CC ;
- +
- + common.handle-options sun-stdcxx4 : $(condition) : $(command) : $(options) ;
- +
- + command_c = $(command[1--2]) $(command[-1]:B=cc) ;
- +
- + toolset.flags sun-stdcxx4 CONFIG_C_COMMAND $(condition) : $(command_c) ;
- +}
- +
- +# Declare generators
- +generators.register-c-compiler sun-stdcxx4.compile.c : C : OBJ : <toolset>sun-stdcxx4 ;
- +generators.register-c-compiler sun-stdcxx4.compile.c++ : CPP : OBJ : <toolset>sun-stdcxx4 ;
- +
- +# Declare flags and actions for compilation
- +flags sun-stdcxx4.compile OPTIONS <debug-symbols>on : -g ;
- +flags sun-stdcxx4.compile OPTIONS <profiling>on : -xprofile=tcov ;
- +flags sun-stdcxx4.compile OPTIONS <optimization>speed : -xO4 ;
- +flags sun-stdcxx4.compile OPTIONS <optimization>space : -xO2 -xspace ;
- +flags sun-stdcxx4.compile OPTIONS <threading>multi : -mt ;
- +flags sun-stdcxx4.compile OPTIONS <warnings>off : -erroff ;
- +flags sun-stdcxx4.compile OPTIONS <warnings>on : -erroff=%none ;
- +flags sun-stdcxx4.compile OPTIONS <warnings>all : -erroff=%none ;
- +flags sun-stdcxx4.compile OPTIONS <warnings-as-errors>on : -errwarn ;
- +
- +flags sun-stdcxx4.compile.c++ OPTIONS <inlining>off : +d ;
- +
- +# The -m32 and -m64 options are supported starting
- +# with Sun Studio 12. On earlier compilers, the
- +# 'address-model' feature is not supported and should not
- +# be used. Instead, use -xarch=generic64 command line
- +# option.
- +# See http://svn.boost.org/trac/boost/ticket/1186
- +# for details.
- +flags sun-stdcxx4 OPTIONS <address-model>32 : -m32 ;
- +flags sun-stdcxx4 OPTIONS <address-model>64 : -m64 ;
- +# On sparc, there's a difference between -Kpic
- +# and -KPIC. The first is slightly more efficient,
- +# but has the limits on the size of GOT table.
- +# For minimal fuss on user side, we use -KPIC here.
- +# See http://svn.boost.org/trac/boost/ticket/1186#comment:6
- +# for detailed explanation.
- +flags sun-stdcxx4 OPTIONS <link>shared : -KPIC ;
- +
- +flags sun-stdcxx4.compile OPTIONS <cflags> ;
- +flags sun-stdcxx4.compile.c++ OPTIONS <cxxflags> ;
- +flags sun-stdcxx4.compile DEFINES <define> ;
- +flags sun-stdcxx4.compile INCLUDES <include> ;
- +
- +actions compile.c
- +{
- + "$(CONFIG_C_COMMAND)" $(OPTIONS) -D$(DEFINES) -I"$(INCLUDES)" -c -o "$(<)" "$(>)"
- +}
- +
- +actions compile.c++
- +{
- + "$(CONFIG_COMMAND)" $(OPTIONS) -D$(DEFINES) -I"$(INCLUDES)" -c -o "$(<)" "$(>)"
- +}
- +
- +# Declare flags and actions for linking
- +flags sun-stdcxx4.link OPTIONS <debug-symbols>on : -g ;
- +# Strip the binary when no debugging is needed
- +flags sun-stdcxx4.link OPTIONS <debug-symbols>off : -s ;
- +flags sun-stdcxx4.link OPTIONS <profiling>on : -xprofile=tcov ;
- +flags sun-stdcxx4.link OPTIONS <threading>multi : -mt ;
- +flags sun-stdcxx4.link OPTIONS <linkflags> ;
- +flags sun-stdcxx4.link LINKPATH <library-path> ;
- +flags sun-stdcxx4.link FINDLIBS-ST <find-static-library> ;
- +flags sun-stdcxx4.link FINDLIBS-SA <find-shared-library> ;
- +flags sun-stdcxx4.link LIBRARIES <library-file> ;
- +flags sun-stdcxx4.link LINK-RUNTIME <runtime-link>static : static ;
- +flags sun-stdcxx4.link LINK-RUNTIME <runtime-link>shared : dynamic ;
- +flags sun-stdcxx4.link RPATH <dll-path> ;
- +# On gcc, there are separate options for dll path at runtime and
- +# link time. On Solaris, there's only one: -R, so we have to use
- +# it, even though it's bad idea.
- +flags sun-stdcxx4.link RPATH <xdll-path> ;
- +
- +# The POSIX real-time library is always needed (nanosleep, clock_gettime etc.)
- +flags sun-stdcxx4.link FINDLIBS-SA : rt ;
- +
- +rule link ( targets * : sources * : properties * )
- +{
- + SPACE on $(targets) = " " ;
- +}
- +
- +actions link bind LIBRARIES
- +{
- + "$(CONFIG_COMMAND)" $(OPTIONS) -L"$(LINKPATH)" -R"$(RPATH)" -o "$(<)" "$(>)" "$(LIBRARIES)" -Bdynamic -l$(FINDLIBS-SA) -Bstatic -l$(FINDLIBS-ST) -B$(LINK-RUNTIME)
- +}
- +
- +# Slight mods for dlls
- +rule link.dll ( targets * : sources * : properties * )
- +{
- + SPACE on $(targets) = " " ;
- +}
- +
- +actions link.dll bind LIBRARIES
- +{
- + "$(CONFIG_COMMAND)" $(OPTIONS) -L"$(LINKPATH)" -R"$(RPATH)" -o "$(<)" -h$(<[1]:D=) -G "$(>)" "$(LIBRARIES)" -Bdynamic -l$(FINDLIBS-SA) -Bstatic -l$(FINDLIBS-ST) -B$(LINK-RUNTIME)
- +}
- +
- +# Declare action for creating static libraries
- +actions piecemeal archive
- +{
- + "$(CONFIG_COMMAND)" -xar -o "$(<)" "$(>)"
- +}
- +
- --- boost/Jamroot.orig 2012-07-24 07:59:48.638807134 +0200
- +++ boost/Jamroot 2012-07-24 08:03:53.908851585 +0200
- @@ -145,7 +145,7 @@
- <conditional>@handle-static-runtime
- # The standard library Sun compilers use by default has no chance
- # of working with Boost. Override it.
- - <toolset>sun:<stdlib>sun-stlport
- + <toolset>sun:<stdlib>sun-stdcxx4
- # Comeau does not support shared lib
- <toolset>como:<link>static
- <toolset>como-linux:<define>_GNU_SOURCE=1
- --- boost/tools/build/v2/engine/build.jam.orig 2012-07-24 08:05:12.587532528 +0200
- +++ boost/tools/build/v2/engine/build.jam 2012-07-24 08:06:38.575780139 +0200
- @@ -329,6 +329,13 @@
- [ opt --debug : -g ]
- -I$(--python-include) -I$(--extra-include)
- : -L$(--python-lib[1]) -l$(--python-lib[2]) ;
- +## Solaris Studio 12.3 with stdcxx4
- +toolset sun-stdcxx4 cc : "-o " : -D
- + :
- + [ opt --release : -s -xO3 ]
- + [ opt --debug : -g ]
- + -I$(--python-include) -I$(--extra-include)
- + : -L$(--python-lib[1]) -l$(--python-lib[2]) ;
- ## Compaq Alpha CXX
- toolset tru64cxx cc : "-o " : -D
- :
- --- tools_bb/engine/build.jam.orig 2012-07-23 20:57:17.579891071 +0200
- +++ tools_bb/engine/build.jam 2012-07-23 20:59:27.301189504 +0200
- @@ -329,6 +329,13 @@
- [ opt --debug : -g ]
- -I$(--python-include) -I$(--extra-include)
- : -L$(--python-lib[1]) -l$(--python-lib[2]) ;
- +#Studio 12.1+ with stdcxx4
- +toolset sun-stdcxx4 cc : "-o " : -D
- + :
- + [ opt --release : -s -xO3 ]
- + [ opt --debug : -g ]
- + -I$(--python-include) -I$(--extra-include)
- + : -L$(--python-lib[1]) -l$(--python-lib[2]) ;
- ## Compaq Alpha CXX
- toolset tru64cxx cc : "-o " : -D
- :
- --- ./tools_bjam/build.jam.orig 2012-07-24 08:58:34.775334868 +0200
- +++ ./tools_bjam/build.jam 2012-07-24 08:59:17.203621470 +0200
- @@ -329,6 +329,13 @@
- [ opt --debug : -g ]
- -I$(--python-include) -I$(--extra-include)
- : -L$(--python-lib[1]) -l$(--python-lib[2]) ;
- +## Solaris Studio with stdcxx4
- +toolset sun-stdcxx4 cc : "-o " : -D
- + :
- + [ opt --release : -s -xO3 ]
- + [ opt --debug : -g ]
- + -I$(--python-include) -I$(--extra-include)
- + : -L$(--python-lib[1]) -l$(--python-lib[2]) ;
- ## Compaq Alpha CXX
- toolset tru64cxx cc : "-o " : -D
- :
- --- tools_bb/bootstrap.sh.orig 2012-07-24 09:44:10.533898164 +0200
- +++ tools_bb/bootstrap.sh 2012-07-24 09:44:21.354697875 +0200
- @@ -74,7 +74,7 @@
- ;;
- sun* )
- - TOOLSET=sun
- + TOOLSET=sun-stdcxx4
- ;;
- * )
- --- /dev/null 2012-07-21 17:36:20.000000000 +0200
- +++ tools_bb/tools/sun-stdcxx4.jam 2012-07-21 19:43:52.462932182 +0200
- @@ -0,0 +1,142 @@
- +# Copyright (C) Christopher Currie 2003. Permission to copy, use,
- +# modify, sell and distribute this software is granted provided this
- +# copyright notice appears in all copies. This software is provided
- +# "as is" without express or implied warranty, and with no claim as
- +# to its suitability for any purpose.
- +
- +import property ;
- +import generators ;
- +import os ;
- +import toolset : flags ;
- +import feature ;
- +import type ;
- +import common ;
- +
- +feature.extend toolset : sun-stdcxx4 ;
- +toolset.inherit sun-stdcxx4 : unix ;
- +generators.override sun-stdcxx4.prebuilt : builtin.lib-generator ;
- +generators.override sun-stdcxx4.prebuilt : builtin.prebuilt ;
- +generators.override sun-stdcxx4.searched-lib-generator : searched-lib-generator ;
- +
- +feature.extend stdlib : sun-stdcxx4 ;
- +feature.compose <stdlib>sun-stdcxx4
- + : <cxxflags>-library=stdcxx4 <linkflags>-library=stdcxx4
- + ;
- +
- +rule init ( version ? : command * : options * )
- +{
- + local condition = [
- + common.check-init-parameters sun-stdcxx4 : version $(version) ] ;
- +
- + command = [ common.get-invocation-command sun-stdcxx4 : CC
- + : $(command) : "/opt/SUNWspro/bin" ] ;
- +
- + # Even if the real compiler is not found, put CC to
- + # command line so that user see command line that would have being executed.
- + command ?= CC ;
- +
- + common.handle-options sun-stdcxx4 : $(condition) : $(command) : $(options) ;
- +
- + command_c = $(command[1--2]) $(command[-1]:B=cc) ;
- +
- + toolset.flags sun-stdcxx4 CONFIG_C_COMMAND $(condition) : $(command_c) ;
- +}
- +
- +# Declare generators
- +generators.register-c-compiler sun-stdcxx4.compile.c : C : OBJ : <toolset>sun-stdcxx4 ;
- +generators.register-c-compiler sun-stdcxx4.compile.c++ : CPP : OBJ : <toolset>sun-stdcxx4 ;
- +
- +# Declare flags and actions for compilation
- +flags sun-stdcxx4.compile OPTIONS <debug-symbols>on : -g ;
- +flags sun-stdcxx4.compile OPTIONS <profiling>on : -xprofile=tcov ;
- +flags sun-stdcxx4.compile OPTIONS <optimization>speed : -xO4 ;
- +flags sun-stdcxx4.compile OPTIONS <optimization>space : -xO2 -xspace ;
- +flags sun-stdcxx4.compile OPTIONS <threading>multi : -mt ;
- +flags sun-stdcxx4.compile OPTIONS <warnings>off : -erroff ;
- +flags sun-stdcxx4.compile OPTIONS <warnings>on : -erroff=%none ;
- +flags sun-stdcxx4.compile OPTIONS <warnings>all : -erroff=%none ;
- +flags sun-stdcxx4.compile OPTIONS <warnings-as-errors>on : -errwarn ;
- +
- +flags sun-stdcxx4.compile.c++ OPTIONS <inlining>off : +d ;
- +
- +# The -m32 and -m64 options are supported starting
- +# with Sun Studio 12. On earlier compilers, the
- +# 'address-model' feature is not supported and should not
- +# be used. Instead, use -xarch=generic64 command line
- +# option.
- +# See http://svn.boost.org/trac/boost/ticket/1186
- +# for details.
- +flags sun-stdcxx4 OPTIONS <address-model>32 : -m32 ;
- +flags sun-stdcxx4 OPTIONS <address-model>64 : -m64 ;
- +# On sparc, there's a difference between -Kpic
- +# and -KPIC. The first is slightly more efficient,
- +# but has the limits on the size of GOT table.
- +# For minimal fuss on user side, we use -KPIC here.
- +# See http://svn.boost.org/trac/boost/ticket/1186#comment:6
- +# for detailed explanation.
- +flags sun-stdcxx4 OPTIONS <link>shared : -KPIC ;
- +
- +flags sun-stdcxx4.compile OPTIONS <cflags> ;
- +flags sun-stdcxx4.compile.c++ OPTIONS <cxxflags> ;
- +flags sun-stdcxx4.compile DEFINES <define> ;
- +flags sun-stdcxx4.compile INCLUDES <include> ;
- +
- +actions compile.c
- +{
- + "$(CONFIG_C_COMMAND)" $(OPTIONS) -D$(DEFINES) -I"$(INCLUDES)" -c -o "$(<)" "$(>)"
- +}
- +
- +actions compile.c++
- +{
- + "$(CONFIG_COMMAND)" $(OPTIONS) -D$(DEFINES) -I"$(INCLUDES)" -c -o "$(<)" "$(>)"
- +}
- +
- +# Declare flags and actions for linking
- +flags sun-stdcxx4.link OPTIONS <debug-symbols>on : -g ;
- +# Strip the binary when no debugging is needed
- +flags sun-stdcxx4.link OPTIONS <debug-symbols>off : -s ;
- +flags sun-stdcxx4.link OPTIONS <profiling>on : -xprofile=tcov ;
- +flags sun-stdcxx4.link OPTIONS <threading>multi : -mt ;
- +flags sun-stdcxx4.link OPTIONS <linkflags> ;
- +flags sun-stdcxx4.link LINKPATH <library-path> ;
- +flags sun-stdcxx4.link FINDLIBS-ST <find-static-library> ;
- +flags sun-stdcxx4.link FINDLIBS-SA <find-shared-library> ;
- +flags sun-stdcxx4.link LIBRARIES <library-file> ;
- +flags sun-stdcxx4.link LINK-RUNTIME <runtime-link>static : static ;
- +flags sun-stdcxx4.link LINK-RUNTIME <runtime-link>shared : dynamic ;
- +flags sun-stdcxx4.link RPATH <dll-path> ;
- +# On gcc, there are separate options for dll path at runtime and
- +# link time. On Solaris, there's only one: -R, so we have to use
- +# it, even though it's bad idea.
- +flags sun-stdcxx4.link RPATH <xdll-path> ;
- +
- +# The POSIX real-time library is always needed (nanosleep, clock_gettime etc.)
- +flags sun-stdcxx4.link FINDLIBS-SA : rt ;
- +
- +rule link ( targets * : sources * : properties * )
- +{
- + SPACE on $(targets) = " " ;
- +}
- +
- +actions link bind LIBRARIES
- +{
- + "$(CONFIG_COMMAND)" $(OPTIONS) -L"$(LINKPATH)" -R"$(RPATH)" -o "$(<)" "$(>)" "$(LIBRARIES)" -Bdynamic -l$(FINDLIBS-SA) -Bstatic -l$(FINDLIBS-ST) -B$(LINK-RUNTIME)
- +}
- +
- +# Slight mods for dlls
- +rule link.dll ( targets * : sources * : properties * )
- +{
- + SPACE on $(targets) = " " ;
- +}
- +
- +actions link.dll bind LIBRARIES
- +{
- + "$(CONFIG_COMMAND)" $(OPTIONS) -L"$(LINKPATH)" -R"$(RPATH)" -o "$(<)" -h$(<[1]:D=) -G "$(>)" "$(LIBRARIES)" -Bdynamic -l$(FINDLIBS-SA) -Bstatic -l$(FINDLIBS-ST) -B$(LINK-RUNTIME)
- +}
- +
- +# Declare action for creating static libraries
- +actions piecemeal archive
- +{
- + "$(CONFIG_COMMAND)" -xar -o "$(<)" "$(>)"
- +}
- +
- --- boost/tools/build/v2/test/BoostBuild.py.orig 2012-04-26 05:35:55.000000000 +0200
- +++ boost/tools/build/v2/test/BoostBuild.py 2012-07-26 02:35:50.890768498 +0200
- @@ -240,7 +240,10 @@
- else:
- jam_build_dir = "bin.linux" + os.uname()[4]
- elif os.uname()[0] == 'SunOS':
- - jam_build_dir = "bin.solaris"
- + if os.uname()[4] == "i386":
- + jam_build_dir = "bin.solarisx86"
- + else:
- + jam_build_dir = "bin.solaris"
- elif os.uname()[0] == 'Darwin':
- if os.uname()[4] == 'i386':
- jam_build_dir = "bin.macosxx86"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement