diff options
author | Michael <michaelbrockus@gmail.com> | 2020-06-16 17:46:29 -0700 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2020-06-17 17:35:15 +0300 |
commit | f7b751401409fb8036b084a7d1729d45e73fe6e6 (patch) | |
tree | ed61dd8c315925feba106425602209ae2880eeaa /docs/markdown/Project-templates.md | |
parent | 07d2331d2354d27d895d926c5c8a8636f93077db (diff) | |
download | meson-f7b751401409fb8036b084a7d1729d45e73fe6e6.zip meson-f7b751401409fb8036b084a7d1729d45e73fe6e6.tar.gz meson-f7b751401409fb8036b084a7d1729d45e73fe6e6.tar.bz2 |
update Project-templates.md
Diffstat (limited to 'docs/markdown/Project-templates.md')
-rw-r--r-- | docs/markdown/Project-templates.md | 23 |
1 files changed, 21 insertions, 2 deletions
diff --git a/docs/markdown/Project-templates.md b/docs/markdown/Project-templates.md index 5f323bd..832cd1d 100644 --- a/docs/markdown/Project-templates.md +++ b/docs/markdown/Project-templates.md @@ -20,11 +20,30 @@ project. The result can be compiled as usual. For example compiling it with Ninja could be done like this: ``` -$ meson builddir -$ ninja -C builddir +$ meson setup builddir +$ meson compile -C builddir ``` The generator has many different projects and settings. They can all be listed by invoking the command `meson init --help`. This feature is available since Meson version 0.45.0. + +# Generate a build script for an existing project + +With `meson init` you can generate a build script for an existing +project with existing project files by running the command in the +root directory of your project. Meson currently supports this +feature for `executable`, and `jar` projects. + +# Build after generation of template + +It is possible to have Meson generate a build directory from the +`meson init` command without running `meson setup`. This is done +by passing `-b` or `--build` switch. + +```console +$ mkdir project_name +$ cd project_name +$ meson init --language=c --name=myproject --version=0.1 --build +```
\ No newline at end of file |