bake resolves dependencies by logical name and keeps everything under one directory
Bake, A build system for building, testing and running C & C++ projects
At a glance
- What is it?
- A zero-dependency C and C++ build system that calls gcc, clang, msvc and emcc directly, discovers projects by walking directories, and stores its binary, its exported variables and your cloned projects in the same place: the bake environment at $HOME/bake. Its last tagged release is from 2019 while the repository is still being pushed to.
- Who is it for?
- Bake is worth trying on a self-contained C or C++ project if the two things that usually go wrong, include paths and dependency discovery, are what annoy you. A dependency is a name, a project in a subdirectory is found and ordered without configuration, and no tool has to be installed for bake to drive the compilers it calls.
- Can I use it commercially?
- Yes, with conditions. GPL-3.0 is a copyleft licence: if you distribute software that includes it, you must release that software's source code under the same licence. Running it internally without distributing it does not trigger that obligation.
- Is it still maintained?
- Yes. The repository last received commits 16 days ago.
- What is it written in?
- Mainly C, according to GitHub's language statistics.
Answers come from the project's GitHub data, last synced on November 15, 2026, and from our analysis. They are not legal advice.
Star history
- SanderMertens/bake755 ★ · +10
| Repository | 2026-09-11 | 2026-11-15 |
|---|---|---|
| SanderMertens/bake | 745 | 755 |
10 Stars in the last 65 days, measured from the daily GitHub snapshot. Compare with other projects
Editorial analysis
A dependency is a logical name, not a path or a flag
The configuration is JSON and it separates two kinds of dependency that every C build file tends to mix. A project dependency goes in `use` as a logical name, and a system library goes in the `lib` array under `lang.c`.
{
"id": "my_app",
"type": "application",
"value": {
"use": ["foo.bar"]
},
"lang.c": {
"lib": ["pthread"]
}
}The block is introduced as a simple configuration with a dependency on the `foo.bar` package that links with `pthread`, and it is the whole file for a new project. The nested `lang.c` object is where language-specific settings live, so the C driver's libraries sit one level below the language key rather than beside the dependency list.
Two things follow from that shape. Nothing in it is an operating system path, which is the point of resolving by logical name, and headers from a dependency are included automatically, so there is no include directory to write down or search for. Pair that with the stated ability to discover, order and build the projects in a directory without additional configuration, and a project can sit next to its dependencies in a tree that nobody had to describe.
The rest of the loop is short: `bake new my_app` creates a project, `bake run my_app` runs it, and `bake --cfg release` selects a configuration instead of the default one.
The bake environment is the binary, the config file and the workspace
One directory does three jobs, and it is called the bake environment. It defaults to `$HOME/bake`, the bake executable is installed there, and `bake.json` at its root holds the variables you export.
bake export VAR=valuePath variables get a second form, `bake export PATH+=/my/path`, because appending to something you did not define locally is a different operation from assigning it. To make those variables visible in a shell you run a command substitution with `bake env`, which the page shows as an export of that command's output.
Cloned projects land in the same place. `bake clone https://github.com/SanderMertens/example` fetches a repository and builds it with its dependencies, and bundles exist for managing projects together with their git repositories. So the directory that holds your build tool also holds the tools you build with it, which makes it easy to back up or delete in one move and easy to accumulate a lot of state in a home directory nobody inspects.
The syntax shown for exposing the environment is POSIX shell substitution. The page also claims Windows as a verified platform, and it does not give a command prompt equivalent for this step.
Installation writes to /usr/local/bin and asks for your password
The Linux and macOS install is two commands, and the second one runs a script from the cloned directory:
git clone https://github.com/SanderMertens/bake
bake/setup.shWhat that script does is described next: it installs a single script into `/usr/local/bin` which calls the bake binary in `~/bake`, and it may prompt for your password during installation. The stated reason for the wrapper is that it lets you call bake from any location without editing your environment. So the convenience costs a write into a system directory and possibly a password prompt.
Local mode exists for people who would rather not have that. You build first, then install with a flag:
git clone https://github.com/SanderMertens/bake
cd bake
make -C build-$(uname) clean all
./bake setup --localAfterwards the executable sits in `~/bake` and you have to add that directory to `PATH` yourself, which is exactly the step the wrapper script existed to remove. Two smaller asymmetries are worth noting. The block above is labelled as C on the page even though every line is shell, and it relies on `uname`, so it is the Unix path. Windows takes a different route, `cd bake` followed by `setup`, and requires Visual Studio Build Tools or the full IDE with the C++ CMake tools for Windows and Windows SDK components from the Desktop development with C++ workload.
Premake generates makefiles that are committed to the repository
The FAQ entry about premake answers the obvious question directly. Bake uses premake to generate its makefiles, with the reasoning given in parentheses: the authors would have used bake to build bake, but that is a chicken and egg problem. The useful part is the next sentence, which says the generated makefiles are included in the repository, so premake does not need to be installed to use bake.
That is visible in the tree. There is a `premake5.lua` at the root and a `run_premake.sh` beside it, and there are four pre-generated build trees committed as well: `build-Darwin/`, `build-Linux/`, `build-Mingw/` and `build-Windows/`. The four trees serve three verified platforms, Linux, macOS and Windows, with MinGW and the Visual Studio toolchain covered separately. The local-mode command addresses them by name, since `make -C build-$(uname)` expands to the Darwin or Linux tree.
So the repository carries two build descriptions: one declarative file that regenerates makefiles for anyone who wants them, and four sets of generated output that let everyone else build without installing anything. Keeping the generated trees in version control is what makes a zero-dependency install possible, and it is also the part that has to be regenerated by hand when the project configuration changes.
The verified compiler list stops at gcc 10 and clang 10
Bake states two lists. Platforms: Linux, MacOS, Windows. Compilers: gcc 7, 8, 9 and 10, clang 8, 9 and 10, and msvc.
Those lists sit next to a promise about warnings. The feature list claims it makes projects warning free on all compilers and compiler versions with a strict compilation mode. Read together, the claim is as broad as the promise and as narrow as the list: the checking that backs it stops at gcc 10 and clang 10, and msvc carries no version numbers at all.
The built-in emscripten support sits outside both lists. The feature list names webasm support and states that bake calls emcc directly alongside msvc, gcc and clang, yet emcc does not appear among the verified compilers. Web output is therefore a supported path with no published compiler matrix behind it.
The repository itself is not frozen at that point. The most recent release tag is Bake 2.5.1 dated 2019-09-30, following Bake 2.5 on 2019-09-14 and Bake 2.4 on 2019-08-25, and there is a `bake upgrade` command for moving to the latest version. Commits after that release are dated as recently as 2026-06-27, so the question of whether you want the 2.5.1 tag or the branch tip is one you have to answer yourself.
The package manager answer says no and stops mid-word
One FAQ entry asks whether bake is a package manager and answers no. What follows begins to list the features that make it look like one: package-management-like behavior such as resolving projects by logical name, automatic project discovery, and associating projects with git repositories. That sentence ends partway through the word for repositories.
The features section supports the hesitation. There is a single command to clone, build and run a project together with its dependencies, and there are bundles for managing projects and their git repositories. The page also names the tooling it sits next to: a test framework, out of the box support for running projects with address sanitizers, and the ability to generate single source and header files from any project.
One adoption data point is on the page: bake is used as the primary build system for Flecs, which is by the same author. That makes the project dogfooded on a real C codebase, and it also means the most visible consumer and the most visible maintainer are the same person, which is worth keeping in mind when reading the reasoning in the FAQ.
The license answers are permissive in use and strict in distribution
Two FAQ entries deal with the GPL3.0 question directly, and both give the same shape of answer.
The first asks whether the license prevents commercial use. It does not, provided you do not distribute bake, as source or as a binary, as part of your closed source deliverable. The comparison the page draws is with make, which is also GPL licensed, and the point of the analogy is that a build tool does not infect what it builds.
The second asks whether customers can use bake. Yes, as long as your customers use the open source version of bake and you do not distribute bake binaries or source files with your product. So the boundary is not commercial versus non-commercial and not open versus closed. It is whether bake travels inside the thing you ship.
That leaves two practical obligations for a team distributing a product: do not bundle the tool or a copy of its source with the deliverable, and make sure anyone who ends up running the build gets the open source version. Both are stated on the page rather than inferred, and neither requires relicensing your own project.
Editorial conclusion
Bake is worth trying on a self-contained C or C++ project if the two things that usually go wrong, include paths and dependency discovery, are what annoy you. A dependency is a name, a project in a subdirectory is found and ordered without configuration, and no tool has to be installed for bake to drive the compilers it calls. Read three things before committing. The compiler verification list on the page names gcc 7 through 10 and clang 8 through 10, so the strict warning-free promise was last checked against that set, and the built-in emscripten support is not in the verified list at all. The install writes a wrapper into /usr/local/bin and may ask for a password, while local mode moves the burden to your own PATH. And the GPL answers are clear but conditional: using bake for commercial work is fine as long as bake itself does not travel inside your deliverable, source or binary. The last release tag is Bake 2.5.1 from 2019-09-30, with commits after it, so decide whether you want that release or the branch.
Frequently asked questions
Can I use bake for a commercial or closed source project?
Yes, as long as you do not distribute bake, either as source or as a binary, as part of your closed source deliverable. The page compares this to using make, which is also GPL licensed. Customers may also use bake as long as they use the open source version and you ship no bake binaries or source with your product.
Do I need premake installed to use bake?
No. Bake uses premake to generate its makefiles, and the generated makefiles are included in the repository, so premake is not needed to use bake. The root carries a premake5.lua, a run_premake.sh, and pre-generated build-Darwin, build-Linux, build-Mingw and build-Windows trees.
Where does bake keep its configuration and cloned projects?
In the bake environment, which defaults to $HOME/bake. That is where the bake executable is installed, where bake.json stores variables added with bake export, and where bake clone puts a repository before building it. Using PATH+=/my/path appends a path rather than assigning it.
Which platforms and compilers does bake claim to be verified on?
Linux, MacOS and Windows, with gcc 7, 8, 9 and 10, clang 8, 9 and 10, and msvc. Emscripten support is built in and bake calls emcc directly, but emcc is not listed among the verified compilers.
Is bake a package manager?
No. The answer begins by listing package-management-like features, such as resolving projects by logical name, automatic project discovery, and associating projects with git repositories, and the sentence stops partway through that last item.
Official sources
Add this badge to your README
If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.
[](https://hysenlabs.com/projects/sandermertens-bake)Star history chart for your README
[](https://hysenlabs.com/projects/sandermertens-bake)Was this useful?