Try and set the right linker options on BSD and Sun platforms.

[SVN r52353]
This commit is contained in:
John Maddock
2009-04-12 15:49:08 +00:00
parent f43833227a
commit 340a8a3e65

View File

@ -7,6 +7,22 @@
# If you need to alter build preferences then set them in
# the template defined in options_v2.jam.
#
import modules ;
local is_unix = [ modules.peek : UNIX ] ;
if $(is_unix)
{
local osname = [ SHELL uname ] ;
switch $(osname)
{
case "Sun*" : OTHERFLAGS = "-lpthread" ;
case "*BSD*" : OTHERFLAGS = "-lpthread" ;
}
}
test-suite config
:
[ run config_test.cpp
@ -23,8 +39,7 @@ test-suite config
<threading>single <toolset>msvc:<runtime-link>static <toolset>msvc:<link>static
<target-os>linux:<linkflags>-lpthread
<target-os>linux:<linkflags>-lrt
<target-os>freebsd:<linkflags>-lpthread
<target-os>bsd:<linkflags>-lpthread
<toolset>gcc:<linkflags>$(OTHERFLAGS)
]
[ run config_info.cpp : : : <test-info>always_show_run_output <threading>single <toolset>msvc:<runtime-link>static <toolset>msvc:<link>static ]
[ run config_info.cpp : : : <test-info>always_show_run_output <threading>multi : config_info_threaded ]