From d85461c4280e292994412056216daf5f82fdd6e9 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Thu, 7 May 2020 22:30:17 +0300 Subject: Factor out generic script parsing/executing functionality from build2::test::script namespace --- libbuild2/buildfile | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'libbuild2/buildfile') diff --git a/libbuild2/buildfile b/libbuild2/buildfile index edd0570..9813808 100644 --- a/libbuild2/buildfile +++ b/libbuild2/buildfile @@ -27,6 +27,9 @@ lib{build2}: libul{build2}: \ {hxx ixx txx cxx}{* -utility-*installed -config -version -*.test...} \ {hxx}{config version} +libul{build2}: script/{hxx ixx txx cxx}{** -*-options -**.test...} \ + script/{hxx ixx cxx}{builtin-options} + # Note that this won't work in libul{} since it's not installed. # lib{build2}: cxx{utility-installed}: for_install = true @@ -78,8 +81,7 @@ libul{build2}: dist/{hxx ixx txx cxx}{** -**.test...} libul{build2}: install/{hxx ixx txx cxx}{** -**.test...} -libul{build2}: test/{hxx ixx txx cxx}{** -**-options -**.test...} \ - test/script/{hxx ixx cxx}{builtin-options} +libul{build2}: test/{hxx ixx txx cxx}{** -**.test...} libul{build2}: $int_libs @@ -105,6 +107,7 @@ exe{*.test}: } for t: cxx{ *.test...} \ + script/cxx{**.test...} \ config/cxx{**.test...} \ dist/cxx{**.test...} \ install/cxx{**.test...} \ @@ -191,15 +194,15 @@ else # Generated options parser. # -test/script/ +script/ { if $cli.configured { cli.cxx{builtin-options}: cli{builtin} cli.options += --std c++11 -I $src_root --include-with-brackets \ ---include-prefix libbuild2/test/script --guard-prefix LIBBUILD2_TEST_SCRIPT \ ---cli-namespace build2::test::script::cli --generate-vector-scanner \ +--include-prefix libbuild2/script --guard-prefix LIBBUILD2_SCRIPT \ +--cli-namespace build2::script::cli --generate-vector-scanner \ --generate-specifier --suppress-usage cli.cxx{*}: -- cgit v1.1