Broken Mouse Studios' build solution
Go to file
ever 3023d612d5 v2023.05.0-BETA0 2023-05-01 12:55:47 +02:00
bmgen v2023.05.0-BETA0 2023-05-01 12:55:47 +02:00
tests Added tests 2023-04-21 19:43:25 +02:00
.gitignore Initial commit 2023-04-17 19:33:58 +02:00
.markdownlint.json Added markdownlint 2023-04-21 20:05:17 +02:00
LICENSE Initial commit 2023-04-17 19:33:58 +02:00 Added markdownlint 2023-04-21 20:05:17 +02:00 Initial commit 2023-04-17 19:33:58 +02:00

bmgen - Broken Mouse Studios' build solution


This project is currently in it's beta phase!

It needs to be cleaned up and does not yet have it's full set of features. You may quickly hit it's limits.

You should expect API changes and are welcome to give feedback via


  • build scripts written in Python
  • incremental builds
  • temporary build directories
  • colorful and easy to read output
  • simple build commands


  • Install bmgen via pip install bmgen or python3 -m pip install bmgen

Building a simple C project

This example shows a script which builds two files named main.c and game.c into a binary named mygame with SDL2.

The directory structure created by bmgen will look like this:

- bin/
  - dbg/
    - obj/
      - main.o
      - game.o
    - mygame

The following is a breakdown of the script.

  1. First import the clang command:
from bmgen.commands.clang import clang
  1. Then set the base output directory and tell bmgen to create the base, variant and the clang command's object directory:
inst.base_output_dir = 'bin'
  1. Build the program via clang:
clang('mygame', ['main.c', 'game.c'], ['sdl2'])

The final looks like this:

from bmgen.commands.clang import clang

inst.base_output_dir = 'bin'

clang('mygame', ['main.c', 'game.c'], ['sdl2'])

Building the program is now as easy as running bmgen in your terminal!


© Broken Mouse Studios 2023

This software and it's accompanying files are licensed under the Mozilla Public License Version 2.0.

For the license's contents, see LICENSE or go to

By submitting patches or merge/pull requests, you grant Broken Mouse Studios the permission to use, copy, modify, distribute, publish and/or relicense the contributions you have made to the project.