Skip to content
A python front-end to the reggae meta-build system
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


Build Status

A Python interface / front-end to the reggae meta-build system.


pip install reggae


This packge makes available a few classes and functions that allow the user to write build descriptions in Python. It is essentially the same API as the D version but in Python syntax. A simple C build could be written like this:

from reggae import *
main_obj = Target('main.o', 'gcc -I$project/src -c $in -o $out', Target('src/main.c'))
maths_obj = Target('maths.o', 'gcc -c $in -o $out', Target('src/maths.c'))
app = Target('myapp', 'gcc -o $out $in', [main_obj, maths_obj])
bld = Build(app)

This should be contained in a file named in the project's root directory. Running the reggae D binary on that directory will produce a build with the requested backend (ninja, make, etc.)

Most builds will probably not resort to low-level primitives as above. A better way to describe that C build would be:

from reggae import *
objs =  object_files(flags='-I$project/src', src_dirs=['src'])
app = link(exe_name='app', dependencies=objs)
bld = Build(app)

Please consult the reggae documentation for more details.

You can’t perform that action at this time.