diff --git a/src/tools/common.jam b/src/tools/common.jam index 04b87accb..e1af5f0b0 100644 --- a/src/tools/common.jam +++ b/src/tools/common.jam @@ -857,6 +857,10 @@ rule format-name ( format * : name : type ? : property-set ) result += [ join-tag $(f:G=) : [ address-model-tag $(name) : $(type) : $(property-set) ] ] ; + case : + result += [ join-tag $(f:G=) : [ arch-and-model-tag $(name) : + $(type) : $(property-set) ] ] ; + case : local key = [ MATCH : $(f:G) ] ; local version = [ $(property-set).get <$(key)> ] ; @@ -1029,6 +1033,19 @@ local rule address-model-tag ( name : type ? : property-set ) return [ $(property-set).get ] ; } +# Create a tag for the architecture and model +# x86 32 would generate "x32" +# This relies on the fact that all architectures start with +# unique letters. +local rule arch-and-model-tag ( name : type ? : property-set ) +{ + local architecture = [ $(property-set).get ] ; + local address-model = [ $(property-set).get ] ; + + local arch = [ MATCH ^(.) : $(architecture) ] ; + + return $(arch)$(address-model) ; +} rule __test__ ( ) {