mirror of
https://gitlab.gnome.org/GNOME/gimp.git
synced 2025-07-03 09:23:24 +00:00

appstreamcli was returning the error: > E: gimp-data-extras:3: cid-is-not-rdns gimp-data-extras Apparently non-desktop component must absolutely follow the schema with a unique identifier with 3 parts or more. As advised in the spec, let's use the main desktop component ID, adding a specific subpart. Also use underscore rather than hyphen for maximum compatibility. See: https://freedesktop.org/software/appstream/docs/chap-Metadata.html#tag-id-generic Finally for addons, share/metainfo/ is the recommended install path. See: https://freedesktop.org/software/appstream/docs/sect-Metadata-Addon.html
122 lines
2.7 KiB
Meson
122 lines
2.7 KiB
Meson
sizes = [
|
|
'16',
|
|
'22',
|
|
'24',
|
|
'32',
|
|
'48',
|
|
'64',
|
|
'256',
|
|
]
|
|
|
|
foreach size : sizes
|
|
sizedir = size+'x'+size
|
|
install_data(sizedir / 'gimp.png',
|
|
install_dir: get_option('datadir') / 'icons' / 'hicolor' / sizedir / 'apps'
|
|
)
|
|
endforeach
|
|
install_data('scalable/gimp.svg',
|
|
install_dir: get_option('datadir') / 'icons' / 'hicolor' / 'scalable' / 'apps'
|
|
)
|
|
|
|
desktopfilename = 'gimp.desktop'
|
|
|
|
desktop_conf = configuration_data()
|
|
desktop_conf.set('GIMP_COMMAND', gimp_command)
|
|
desktop_conf.set('GIMP_VERSION', gimp_version)
|
|
desktop_conf.set('GIMP_APP_VERSION', gimp_app_version)
|
|
desktop_conf.set('MIME_TYPES', ';'.join(MIMEtypes))
|
|
desktop_conf.set('BUG_REPORT_URL', bug_report_url)
|
|
|
|
desktopfilein = configure_file(
|
|
input : desktopfilename+'.in.in',
|
|
output: desktopfilename+'.in',
|
|
configuration: desktop_conf,
|
|
)
|
|
|
|
desktopfile = custom_target(desktopfilename,
|
|
input : [ desktopfilein, ],
|
|
output: [ desktopfilename, ],
|
|
command: [
|
|
intltool_merge,
|
|
po_dir,
|
|
'@INPUT@',
|
|
'@OUTPUT@',
|
|
'--desktop-style',
|
|
'--utf8',
|
|
'--cache=' + '@OUTDIR@' / 'intltool-merge-cache',
|
|
],
|
|
install: true,
|
|
install_dir: get_option('datadir') / 'applications',
|
|
)
|
|
|
|
appdatafilename = 'org.gimp.GIMP.appdata.xml'
|
|
appdatafilein = configure_file(
|
|
input : appdatafilename+'.in.in',
|
|
output: appdatafilename+'.in',
|
|
configuration: desktop_conf,
|
|
)
|
|
appdatafile = custom_target(appdatafilename,
|
|
input : [ appdatafilein, ],
|
|
output: [ appdatafilename, ],
|
|
command: [
|
|
intltool_merge,
|
|
po_dir,
|
|
'@INPUT@',
|
|
'@OUTPUT@',
|
|
'--xml-style',
|
|
'--utf8',
|
|
'--cache=' + '@OUTDIR@' / 'intltool-merge-cache',
|
|
],
|
|
install: true,
|
|
install_dir: get_option('datadir') / 'metainfo',
|
|
)
|
|
|
|
metainfofilename = 'org.gimp.GIMP.data_extras.metainfo.xml'
|
|
metainfofilein = configure_file(
|
|
input : metainfofilename+'.in.in',
|
|
output: metainfofilename+'.in',
|
|
configuration: desktop_conf,
|
|
)
|
|
metainfofile = custom_target(metainfofilename,
|
|
input : [ metainfofilein, ],
|
|
output: [ metainfofilename, ],
|
|
command: [
|
|
intltool_merge,
|
|
po_dir,
|
|
'@INPUT@',
|
|
'@OUTPUT@',
|
|
'--xml-style',
|
|
'--utf8',
|
|
'--cache=' + '@OUTDIR@' / 'intltool-merge-cache',
|
|
],
|
|
install: true,
|
|
install_dir: get_option('datadir') / 'metainfo',
|
|
)
|
|
|
|
if desktop_validate.found()
|
|
test('validate-desktop',
|
|
desktop_validate,
|
|
args: [ desktopfile ],
|
|
suite: 'desktop',
|
|
)
|
|
endif
|
|
|
|
if appstreamcli.found()
|
|
test('appdata_file',
|
|
appstreamcli,
|
|
args: [ 'validate', appdatafile ],
|
|
env: [
|
|
'GIMP_TESTING_ABS_TOP_BUILDDIR=' + meson.build_root(),
|
|
],
|
|
suite: 'desktop',
|
|
)
|
|
|
|
test('metainfo_file',
|
|
appstreamcli,
|
|
args: [ 'validate', metainfofile ],
|
|
env: [
|
|
'GIMP_TESTING_ABS_TOP_BUILDDIR=' + meson.build_root(),
|
|
],
|
|
suite: 'desktop',
|
|
)
|
|
endif
|