On 02-Oct-15 11:05 PM, Ion GaztaƱaga wrote:
On 02/10/2015 20:19, Vladimir Prus wrote:
Ion,
does the following patch (which basically makes global-setup argument optional), help? It seems the code of that function is already handling lack of global setup script (=vcvarsall.bat), but the signature does not.
--- src/tools/msvc.jam +++ src/tools/msvc.jam @@ -793,10 +793,10 @@ actions write-setup-script # Local helper rule to create the vcvars setup command for given architecture # and options. # -local rule generate-setup-cmd ( version : command : parent : options * : cpu : global-setup : default-global-setup-options : default-setup ) +local rule generate-setup-cmd ( version : command : parent : options * : cpu : global-setup ? : default-global-setup-options : default-setup ) { Thanks. I tried that before, unfortunately a new error happened:
C:/boost/develop/boost_bb/src/tools\msvc.jam:834: in generate-setup-cmd *** argument error * rule maybe-rewrite-setup ( toolset : setup-script : setup-options : version : rewrite-setup ? ) * called with: ( msvc : : : 7.1 : ) * missing argument setup-script C:/boost/develop/boost_bb/src/tools\msvc.jam:746:see definition of rule 'maybe-rewrite-setup' being called C:/boost/develop/boost_bb/src/tools\msvc.jam:1072: in configure-really C:/boost/develop/boost_bb/src/tools\msvc.jam:201: in configure C:/boost/develop/boost_bb/src/tools\msvc.jam:153: in msvc.init C:/boost/develop/boost_bb/src/build\toolset.jam:43: in using C:\Users\igaztanaga\user-config.jam:49: in modules.load
It seems that "maybe-rewrite-setup" does not support an optional "setup-script" argument, and the call to rewrite is not prepared for MSVC-7.1. I can't figure out what "$(setup:J=" ")" argument tries to do.
I commented the line 834 as it seems to be an optimization for MSVC >= 10.0 and the process goes further. The build starts but it seems that hardlinks are not properly done and the compiler does not found includes. But the toolset seems ok now. So avoid the optimization for MSVC 7.1 seems a quick workaround as calling 7.1's vcvars32.bat is very quick.
$(setup:J=" ") is basically what " ".join(setup) is in Python - it joins all elements of a list with a separator. If that ends up empty, it means we failed to find setup script MSVC 7.1 at all. It might explain not finding includes. Could you find the line a bit above that reads: setup = [ locate-default-setup $(command) : $(parent) : $(default-setup) ] ; and add ECHO "locate-default-setup $(command:E=) : $(parent:E=) : $(default-setup:E=) -> $(setup:E=) " ; after it and see what that outputs? We might want to move this to boost-build@lists.boost.org though, as it's becoming rather detailed discussion. - Volodya