Files
tldr/pages.zh/common/meson.md

28 lines
538 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# meson
> 类似SCons的构建系统使用Python作为前端语言Ninja作为构建后端。
> 更多信息请访问:<https://mesonbuild.com>。
- 生成一个具有给定名称和版本的C项目
`meson init --language={{c}} --name={{myproject}} --version={{0.1}}`
- 使用默认值配置 `builddir`
`meson setup {{build_dir}}`
- 构建项目:
`meson compile -C {{path/to/build_dir}}`
- 运行项目中的所有测试:
`meson test`
- 显示帮助信息:
`meson --help`
- 显示版本:
`meson --version`