Metadata-Version: 2.1
Name: bmgen
Version: 2023.4.0b3
Summary: Broken Mouse Studios' build solution
Home-page: https://git.brokenmouse.studio/bms/bmgen
Author: bms
Author-email: bmgen@brokenmouse.studio
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE

# bmgen - Broken Mouse Studios' build solution

## DISCLAIMER
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 https://git.brokenmouse.studio/bms/bmgen/issues

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

## Installation
- 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:
```python
from bmgen.commands.clang import clang
```
2. Then set the base output directory and tell bmgen to create the base, variant and the `clang` command's object directory:
```python
inst.base_output_dir = 'bin'
inst.update_output_dir()
clang.update_object_dir()
```
3. Build the program via `clang`:
```python
clang('mygame', ['main.c', 'game.c'], ['sdl2'])
```

The final `bmgen.py` looks like this:
```python
from bmgen.commands.clang import clang

inst.base_output_dir = 'bin'
inst.update_output_dir()
clang.update_object_dir()

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

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

## License
© Broken Mouse Studios 2023<br>
https://brokenmouse.studio

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

For the license's contents, see [LICENSE](LICENSE) or go to https://mozilla.org/MPL/2.0/.

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.
