diff --git a/v2/build-system.jam b/v2/build-system.jam index 07d8b8c51..314448fe6 100644 --- a/v2/build-system.jam +++ b/v2/build-system.jam @@ -559,7 +559,6 @@ local rule should-clean-project ( project ) current-project = [ project.target [ project.load "." ] ] ; } - # Load the default toolset module if no other has already been specified. if ! [ feature.values ] { diff --git a/v2/build/project.jam b/v2/build/project.jam index 251cfb5ce..b86f1e85a 100644 --- a/v2/build/project.jam +++ b/v2/build/project.jam @@ -953,8 +953,7 @@ module project-rules } # If '--build-dir' is specified, change the build dir for the project. - local global-build-dir = - [ modules.peek project : .global-build-dir ] ; + local global-build-dir = [ modules.peek project : .global-build-dir ] ; if $(global-build-dir) { diff --git a/v2/build/toolset.jam b/v2/build/toolset.jam index d19be3c0b..d9adc5d4a 100644 --- a/v2/build/toolset.jam +++ b/v2/build/toolset.jam @@ -2,7 +2,8 @@ # Copyright 2005 Rene Rivera # Copyright 2002, 2003, 2004, 2005, 2006 Vladimir Prus # Distributed under the Boost Software License, Version 1.0. -# (See accompanying file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt) +# (See accompanying file LICENSE_1_0.txt or copy at +# http://www.boost.org/LICENSE_1_0.txt) # Support for toolset definition. @@ -36,7 +37,8 @@ if --ignore-toolset-requirements in [ modules.peek : ARGV ] rule using ( toolset-module : * ) { import $(toolset-module) ; - $(toolset-module).init $(2) : $(3) : $(4) : $(5) : $(6) : $(7) : $(8) : $(9) ; + $(toolset-module).init $(2) : $(3) : $(4) : $(5) : $(6) : $(7) : $(8) : $(9) + ; } @@ -497,8 +499,8 @@ rule inherit-flags ( toolset : base : prohibited-properties * : prohibited-vars local rule-or-module = $(.rule-or-module.$(f)) ; if ( [ set.difference $(.$(rule-or-module).condition.$(f)) : - $(prohibited-properties) ] - || ! $(.$(rule-or-module).condition.$(f)) + $(prohibited-properties) ] + || ! $(.$(rule-or-module).condition.$(f)) ) && ( ! $(.$(rule-or-module).variable.$(f)) in $(prohibited-vars) ) { local rule_ = [ MATCH "[^.]*\.(.*)" : $(rule-or-module) ] ; diff --git a/v2/test/using.py b/v2/test/using.py index 452e7363b..9a247aed7 100644 --- a/v2/test/using.py +++ b/v2/test/using.py @@ -9,32 +9,22 @@ import BoostBuild t = BoostBuild.Tester() -t.write("sub/a.cpp", """ -int main() {} -""") - -t.write("jamroot.jam", """ -using some_tool ; -""") - -t.write("some_tool.jam", """ +t.write("jamroot.jam", "using some_tool ;") +t.write("some_tool.jam", """\ import project ; project.initialize $(__name__) ; rule init ( ) { } """) -t.write("some_tool.py", """ +t.write("some_tool.py", """\ from b2.manager import get_manager - get_manager().projects().initialize(__name__) - def init(): pass """) -t.write("sub/jamfile.jam", """ -exe a : a.cpp ; -""") +t.write("sub/a.cpp", "int main() {}\n") +t.write("sub/jamfile.jam", "exe a : a.cpp ;") t.run_build_system(subdir="sub") t.expect_addition("sub/bin/$toolset/debug/a.exe")