aboutsummaryrefslogtreecommitdiff
path: root/build.conf
diff options
context:
space:
mode:
Diffstat (limited to 'build.conf')
-rw-r--r--build.conf47
1 files changed, 29 insertions, 18 deletions
diff --git a/build.conf b/build.conf
index dc847c8..8bbe679 100644
--- a/build.conf
+++ b/build.conf
@@ -1,27 +1,38 @@
1# This is a build file for build 1default action: check "build", check "cleanup"
2 2
3default action: check build 3["build", "cleanup"]:
4"clean" action: clean build 4 rule "exe",
5 target file,
6 set "CXXFLAGS" = "-lBob",
7 input [files("src/{target}"), files("src/shared")]
5 8
6create file build from files in src using rule exe 9[directoryName("src/tests")] filter /src\/tests/(.*)/tests\/{re:1}/:
10 rule "exe",
11 target prefix "tests/",
12 target file,
13 input files("src/tests/{target}")
7 14
8set CXXFLAGS += "-ggdb" 15[directories("src/tests"), aoeua]:
16 rule "exe",
17 target file,
18 input files("src/{target}")
9 19
10set CXXFLAGS += "-Ilibbu++/src" 20"build":
11set LDFLAGS += "-Llibbu++ -lbu++" 21 input [files("src"), "boy.cpp"] filter /.*\.cpp$/,
22 input filter /.*\.cpp$/,
23 requires ["bob.cpp", "libbuild.a", "libbu++/libbu++.a"]
12 24
13build requires "libbu++/libbu++.a" 25"bob.cpp": set "aoeu" = "food", requires "bob.bastard"
14 26
15/(.*)\.o$/ requires from command "g++ {CXXFLAGS} -M {re:1}.c*" 27rule "exe"
28 matches /(.*)\.o$/,
29 input filter toSpaces(),
30 perform command("stuff")
16 31
17rule exe matches all /(.*)\.o$/ perform command ... 32rule "cpp":
18 "g++ {match} {LDFLAGS} -o {target}" 33 matches /(.*)\.cpp$/,
34 produces "{re:1}.o",
35 requires commandToList( make, "g++ -M {match}"),
36 perform command("stuff")
19 37
20rule cpp matches one /(.*)\.c(pp)?$/ produces "{re:1}.o" perform command ...
21 "g++ {CXXFLAGS} -c -o {target} {match}"
22 38
23rule bison matches one /(.*)\.y$/ produces "{re:1}.tab.c", "{re:1}.tab.h", ...
24 "{re:1}.output" perform command "bison -v -b{re:1} {match}"
25
26rule flex matches one /(.*)\.l$/ produces "{re:1}.yy.c" perform ...
27 command "flex --bison-bridge --bison-locations -o {target} {match}"