summaryrefslogtreecommitdiffstats
path: root/tools/meson.build
blob: 68be8a4a0119344412d15bd0a62f79e4d3616330 (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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
install_data(
  'gnome-session-custom-session',
  install_dir: session_bindir
)

deps = session_deps + [
  sm_dep,
  ice_dep
]

cflags = ['-DLOCALE_DIR="@0@"'.format(session_localedir)]

programs = [
  # name, deps, cflags, install_dir
  ['gnome-session-quit', deps, cflags, session_bindir],
  ['gnome-session-inhibit', session_deps, cflags, session_bindir]
]

if enable_systemd_session
  programs += [['gnome-session-ctl', session_bin_deps, cflags, session_libexecdir]]
endif

if enable_session_selector
  deps = [
    glib_dep,
    gtk_dep
  ]

  cflags += '-DGTKBUILDER_DIR="@0@"'.format(session_pkgdatadir)

  programs += [['gnome-session-selector', deps, cflags, session_bindir]]
endif

deps = [
  gtk_dep,
  x11_dep,
  dependency('egl'),
  dependency('glesv2')
]

cflags = '-DPKGDATADIR="@0@"'.format(session_pkgdatadir)

programs += [['gnome-session-check-accelerated-gles-helper', deps, cflags, session_libexecdir]]

deps = [
  glib_dep,
  x11_dep,
  dependency('gl'),
  dependency('epoxy'),
  dependency('xcomposite')
]

programs += [['gnome-session-check-accelerated-gl-helper', deps, cflags, session_libexecdir]]

deps += [gtk_dep]

cflags = '-DLIBEXECDIR="@0@"'.format(session_libexecdir)

programs += [['gnome-session-check-accelerated', deps, cflags, session_libexecdir]]

foreach program: programs
  executable(
    program[0],
    program[0] + '.c',
    include_directories: top_inc,
    dependencies: program[1],
    c_args: program[2],
    install: true,
    install_dir: program[3]
  )
endforeach