lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Hi guys,

There has recently been discussion around build frameworks, with
various degrees of religious conviction. I've been playing with my own
take on the problem for a while; formerly known as LuaMake, then (for
a few days) as Lake, and now finally as Bou.  Bou means 'build' in
Afrikaans, pronounced rather like 'beau'. (the English language is
runninig out of cool names for projects.)

There is a lot missing, but, release early and release often.

Bou looks for a boufile in the current directory; the simplest
possible boufile is "program 'hello.c'".

You can embed the popular 'deps' format into boufiles:

cpp.defaults = {defines = 'SIMPLE',libs = 'user32'}
cpp.program {'bonzo',rules=[[
cppfile.o: cppfile.cpp cpp/inc.h c/common.h
cfile.o: cfile.c c/inc.h c/common.h
clib.o: c/clib.c c/inc.h

which results in:

g++ -c -O1 -DNDEBUG -DSIMPLE  -Icpp -Ic   cppfile.cpp
gcc -c -O1 -DNDEBUG -Ic   cfile.c
gcc -c -O1 -DNDEBUG -Ic   c/clib.c
g++ cppfile.o cfile.o clib.o  -luser32  -o bonzo.exe

My current favourite is this:


This builds and runs all the C files in a directory, and then runs all
the Lua files. Nice for testing...

As always, it's all on our favourite self-publishing forum:

steve d.