diff options
author | Philip Chimento <philip.chimento@gmail.com> | 2020-01-13 22:35:56 -0800 |
---|---|---|
committer | Philip Chimento <philip.chimento@gmail.com> | 2020-01-21 22:35:27 -0800 |
commit | aad47f9b07dc6105c3ce10059a83efea4a36bcfc (patch) | |
tree | e4cda4c4c732fe524cdfdab3632bbe5ce10ba739 /clang-plugin | |
parent | 9e9dea45678c01b95bc85bf4915e42c2094fdde2 (diff) |
build: Meson build system
Removes the existing Autotools build system and adds a new Meson one.
Also replaces the shell script test driver with a Python one, since
Meson already brings in a Python dependency.
Common operations:
- ./configure -> meson _build
- make -> ninja -C _build
- make install -> ninja -C _build install
- make check -> meson test -C _build
- make Tartan.pot-update -> ninja -C _build tartan-pot
- make update-po -> ninja -C _build tartan-update-po
To run the tests with coverage enabled and make a coverage report:
- meson _build -Db_coverage=true
- meson test -C _build
- ninja -C _build coverage-html
Diffstat (limited to 'clang-plugin')
-rw-r--r-- | clang-plugin/meson.build | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/clang-plugin/meson.build b/clang-plugin/meson.build new file mode 100644 index 0000000..9810177 --- /dev/null +++ b/clang-plugin/meson.build @@ -0,0 +1,39 @@ +plugin_sources = [ + 'assertion-extracter.cpp', + 'assertion-extracter.h', + 'checker.cpp', + 'checker.h', + 'debug.cpp', + 'debug.h', + 'gassert-attributes.cpp', + 'gassert-attributes.h', + 'gerror-checker.cpp', + 'gerror-checker.h', + 'gir-attributes.cpp', + 'gir-attributes.h', + 'gir-manager.cpp', + 'gir-manager.h', + 'gsignal-checker.cpp', + 'gsignal-checker.h', + 'gvariant-checker.cpp', + 'gvariant-checker.h', + 'nullability-checker.cpp', + 'nullability-checker.h', + 'plugin.cpp', + 'type-manager.cpp', + 'type-manager.h', +] + +version_arr = llvm.version().split('.') +llvm_major = version_arr[0] +llvm_minor = version_arr[1] +normalized_llvm_version = '@0@.@1@'.format(llvm_major, llvm_minor) + +plugindir = join_paths(get_option('libdir'), meson.project_name(), + normalized_llvm_version) + +plugin = shared_module('tartan', plugin_sources, name_suffix: 'so', + dependencies: [llvm, glib, gobject, gio, gi], + cpp_args: ['-DG_LOG_DOMAIN="tartan"'], + include_directories: config_h_include, + install: true, install_dir: plugindir) |