diff options
author | Jukka Laurila <jlaurila@google.com> | 2018-02-24 23:44:20 +0100 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2018-03-06 00:05:17 +0200 |
commit | 8f340ffb8db0eea74dcdb1068ee575d28d39dbb2 (patch) | |
tree | c6113d256a02a22e9e24f1e856616a29da3480e9 /docs/markdown | |
parent | fcb95847edb05d900725923697974688ab1121bb (diff) | |
download | meson-8f340ffb8db0eea74dcdb1068ee575d28d39dbb2.zip meson-8f340ffb8db0eea74dcdb1068ee575d28d39dbb2.tar.gz meson-8f340ffb8db0eea74dcdb1068ee575d28d39dbb2.tar.bz2 |
Generate meson.build based on existing source files when meson init is run in a non-empty directory.
Diffstat (limited to 'docs/markdown')
-rw-r--r-- | docs/markdown/snippets/improved-meson-init.md | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/docs/markdown/snippets/improved-meson-init.md b/docs/markdown/snippets/improved-meson-init.md new file mode 100644 index 0000000..ec17bc4 --- /dev/null +++ b/docs/markdown/snippets/improved-meson-init.md @@ -0,0 +1,19 @@ +## Autogeneration of simple meson.build files + +A feature to generate a meson.build file compiling given C/C++ source +files into a single executable has been added to "meson init". By +default, it will take all recognizable source files in the current +directory. You can also specify a list of dependencies with the -d +flag and automatically invoke a build with the -b flag to check if the +code builds with those dependencies. + +For example, + +```meson +meson init -fbd sdl2,gl +``` + +will look for C or C++ files in the current directory, generate a +meson.build for them with the dependencies of sdl2 and gl and +immediately try to build it, overwriting any previous meson.build and +build directory. |