summaryrefslogtreecommitdiff
path: root/src/meson.build
blob: a8cd1b14b05dc1b95db84a43622b2d57f0c34f11 (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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
version_data = configuration_data()
version_data.set('TERMINAL_MAJOR_VERSION', version_major)
version_data.set('TERMINAL_MINOR_VERSION', version_minor)
version_data.set('TERMINAL_MICRO_VERSION', version_micro)

version_h = configure_file(
  input: 'terminal-version.h.in',
  output: 'terminal-version.h',
  configuration: version_data,
)

cargs = [
  '-DG_LOG_DOMAIN="marco"',
  '-DTERMINAL_COMPILATION',
  '-DTERMINAL_RESOURCES_PATH_PREFIX="/org/mate/terminal"',
  '-DTERM_DATADIR="@0@"'.format(datadir),
  '-DTERM_LOCALEDIR="@0@/locale"'.format(datadir),
  '-DTERM_PKGDATADIR="@0@"'.format(pkgdatadir),
  '-DTERM_HELPDIR="@0@/help"'.format(datadir),
  '-DSN_API_NOT_YET_FROZEN',
  '-DGDK_MULTIHEAD_SAFE',
  '-DG_DISABLE_SINGLE_INCLUDES',
  '-DPANGO_DISABLE_SINGLE_INCLUDES',
  '-DATK_DISABLE_SINGLE_INCLUDES',
  '-DGDK_DISABLE_SINGLE_INCLUDES',
  '-DGDK_PIXBUF_DISABLE_SINGLE_INCLUDES',
  '-DGTK_DISABLE_SINGLE_INCLUDES',
  '-DEGG_SM_CLIENT_BACKEND_XSMP',
]

sources = [
  'eggshell.c',
  'eggshell.h',
  'profile-editor.c',
  'profile-editor.h',
  'terminal.c',
  'terminal-accels.c',
  'terminal-accels.h',
  'terminal-app.c',
  'terminal-app.h',
  'terminal-close-button.h',
  'terminal-close-button.c',
  'terminal-debug.c',
  'terminal-debug.h',
  'terminal-encoding.c',
  'terminal-encoding.h',
  'terminal-info-bar.c',
  'terminal-info-bar.h',
  'terminal-intl.h',
  'terminal-options.c',
  'terminal-options.h',
  'terminal-profile.c',
  'terminal-profile.h',
  'terminal-screen.c',
  'terminal-screen.h',
  'terminal-screen-container.c',
  'terminal-screen-container.h',
  'terminal-search-dialog.c',
  'terminal-search-dialog.h',
  'terminal-tab-label.c',
  'terminal-tab-label.h',
  'terminal-tabs-menu.c',
  'terminal-tabs-menu.h',
  'terminal-util.c',
  'terminal-util.h',
  'terminal-window.c',
  'terminal-window.h',
  version_h,
]

if build_skey
  subdir('skey')
  sources += [
    'skey-popup.c',
    'skey-popup.h',
  ]
endif

schemas_data = configuration_data()
schemas_data.set('GETTEXT_PACKAGE', meson.project_name())

schemas_in = [
  'org.mate.terminal.gschema.xml',
]

schemas = []
foreach s: schemas_in
  schemas += configure_file(
    input: '@0@.in'.format(s),
    output: '@0@'.format(s),
    configuration: schemas_data,
  )
endforeach

install_data(schemas,
  install_dir: join_paths(get_option('datadir'), 'glib-2.0/schemas'),
)

source_enum = gnome.mkenums('terminal-type-builtins',
  sources: 'terminal-profile.h',
  h_template: 'terminal-type-builtins.h.template',
  c_template: 'terminal-type-builtins.c.template',
  )

source_resources = gnome.compile_resources(
  'terminal-resources',
  'terminal.gresource.xml',
  source_dir : '.',
  c_name : 'terminal'
  )

marshalers = gnome.genmarshal('terminal-marshal',
  sources: 'terminal-marshal.list',
  prefix: '_terminal_marshal',
)

executable('mate-terminal',
  sources, source_enum, source_resources, marshalers,
  include_directories : [
    include_directories('.'),
    include_directories('..'),
    ],
  dependencies : term_deps,
  link_with : [
    libskey,
    ],
  c_args : cargs,
  install: true,
)