2
0
mirror of https://github.com/boostorg/build.git synced 2026-02-16 01:12:13 +00:00

handle command-line arguments as bjam does

[SVN r33935]
This commit is contained in:
João Abecasis
2006-05-05 10:22:18 +00:00
parent 922f927e49
commit 17beafee48

View File

@@ -125,9 +125,14 @@ rule from-command-line ( command-line * )
local properties ;
command-line = $(command-line[2-]) ;
local skip-next = ;
for local e in $(command-line)
{
if ! [ MATCH "^(-).*" : $(e) ]
if $(skip-next)
{
skip-next = ;
}
else if ! [ MATCH "^(-).*" : $(e) ]
{
# Build request spec either has "=" in it, or completely
# consists of implicit feature values.
@@ -142,6 +147,10 @@ rule from-command-line ( command-line * )
targets += $(e) ;
}
}
else if [ MATCH "^(-[-ldjfsto])$" : $(e) ]
{
skip-next = true ;
}
}
return [ new vector [ new vector $(targets) ] [ new vector $(properties) ] ] ;
}