#================================================================================================== # Proposed patch, which ensures that examples and tests are truly disabled [when desired]. # # Add a new build option - 'build-examples' - which can be used to disable the former. # (Note that there is already a formal option for tests.) # # Author: Christopher Nielsen @ MacPorts # Date: 2024-04-17 # # Merge Request: https://gitlab.gnome.org/GNOME/pango/-/merge_requests/732 #================================================================================================== --- meson.build.orig 2024-04-15 16:35:49.000000000 -0400 +++ meson.build 2024-04-15 16:42:07.000000000 -0400 @@ -542,10 +542,16 @@ subdir('pango') subdir('utils') -subdir('examples') -subdir('tests') subdir('tools') +if get_option('install-tests') + subdir('tests') +endif + +if get_option('build-examples') + subdir('examples') +endif + if get_option('gtk_doc') subdir('docs') endif @@ -570,6 +576,7 @@ summary('Introspection', gir.found(), section: 'Build') summary('Documentation', get_option('gtk_doc'), section: 'Build') summary('Install tests', get_option('install-tests'), section: 'Build') +summary('Build Examples', get_option('build-examples'), section: 'Build') summary('prefix', pango_prefix, section: 'Directories') summary('includedir', pango_includedir, section: 'Directories') --- meson_options.txt.orig 2024-04-15 16:40:31.000000000 -0400 +++ meson_options.txt 2024-04-15 16:41:31.000000000 -0400 @@ -11,6 +11,10 @@ description : 'Install tests', type: 'boolean', value: false) +option('build-examples', + description : 'Build example test programs', + type: 'boolean', + value: false) option('fontconfig', description : 'Build with FontConfig support. Passing \'auto\' or \'disabled\' disables fontconfig where it is optional, i.e. on Windows and macOS. Passing \'disabled\' on platforms where fontconfig is required results in error.', type: 'feature',