--- boost_1_53_0/tools/build/v2/tools/mpi.jam 2012-04-27 01:32:41.000000000 +0400 +++ boost_1_53_0_patched/tools/build/v2/tools/mpi.jam 2013-08-03 18:34:31.141619900 +0400 @@ -231,7 +231,14 @@ # not. Returns true for an exit code of zero, false otherwise. local rule safe-shell-command ( cmdline ) { - local result = [ SHELL "$(cmdline) > /dev/null 2>/dev/null; if [ "$?" -eq "0" ]; then echo SSCOK; fi" ] ; + local result ; + + if [ os.name ] = NT { + result = [ SHELL "$(cmdline) -showme:compile >NUL 2>NUL && echo SSCOK" ] ; + } else { + result = [ SHELL "$(cmdline) > /dev/null 2>/dev/null; if [ "$?" -eq "0" ]; then echo SSCOK; fi" ] ; + } + return [ MATCH ".*(SSCOK).*" : $(result) ] ; }