|dirkson d6f7f52e85 Improving clean behavior, fixing script locations||1 week ago|
|subprojects||1 week ago|
|.gitignore||1 year ago|
|LICENSE||1 year ago|
|README.md||1 week ago|
|build||1 week ago|
Osmia is a busy little bee of a build script for meson projects. It works around some of meson’s stranger design decisions.
Meson fills its directory with a mix of files you might want to interact with and meson internal files. Osmia provides “bin”, “lib”, and “doc” directories full of symlinks so that you don’t have to hunt around inside the meson build dir to find what you need.
Meson doesn’t provide tools to automatically procure and build dependencies without a meson file. This means that you cannot use a dependency without a meson build system. Osmia fills this gap with its ‘subprojects/dependencies’ file.
Meson sometimes requires one of two separate commands (“meson” or “ninja”) to build. Osmia figures out which command(s) currently need to be run to build and does it for you.
Using Meson alone, it’s unclear to users unfamilliar with meson how to build your software. By providing a simple ./build script that walks them through missing dependencies (meson, ninja, optionally ccache), osmia makes it easier for end users to build your software.
At the time of this writing, meson will attempt to use ccache, but will stop using it once you specify some different compiler to back it with. Osmia attempts to guess the compiler you want, (Clang, GCC, others) but can also be told to use a specific compiler with “COMPILER=”. When specifying a compiler this way, ccache will still be automatically used if available.
Osmia stays out of Meson’s way, so you can always use the standard Meson/ninja build commands instead of or in addition to the osmia wrapper.
Drop the “build” file into your project at the root directory and run it (“./build”) when you want to build.
./build [-mode] [target]
Target will be passed to ninja directly
Mode defaults to ‘release’, or can be one of the following:
Osmia will return appropriately when called, so you can do constructs such as: ./build -d && ./bin/mytest
The end goal of this thing is basically to lose all its features to Meson over time. For example, there’s no reason I can see that calling ‘meson’ again shouldn’t just run ninja for you.