meson.build 2.01 KB
Newer Older
Robert Roth's avatar
Robert Roth committed
1
desktop = 'org.gnome.five-or-more.desktop'
Ruxandra Simion's avatar
Ruxandra Simion committed
2
# Desktop file
3
desktop_file = i18n.merge_file (
Robert Roth's avatar
Robert Roth committed
4 5
  input: desktop + '.in',
  output: desktop,
Ruxandra Simion's avatar
Ruxandra Simion committed
6 7 8 9
  type: 'desktop',
  po_dir: po_dir,
  install: true,
  install_dir: join_paths (data_dir, 'applications')
Ruxandra Simion's avatar
Ruxandra Simion committed
10
)
11 12 13 14 15 16 17 18 19 20
desktop_file_validate = find_program('desktop-file-validate', required: false)
if desktop_file_validate.found()
  test(
    'validate-desktop',
    desktop_file_validate,
    args: [
      desktop_file.full_path()
    ]
  )
endif
Ruxandra Simion's avatar
Ruxandra Simion committed
21 22

# Themes
23
foreach file: ['balls.svg', 'shapes.svg', 'tango.svg']
Ruxandra Simion's avatar
Ruxandra Simion committed
24 25 26
  install_data (file,
                install_dir: join_paths(pkgdata_dir, 'themes')
  )
Ruxandra Simion's avatar
Ruxandra Simion committed
27 28 29
endforeach

# UI files
Robert Roth's avatar
Robert Roth committed
30
foreach file: ['five-or-more.ui', 'five-or-more-preferences.ui']
Ruxandra Simion's avatar
Ruxandra Simion committed
31 32 33
  install_data (file,
    install_dir: join_paths (pkgdata_dir)
  )
Ruxandra Simion's avatar
Ruxandra Simion committed
34 35 36
endforeach

# Icons
37
foreach size: [ '16x16', '22x22', '24x24', '32x32', '48x48', '256x256', '512x512' ]
Robert Roth's avatar
Robert Roth committed
38
    install_data(join_paths('icons', 'hicolor', size, 'org.gnome.five-or-more.png'),
39 40
                 install_dir: join_paths (data_dir, 'icons', 'hicolor', size, 'apps')
    )
41
endforeach
42

Robert Roth's avatar
Robert Roth committed
43
install_data (join_paths ('icons', 'hicolor', 'symbolic', 'org.gnome.five-or-more-symbolic.svg'),
Ruxandra Simion's avatar
Ruxandra Simion committed
44 45
             install_dir: join_paths (data_dir, 'icons', 'hicolor', 'symbolic', 'apps')
             )
Ruxandra Simion's avatar
Ruxandra Simion committed
46

Robert Roth's avatar
Robert Roth committed
47
appdata = 'org.gnome.five-or-more.appdata.xml'
Ruxandra Simion's avatar
Ruxandra Simion committed
48
# Appdata
49
appdata_file = i18n.merge_file (
Robert Roth's avatar
Robert Roth committed
50 51
  input: appdata + '.in',
  output: appdata,
Ruxandra Simion's avatar
Ruxandra Simion committed
52 53 54 55
  type: 'xml',
  po_dir: po_dir,
  install: true,
  install_dir: join_paths (data_dir, 'metainfo'),
Ruxandra Simion's avatar
Ruxandra Simion committed
56
)
57 58 59 60 61 62 63 64 65
appstream_util = find_program('appstream-util', required: false)
if appstream_util.found()
  test(
    'validate-appdata', appstream_util,
    args: [
      'validate-relax', '--nonet', appdata_file.full_path()
    ]
  )
endif
Ruxandra Simion's avatar
Ruxandra Simion committed
66 67

# Gschema
Ruxandra Simion's avatar
Ruxandra Simion committed
68 69
install_data ('org.gnome.five-or-more.gschema.xml',
  install_dir: join_paths (data_dir, 'glib-2.0', 'schemas')
Ruxandra Simion's avatar
Ruxandra Simion committed
70 71
)

72
# Gresource
Ruxandra Simion's avatar
Ruxandra Simion committed
73 74
resource_files = files ('org.gnome.five-or-more.gresource.xml')
resources = gnome.compile_resources ('five-or-more', resource_files)
75

Ruxandra Simion's avatar
Ruxandra Simion committed
76
# Manpage
Ruxandra Simion's avatar
Ruxandra Simion committed
77 78
install_man (
  'five-or-more.6'
Ruxandra Simion's avatar
Ruxandra Simion committed
79
)