Skip to content

Commit 4e68e17

Browse files
committed
Meson build: Add install_tag keyword argument
1 parent 8e33aa7 commit 4e68e17

File tree

5 files changed

+15
-8
lines changed

5 files changed

+15
-8
lines changed

docs/docs/manual/meson.build

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@ custom_target('manual_html',
6161
],
6262
build_by_default: true,
6363
install: true,
64-
install_dir: install_tutorialdir
64+
install_dir: install_tutorialdir,
65+
install_tag: 'doc',
6566
)
6667

6768
if can_parse_and_validate

docs/docs/reference/meson.build

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ tag_file = custom_target('html_and_tag',
102102
build_by_default: build_documentation,
103103
install: true,
104104
install_dir: install_reference_docdir,
105+
install_tag: 'doc',
105106
)
106107

107108
devhelp_file = custom_target('devhelp',
@@ -125,7 +126,8 @@ meson.add_install_script(
125126
devhelp_file.full_path(),
126127
install_devhelpdir,
127128
install_reference_docdir / 'html',
128-
docinstall_flags
129+
docinstall_flags,
130+
install_tag: 'doc',
129131
)
130132

131133
# Distribute built files and files copied by mm-common-get.

examples/meson.build

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ foreach ex : examples
2323
cpp_args: '-DSIGCXX_DISABLE_DEPRECATED=1',
2424
dependencies: sigcxx_own_dep,
2525
implicit_include_directories: false,
26-
build_by_default: build_examples
26+
build_by_default: build_examples,
27+
install: false,
2728
)
2829
endforeach

meson.build

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,10 +33,9 @@ sigcxx_libversion = '@0@.@1@.@2@'.format(
3333
libtool_soversion[1])
3434
darwin_versions = [libtool_soversion[0] + 1, '@0@.@1@'.format(libtool_soversion[0] + 1, libtool_soversion[1])]
3535

36-
# Use these instead of meson.source_root() and meson.build_root() in subdirectories.
37-
# source_root() and build_root() are not useful, if this is a subproject.
38-
project_source_root = meson.current_source_dir()
39-
project_build_root = meson.current_build_dir()
36+
# Source and build root directories of the current (sub)project.
37+
project_source_root = meson.project_source_root()
38+
project_build_root = meson.project_build_root()
4039

4140
cpp_compiler = meson.get_compiler('cpp')
4241
cpp_compiler_id = cpp_compiler.get_id()
@@ -252,7 +251,9 @@ configure_file(
252251
input: sigcxxconfig_h_meson,
253252
output: 'sigc++config.h',
254253
configuration: pkg_conf_data,
254+
install: true,
255255
install_dir: install_includeconfigdir,
256+
install_tag: 'devel',
256257
)
257258

258259
#subdir('cmake')

tests/meson.build

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ foreach ex : test_programs
7070
dependencies: sigcxx_own_dep,
7171
implicit_include_directories: false,
7272
build_by_default: build_tests,
73+
install: false,
7374
)
7475

7576
# If exe_file is a test program, it is built by default unconditionally.
@@ -93,7 +94,8 @@ if can_benchmark
9394
exe_file = executable(ex_name, ex_sources,
9495
dependencies: [sigcxx_own_dep, benchmark_dep],
9596
implicit_include_directories: false,
96-
build_by_default: do_benchmark
97+
build_by_default: do_benchmark,
98+
install: false,
9799
)
98100

99101
if do_benchmark

0 commit comments

Comments
 (0)