meson.build 1.63 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77
subdir('icons')

# Desktop file
desktops = [ev_namespace + '.desktop']

if enable_previewer
  desktops += [ev_namespace + '-previewer.desktop']
endif

foreach desktop: desktops
  desktop_in = configure_file(
    input: desktop + '.in.in',
    output: desktop + '.in',
    configuration: mime_types_conf,
  )

  custom_target(
    desktop,
    input: desktop_in,
    output: desktop,
    command: intltool_desktop_cmd,
    install: true,
    install_dir: join_paths(ev_datadir, 'applications'),
  )
endforeach

# DBus service file
if enable_dbus
  service_conf = configuration_data()
  service_conf.set('libexecdir', join_paths(ev_prefix, ev_libexecdir))
  service_conf.set('if_systemd_service', '')

  services = [[ev_namespace + '.Daemon.service', dbus_service_dir]]

  if install_systemd_user_unit_dir
    services += [[ev_namespace + '.service', systemd_user_unit_dir]]
  endif

  foreach service: services
    configure_file(
      input: service[0] + '.in',
      output: service[0],
      configuration: service_conf,
      install: true,
      install_dir: service[1],
    )
  endforeach
endif

# GSettings schema
gschema = ev_namespace + '.gschema.xml'

custom_target(
  gschema,
  input: gschema + '.in',
  output: gschema,
  command: [intltool_merge, '-x', '-u', '--no-translations', '@INPUT@', '@OUTPUT@'],
  install: true,
  install_dir: join_paths(ev_datadir, 'glib-2.0', 'schemas'),
)

install_data(
  'evince.convert',
  install_dir: join_paths(ev_datadir, 'GConf', 'gsettings'),
)

# man file
install_data(
  'evince.1',
  install_dir: join_paths(ev_mandir, 'man1'),
)

# UI descriptions
install_data(
  'hand-open.png',
  install_dir: ev_pkgdatadir,
)