summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--build/root.build4
-rw-r--r--cli/buildfile9
-rw-r--r--unit-tests/lexer/buildfile8
-rw-r--r--unit-tests/parser/buildfile10
4 files changed, 11 insertions, 20 deletions
diff --git a/build/root.build b/build/root.build
index ee1272a..fc8c83c 100644
--- a/build/root.build
+++ b/build/root.build
@@ -21,6 +21,10 @@ cxx.poptions =+ "-I$out_root" "-I$src_root"
#
using? cli
+# Don't link whole archives by default in unit-tests/.
+#
+unit-tests/libu{*}: bin.whole = false
+
# Specify the test target for cross-testing.
#
test.target = $cxx.target
diff --git a/cli/buildfile b/cli/buildfile
index 48edffd..e64458f 100644
--- a/cli/buildfile
+++ b/cli/buildfile
@@ -4,10 +4,11 @@
import libs = libcutl%lib{cutl}
-exe{cli}: {hxx ixx txx cxx}{** -version -options} \
- {hxx}{version} \
- {hxx ixx cxx}{options} \
- $libs
+exe{cli}: cxx{cli} libu{cli}
+
+libu{cli}: {hxx ixx txx cxx}{** -cli -version -options} \
+ {hxx}{version} {hxx ixx cxx}{options} \
+ $libs
hxx{version}: in{version} $src_root/file{manifest}
hxx{version}: dist = true
diff --git a/unit-tests/lexer/buildfile b/unit-tests/lexer/buildfile
index 0b4fbcf..3827d04 100644
--- a/unit-tests/lexer/buildfile
+++ b/unit-tests/lexer/buildfile
@@ -2,11 +2,5 @@
# copyright : Copyright (c) 2009-2017 Code Synthesis Tools CC
# license : MIT; see accompanying LICENSE file
-#@@ Temporary until we get utility library support.
-#
-import libs = libcutl%lib{cutl}
-src = lexer
-
-exe{driver}: {hxx cxx}{*} ../../cli/cxx{$src} $libs test{testscript}
-
include ../../cli/
+exe{driver}: {hxx cxx}{*} ../../cli/libu{cli} test{testscript}
diff --git a/unit-tests/parser/buildfile b/unit-tests/parser/buildfile
index 44020d8..381f56a 100644
--- a/unit-tests/parser/buildfile
+++ b/unit-tests/parser/buildfile
@@ -2,13 +2,5 @@
# copyright : Copyright (c) 2009-2017 Code Synthesis Tools CC
# license : MIT; see accompanying LICENSE file
-#@@ Temporary until we get utility library support.
-#
-import libs = libcutl%lib{cutl}
-src = lexer parser \
-semantics/{class elements expression namespace option unit} \
-traversal/{class elements namespace option unit}
-
-exe{driver}: {hxx cxx}{*} ../../cli/cxx{$src} $libs test{testscript}
-
include ../../cli/
+exe{driver}: {hxx cxx}{*} ../../cli/libu{cli} test{testscript}