summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build20
1 files changed, 13 insertions, 7 deletions
diff --git a/meson.build b/meson.build
index b5d58e7..c490382 100644
--- a/meson.build
+++ b/meson.build
@@ -133,8 +133,11 @@ endif
mm_common_get = find_program('mm-common-get', required: false)
if maintainer_mode and not mm_common_get.found()
- error('Maintainer mode requires the \'mm-common-get\' command.\n' +
- 'Use \'-Dmaintainer-mode=false\' or install the \'mm-common\' package, version 1.0.0 or higher')
+ message('Maintainer mode requires the \'mm-common-get\' command. If it is not found,\n' +
+ 'use \'-Dmaintainer-mode=false\' or install the \'mm-common\' package, version 1.0.0 or higher.')
+ # If meson --wrap-mode != forcefallback, Meson falls back to the mm-common
+ # subproject only if mm-common-get is required.
+ mm_common_get = find_program('mm-common-get', required: true)
endif
perl = find_program('perl', required: build_documentation)
@@ -280,13 +283,16 @@ if can_add_dist_script
endif
if meson.is_subproject()
+ pkgconfig_vars = {
+ 'htmlrefdir': install_prefix / install_docdir / 'reference' / 'html',
+ 'htmlrefpub': 'http://www.cairographics.org/documentation/cairomm/reference'
+ }
+ if build_documentation
+ pkgconfig_vars += {'doxytagfile': tag_file.full_path()}
+ endif
cairomm_dep = declare_dependency(
dependencies: cairomm_own_dep,
- variables: {
- 'doxytagfile': tag_file.full_path(),
- 'htmlrefdir': install_prefix / install_docdir / 'reference' / 'html',
- 'htmlrefpub': 'http://www.cairographics.org/documentation/cairomm/reference'
- }
+ variables: pkgconfig_vars,
)
# A main project that looks for cairomm_pcname.pc shall find cairomm_dep.