aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--build/root.build11
-rw-r--r--doc/buildfile6
-rw-r--r--tests/ci/buildfile7
-rw-r--r--tests/submit/buildfile5
-rw-r--r--www/buildfile16
5 files changed, 15 insertions, 30 deletions
diff --git a/build/root.build b/build/root.build
index 2502705..ce8ca41 100644
--- a/build/root.build
+++ b/build/root.build
@@ -31,6 +31,17 @@ using bash
brep/bash{*}: install.subdirs = true
+# Define commonly used target types.
+#
+define css: file
+css{*}: extension = css
+
+define xhtml: doc
+xhtml{*}: extension = xhtml
+
+define common_testscript: file
+common_testscript{*}: extension = testscript
+
# All exe{} in tests/ are, well, tests. Also don't link whole archives
# by default there.
#
diff --git a/doc/buildfile b/doc/buildfile
index f4721c9..4b2305e 100644
--- a/doc/buildfile
+++ b/doc/buildfile
@@ -7,12 +7,6 @@ brep-clean \
brep-load \
brep-migrate
-define css: file
-css{*}: extension = css
-
-define xhtml: doc
-xhtml{*}: extension = xhtml
-
./: {man1 xhtml}{$cmds} \
css{common pre-box man} \
file{man-*}
diff --git a/tests/ci/buildfile b/tests/ci/buildfile
index 6ed5d5b..280e364 100644
--- a/tests/ci/buildfile
+++ b/tests/ci/buildfile
@@ -2,17 +2,14 @@
# copyright : Copyright (c) 2014-2019 Code Synthesis Ltd
# license : MIT; see accompanying LICENSE file
-define common: file
-common{*}: extension = testscript
-
dir = ../../brep/handler/ci/
include $dir
commons = data
-./: testscript{* -{$commons}} common{$commons} {*/ -test/}{**} \
- $dir/exe{brep-ci-dir} $dir/exe{brep-ci-load} \
+./: testscript{* -{$commons}} common_testscript{$commons} {*/ -test/}{**} \
+ $dir/exe{brep-ci-dir} $dir/exe{brep-ci-load} \
doc{README} file{hello.tar.gz}
testscript{ci-dir}@./: test = $out_base/$dir/brep-ci-dir
diff --git a/tests/submit/buildfile b/tests/submit/buildfile
index e4dc657..aaffede 100644
--- a/tests/submit/buildfile
+++ b/tests/submit/buildfile
@@ -2,16 +2,13 @@
# copyright : Copyright (c) 2014-2019 Code Synthesis Ltd
# license : MIT; see accompanying LICENSE file
-define common: file
-common{*}: extension = testscript
-
dir = ../../brep/handler/submit/
include $dir
commons = data
-./: testscript{* -{$commons}} common{$commons} {*/ -test/}{**} \
+./: testscript{* -{$commons}} common_testscript{$commons} {*/ -test/}{**} \
$dir/exe{brep-submit-dir} $dir/exe{brep-submit-git} file{hello.tar.gz} \
doc{README}
diff --git a/www/buildfile b/www/buildfile
index e189202..6c2f15f 100644
--- a/www/buildfile
+++ b/www/buildfile
@@ -2,13 +2,7 @@
# copyright : Copyright (c) 2014-2019 Code Synthesis Ltd
# license : MIT; see accompanying LICENSE file
-define css: file
-
-css{*}:
-{
- extension = css
- install = data/www/
-}
+css{*} xhtml{*}: install = data/www/
define scss: file
@@ -18,12 +12,4 @@ scss{*}:
install = data/www/
}
-define xhtml: file
-
-xhtml{*}:
-{
- extension = xhtml
- install = data/www/
-}
-
./: css{*} scss{*} xhtml{*}