diff --git a/src/tools/intel-win.jam b/src/tools/intel-win.jam index f138607a0..68d707298 100644 --- a/src/tools/intel-win.jam +++ b/src/tools/intel-win.jam @@ -7,6 +7,7 @@ import toolset ; import feature ; import toolset : flags ; import os ; +import errors ; # This is needed because the rule we import here depend on 'common' # That's nasty. @@ -137,10 +138,17 @@ rule init ( version ? : # the compiler version if ! $(compatibility) { # If there's no backend version, assume 7.1. - compatibility = 7.1 ; + compatibility = vc7.1 ; } - msvc.configure-version-specific intel-win : $(compatibility) : $(condition) ; + local extract-version = [ MATCH ^vc(.*) : $(compatibility) ] ; + if ! $(extract-version) + { + errors.user-error "Invalid value for compatibility option:" + $(compatibility) ; + } + + msvc.configure-version-specific intel-win : $(extract-version[1]) : $(condition) ; } flags intel-win.link LIBRARY_OPTION intel : "" ; diff --git a/src/tools/msvc.jam b/src/tools/msvc.jam index 119e8e23f..98fbac877 100644 --- a/src/tools/msvc.jam +++ b/src/tools/msvc.jam @@ -415,7 +415,7 @@ rule configure-version-specific ( toolset : version : condition ) # Processor-specific optimization # - if [ MATCH ^([67]\\.) : $(version) ] + if [ MATCH ^([67]) : $(version) ] { # 8.0 deprecates some of the options flags $(toolset).compile CFLAGS $(condition)/speed $(condition)/space : /Ogiy /Gs ;