summaryrefslogtreecommitdiffstats
path: root/plugins/color/meson.build
blob: 2ae1740a72ab9edfde5706a0754c91d0de99b9ad (plain)
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
sources = files(
  'gcm-edid.c',
  'gnome-datetime-source.c',
  'gsd-color-calibrate.c',
  'gsd-color-manager.c',
  'gsd-color-profiles.c',
  'gsd-color-state.c',
  'gsd-night-light.c',
  'gsd-night-light-common.c',
  'main.c'
)

deps = plugins_deps + [
  colord_dep,
  gnome_desktop_dep,
  lcms_dep,
  libcanberra_gtk_dep,
  libgeoclue_dep,
  libnotify_dep,
  m_dep,
]

cflags += ['-DBINDIR="@0@"'.format(gsd_bindir)]

executable(
  'gsd-' + plugin_name,
  sources,
  include_directories: [top_inc, common_inc],
  dependencies: deps,
  c_args: cflags,
  install: true,
  install_rpath: gsd_pkglibdir,
  install_dir: gsd_libexecdir
)

sources = files(
  'gcm-edid.c',
  'gcm-self-test.c',
  'gnome-datetime-source.c',
  'gsd-night-light.c',
  'gsd-night-light-common.c'
)

test_unit = 'gcm-self-test'

exe = executable(
  test_unit,
  sources,
  include_directories: top_inc,
  dependencies: deps,
  c_args: '-DTESTDATADIR="@0@"'.format(join_paths(meson.current_source_dir(), 'test-data'))
)

envs = ['GSETTINGS_SCHEMA_DIR=@0@'.format(join_paths(meson.build_root(), 'data'))]
test(test_unit, exe, env: envs)