2 specific_ss.add(when: ['CONFIG_SOFTMMU'], if_true: pixman) # for the include path
3 specific_ss.add(when: ['CONFIG_SOFTMMU'], if_true: opengl) # for the include path
22 softmmu_ss.add(files('dbus-module.c'))
24 softmmu_ss.add([spice_headers, files('spice-module.c')])
25 softmmu_ss.add(when: spice_protocol, if_true: files('vdagent.c'))
27 softmmu_ss.add(when: 'CONFIG_LINUX', if_true: files(
31 softmmu_ss.add(when: cocoa, if_true: files('cocoa.m'))
33 vnc_ss = ss.source_set()
41 'vnc-auth-vencrypt.c',
46 vnc_ss.add(zlib, jpeg, gnutls)
47 vnc_ss.add(when: sasl, if_true: files('vnc-auth-sasl.c'))
48 softmmu_ss.add_all(when: vnc, if_true: vnc_ss)
49 softmmu_ss.add(when: vnc, if_false: files('vnc-stubs.c'))
54 curses_ss = ss.source_set()
55 curses_ss.add(when: [curses, iconv], if_true: [files('curses.c'), pixman])
56 ui_modules += {'curses' : curses_ss}
59 softmmu_ss.add(opengl)
61 opengl_ss = ss.source_set()
63 opengl_ss.add(when: [opengl, pixman],
64 if_true: files('shader.c', 'console-gl.c', 'egl-helpers.c', 'egl-context.c'))
65 ui_modules += {'opengl' : opengl_ss}
68 if opengl.found() and gbm.found()
69 egl_headless_ss = ss.source_set()
70 egl_headless_ss.add(when: [opengl, gbm, pixman],
71 if_true: files('egl-headless.c'))
72 ui_modules += {'egl-headless' : egl_headless_ss}
76 dbus_ss = ss.source_set()
77 dbus_display1 = custom_target('dbus-display gdbus-codegen',
78 output: ['dbus-display1.h', 'dbus-display1.c'],
79 input: files('dbus-display1.xml'),
80 command: [gdbus_codegen, '@INPUT@',
81 '--glib-min-required', '2.64',
82 '--output-directory', meson.current_build_dir(),
83 '--interface-prefix', 'org.qemu.',
84 '--c-namespace', 'QemuDBus',
85 '--generate-c-code', '@BASENAME@'])
86 dbus_display1_lib = static_library('dbus-display1', dbus_display1, dependencies: gio)
87 dbus_display1_dep = declare_dependency(link_with: dbus_display1_lib, include_directories: include_directories('.'))
88 dbus_ss.add(when: [gio, pixman, dbus_display1_dep],
97 ui_modules += {'dbus' : dbus_ss}
101 softmmu_ss.add(when: 'CONFIG_WIN32', if_true: files('win32-kbd-hook.c'))
103 gtk_ss = ss.source_set()
104 gtk_ss.add(gtk, vte, pixman, files('gtk.c'))
105 if have_gtk_clipboard
106 gtk_ss.add(files('gtk-clipboard.c'))
108 gtk_ss.add(when: x11, if_true: files('x_keymap.c'))
109 gtk_ss.add(when: opengl, if_true: files('gtk-gl-area.c'))
110 gtk_ss.add(when: [x11, opengl], if_true: files('gtk-egl.c'))
111 ui_modules += {'gtk' : gtk_ss}
115 softmmu_ss.add(when: 'CONFIG_WIN32', if_true: files('win32-kbd-hook.c'))
117 sdl_ss = ss.source_set()
118 sdl_ss.add(sdl, sdl_image, pixman, glib, files(
123 sdl_ss.add(when: opengl, if_true: files('sdl2-gl.c'))
124 sdl_ss.add(when: x11, if_true: files('x_keymap.c'))
125 ui_modules += {'sdl' : sdl_ss}
129 spice_core_ss = ss.source_set()
130 spice_core_ss.add(spice, pixman, files(
135 ui_modules += {'spice-core' : spice_core_ss}
138 if spice.found() and gio.found()
139 spice_ss = ss.source_set()
140 spice_ss.add(spice, gio, pixman, files('spice-app.c'))
141 ui_modules += {'spice-app': spice_ss}
157 ['xorgevdev', 'qcode'],
158 ['xorgkbd', 'qcode'],
159 ['xorgxquartz', 'qcode'],
160 ['xorgxwin', 'qcode'],
164 if have_system or xkbcommon.found()
165 keycodemapdb_proj = subproject('keycodemapdb', required: true)
167 output = 'input-keymap-@0@-to-@1@.c.inc'.format(e[0], e[1])
168 genh += custom_target(output,
171 input: keycodemapdb_proj.get_variable('keymaps_csv'),
172 command: [python, keycodemapdb_proj.get_variable('keymap_gen').full_path(),
173 'code-map', '--lang', 'glib2',
174 '--varname', 'qemu_input_map_@0@_to_@1@'.format(e[0], e[1]),
175 '@INPUT0@', e[0], e[1]])
184 install_data('qemu.desktop', install_dir: qemu_desktopdir)
187 modules += {'ui': ui_modules}