mirror of
https://gitlab.gnome.org/GNOME/gimp.git
synced 2025-07-04 01:43:24 +00:00
meson: fix relocatable-bundle feature and mypaint-brushes dependency.
It must not be a boolean but a `feature` option, with `auto` by default. `auto` value mean enabled for macOS and Win32, and disabled for other cases. This default logics disappeared in the meson build. Also the mypaint-brushes package is a mandatory dependency, which must always be checked. Absence is fatale. Finally properly set the MYPAINT_BRUSHES_DIR macro depending on the proper relocatable case.
This commit is contained in:
parent
2b67a54b15
commit
738dab0fce
4 changed files with 36 additions and 19 deletions
|
@ -7,7 +7,7 @@ manconf.set('gimplocaledir', prefix / localedir)
|
||||||
manconf.set('gimpplugindir', prefix / gimpplugindir)
|
manconf.set('gimpplugindir', prefix / gimpplugindir)
|
||||||
manconf.set('manpage_gimpdir', '$XDG_CONFIG_HOME/' + gimpdir / gimp_app_version)
|
manconf.set('manpage_gimpdir', '$XDG_CONFIG_HOME/' + gimpdir / gimp_app_version)
|
||||||
manconf.set('gimpsysconfdir', prefix / gimpsysconfdir)
|
manconf.set('gimpsysconfdir', prefix / gimpsysconfdir)
|
||||||
manconf.set('mypaint_brushes_dir', libmypaint_brushes_dir)
|
manconf.set('mypaint_brushes_dir', mypaint_brushes_dir)
|
||||||
|
|
||||||
|
|
||||||
man_files = [
|
man_files = [
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
etcconf = configuration_data()
|
etcconf = configuration_data()
|
||||||
etcconf.set('mypaint_brushes_dir', libmypaint_brushes_dir)
|
etcconf.set('mypaint_brushes_dir', mypaint_brushes_dir)
|
||||||
|
|
||||||
|
|
||||||
install_data(
|
install_data(
|
||||||
|
|
29
meson.build
29
meson.build
|
@ -287,7 +287,20 @@ no_dep = dependency('', required: false)
|
||||||
################################################################################
|
################################################################################
|
||||||
# Mandatory Dependencies
|
# Mandatory Dependencies
|
||||||
|
|
||||||
relocatable_bundle = get_option('relocatable-bundle')
|
if get_option('relocatable-bundle').enabled()
|
||||||
|
relocatable_bundle = true
|
||||||
|
elif get_option('relocatable-bundle').disabled()
|
||||||
|
relocatable_bundle = false
|
||||||
|
else # .auto()
|
||||||
|
# By default, assume building for Windows or macOS everything to be on
|
||||||
|
# the same prefix and can be relocated.
|
||||||
|
# On other platforms, build-time paths are meaningful.
|
||||||
|
if platform_windows or platform_osx
|
||||||
|
relocatable_bundle = true
|
||||||
|
else
|
||||||
|
relocatable_bundle = false
|
||||||
|
endif
|
||||||
|
endif
|
||||||
conf.set('ENABLE_RELOCATABLE_RESOURCES', relocatable_bundle)
|
conf.set('ENABLE_RELOCATABLE_RESOURCES', relocatable_bundle)
|
||||||
|
|
||||||
|
|
||||||
|
@ -335,15 +348,15 @@ lcms = dependency('lcms2', version: '>=2.8')
|
||||||
|
|
||||||
libmypaint = dependency('libmypaint', version: '>=1.3.0')
|
libmypaint = dependency('libmypaint', version: '>=1.3.0')
|
||||||
|
|
||||||
libmypaint_brushes= relocatable_bundle ? no_dep : \
|
mypaint_brushes = dependency('mypaint-brushes-1.0', version: '>=1.3.0')
|
||||||
dependency('mypaint-brushes-1.0', version: '>=1.3.0', required: false)
|
|
||||||
|
|
||||||
libmypaint_brushes_dir = libmypaint_brushes.get_pkgconfig_variable(
|
if relocatable_bundle
|
||||||
'brushesdir',
|
mypaint_brushes_dir = '${gimp_installation_dir}'/'share'/'mypaint-data'/'1.0'/'brushes'
|
||||||
default: '${gimp_installation_dir}'/'share'/'mypaint-data'/'1.0'/'brushes',
|
else
|
||||||
)
|
mypaint_brushes_dir = mypaint_brushes.get_pkgconfig_variable('brushesdir')
|
||||||
|
endif
|
||||||
|
|
||||||
conf.set_quoted('MYPAINT_BRUSHES_DIR', libmypaint_brushes_dir)
|
conf.set_quoted('MYPAINT_BRUSHES_DIR', mypaint_brushes_dir)
|
||||||
|
|
||||||
pangocairo = dependency('pangocairo', version: '>=1.29.4')
|
pangocairo = dependency('pangocairo', version: '>=1.29.4')
|
||||||
pangoft2 = dependency('pangoft2', version: '>=1.29.4')
|
pangoft2 = dependency('pangoft2', version: '>=1.29.4')
|
||||||
|
|
|
@ -6,8 +6,12 @@ option('enable-default-bin',type: 'boolean', value: true, description: 'Build de
|
||||||
option('enable-multiproc', type: 'boolean', value: true, description: 'Support for multiple processors')
|
option('enable-multiproc', type: 'boolean', value: true, description: 'Support for multiple processors')
|
||||||
option('profiling', type: 'boolean', value: false, description: 'Enable profiling')
|
option('profiling', type: 'boolean', value: false, description: 'Enable profiling')
|
||||||
option('windows-installer', type: 'boolean', value: false, description: 'Generate files needed for the Windows installer')
|
option('windows-installer', type: 'boolean', value: false, description: 'Generate files needed for the Windows installer')
|
||||||
option('relocatable-bundle',type: 'boolean', value: false,description: 'build with resources considered bundled under the same prefix')
|
|
||||||
option('shmem-type', type: 'combo', value: 'auto', description: 'Shared memory transport type', choices: [ 'none', 'sysv', 'posix', 'win32', 'auto' ])
|
option('relocatable-bundle',type: 'feature', value: 'auto', description: 'build with resources considered bundled under the same prefix')
|
||||||
|
|
||||||
|
option('shmem-type', type: 'combo', value: 'auto', description: 'Shared memory transport type',
|
||||||
|
choices: [ 'none', 'sysv', 'posix', 'win32', 'auto' ])
|
||||||
|
|
||||||
option('bug-report-url', type: 'string', value: '', description: 'URL used by the debug dialog to report bugs')
|
option('bug-report-url', type: 'string', value: '', description: 'URL used by the debug dialog to report bugs')
|
||||||
option('gimpdir', type: 'string', value: '', description: 'Change default gimpdir from ~/.config/GIMP/2.9 to ~/.config/DIR/2.9 (if relative), or to DIR (if absolute)')
|
option('gimpdir', type: 'string', value: '', description: 'Change default gimpdir from ~/.config/GIMP/2.9 to ~/.config/DIR/2.9 (if relative), or to DIR (if absolute)')
|
||||||
option('icc-directory', type: 'string', value: '', description: 'Path to default color profiles for this system')
|
option('icc-directory', type: 'string', value: '', description: 'Path to default color profiles for this system')
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue