Menu

Tree [f14e71] master /
 History

HTTPS access


File Date Author Commit
 doc 2021-09-18 Stefan Meinlschmidt Stefan Meinlschmidt [192152] added compiler options abstraction mechanism,
 extensions 2021-09-10 Stefan Meinlschmidt Stefan Meinlschmidt [e22500] some fixes,
 .gitignore 2021-08-22 Stefan Meinlschmidt Stefan Meinlschmidt [335b99] introduced explicit caching mechanism,
 LICENSE.txt 2021-08-20 Stefan Meinlschmidt Stefan Meinlschmidt [cad2d7] first version that successfully avoids unnecess...
 README.rst 2021-09-15 Stefan Meinlschmidt Stefan Meinlschmidt [425ad3] added keepable TemporaryDirectory,
 __init__.py 2021-09-14 Stefan Meinlschmidt Stefan Meinlschmidt [cb8338] added basic configure checks,
 _builder.py 2021-09-14 Stefan Meinlschmidt Stefan Meinlschmidt [cb8338] added basic configure checks,
 _cache.py 2021-09-14 Stefan Meinlschmidt Stefan Meinlschmidt [cb8338] added basic configure checks,
 _cmdline.py 2021-09-18 Stefan Meinlschmidt Stefan Meinlschmidt [192152] added compiler options abstraction mechanism,
 _env.py 2021-09-18 Stefan Meinlschmidt Stefan Meinlschmidt [192152] added compiler options abstraction mechanism,
 _projects.py 2021-09-10 Stefan Meinlschmidt Stefan Meinlschmidt [e22500] some fixes,
 _utils.py 2021-09-18 Stefan Meinlschmidt Stefan Meinlschmidt [192152] added compiler options abstraction mechanism,
 artefacts.py 2021-09-18 Stefan Meinlschmidt Stefan Meinlschmidt [192152] added compiler options abstraction mechanism,
 bobfile.py 2021-09-09 Stefan Meinlschmidt Stefan Meinlschmidt [f6e9ae] added copyright info,
 checks.py 2021-09-18 Stefan Meinlschmidt Stefan Meinlschmidt [192152] added compiler options abstraction mechanism,
 lazy.py 2021-09-18 Stefan Meinlschmidt Stefan Meinlschmidt [192152] added compiler options abstraction mechanism,
 package.py 2021-09-18 Stefan Meinlschmidt Stefan Meinlschmidt [f14e71] removed packaging script from packaged bob
 recipes.py 2021-09-18 Stefan Meinlschmidt Stefan Meinlschmidt [192152] added compiler options abstraction mechanism,
 render_rst.py 2021-09-15 Stefan Meinlschmidt Stefan Meinlschmidt [425ad3] added keepable TemporaryDirectory,
 templates.py 2021-09-15 Stefan Meinlschmidt Stefan Meinlschmidt [425ad3] added keepable TemporaryDirectory,
 toolchains.py 2021-09-18 Stefan Meinlschmidt Stefan Meinlschmidt [192152] added compiler options abstraction mechanism,

Read Me

The bob software build system

Author
Stefan Meinlschmidt mailto:meinls@users.sourceforge.net
Homepage
https://sourceforge.net/projects/bob-buildsystem
SPDX-License-Identifier
MIT

bob is a buildsystem roughly comparable with autotools+gmake or CMake+gmake. This means you write a list of the executables and libraries etc. you want to have built, and what source files to build them from, and bob takes care of the nitty, gritty details like finding your compiler and knowing how to invoke it. It also can perform configure checks to help you to adapt your code to the underlying system, i.e. makeing it portable.

Other than autotools or CMake, bob combines the various configure and build phases (including make) into one single tool. This allows for better support for generated code. Building a code generator, then running it to find out what (generated) sources to incorporate into the actual program, then building that, is no problem for bob, even when crosscompiling.

Also bob avoids the use of a specialized description language, slowly and painfully evolved into Turing-completeness, harnessing the power of kludgy workarounds, and has you use Python instead, a real & mature programming language, and even one of the better ones.

Actually bob is simply a Python package. This means that instead of a traditional Makefile to be processed by some tool you write a Python3 script using bob commands. The script describes what to build and from what sources. Invoking it uses bob to build.

The conventional filename for the build script is make.py. A minimal example looks like:

#!/usr/bin/env python3
###############################################

from bob import *

###############################################

def project_hello(public):
    Executable('hello', 'src/hello-main.c')

###############################################

if __name__=='__main__':
    build(project_hello)

###############################################

In the end your source tree should look something like this:

your source root
+--bob
+--make.py
+--more stuff

For details see the bob-manual.