Codebase list xapp / 5a7b452
build: Allow making a library-only build for flatpak packaging. It's not worth bundling libgnomekbd into a flatpak either so drop the layout controller also, which isn't really useful outside of Cinnamon desktop components anyhow. Michael Webster 3 years ago
4 changed file(s) with 25 addition(s) and 11 deletion(s). Raw diff Collapse all Expand all
55 libdeps += dependency('gtk+-3.0', version: '>=3.3.16', required: true)
66 libdeps += dependency('gdk-pixbuf-2.0', version: '>=2.22.0', required: true)
77 libdeps += dependency('cairo', required: true)
8 libdeps += dependency('libgnomekbdui', required: true)
98 libdeps += dependency('x11', required: true)
109
1110 xapp_headers = [
1211 'xapp-gtk-window.h',
1312 'xapp-icon-chooser-button.h',
1413 'xapp-icon-chooser-dialog.h',
15 'xapp-kbd-layout-controller.h',
1614 'xapp-monitor-blanker.h',
1715 'xapp-preferences-window.h',
1816 'xapp-stack-sidebar.h',
2624 'xapp-gtk-window.c',
2725 'xapp-icon-chooser-button.c',
2826 'xapp-icon-chooser-dialog.c',
29 'xapp-kbd-layout-controller.c',
3027 'xapp-monitor-blanker.c',
3128 'xapp-preferences-window.c',
3229 'xapp-stack-sidebar.c',
3431 'xapp-status-icon-monitor.c',
3532 'xapp-util.c'
3633 ]
34
35 if not app_lib_only
36 libdeps += dependency('libgnomekbdui', required: true)
37 xapp_headers += 'xapp-kbd-layout-controller.h'
38 xapp_sources += 'xapp-kbd-layout-controller.c'
39 endif
3740
3841 dbus_headers = []
3942
99 dbus_services_dir = dependency('dbus-1').get_pkgconfig_variable('session_bus_services_dir',
1010 define_variable: ['prefix', get_option('prefix')])
1111 libexec_path = join_paths(get_option('prefix'), get_option('libexecdir'), 'xapps', 'sn-watcher')
12
13
1412
1513 cdata = configuration_data()
1614 cdata.set_quoted('GETTEXT_PACKAGE', 'xapp')
3331 )
3432 endif
3533
34 app_lib_only = get_option('app-lib-only')
35
3636 c = configure_file(output : 'config.h',
3737 configuration : cdata
3838 )
4040 top_inc = include_directories('.')
4141 codegen = find_program(join_paths(meson.source_root(), 'meson-scripts', 'g-codegen.py'))
4242
43 subdir('icons')
4443 subdir('libxapp')
4544 subdir('po')
45 subdir('schemas')
4646 subdir('pygobject')
47 subdir('schemas')
48 subdir('status-applets')
49 subdir('scripts')
5047
51 if get_option('status-notifier')
48 if not app_lib_only
49 subdir('icons')
50 subdir('status-applets')
51 subdir('scripts')
52 endif
53
54 if get_option('status-notifier') and not app_lib_only
5255 subdir('xapp-sn-watcher')
5356 endif
5457
1616 type: 'boolean',
1717 value: true,
1818 description: 'Build the XApp StatusNotifier service.'
19 )
19 )
20 option('app-lib-only',
21 type: 'boolean',
22 value: false,
23 description: 'Limit build to core library only and without the keyboard layout controller. This is to allow flatpak bundlings.'
24 )
25
405405 cairo_status_t status = CAIRO_STATUS_SUCCESS;
406406 status = cairo_surface_write_to_png (surface, save_filename);
407407
408 g_debug ("Saving tmp image file for '%s' to '%s'", item->sortable_name, save_filename);
409
408410 if (status != CAIRO_STATUS_SUCCESS)
409411 {
410412 g_warning ("Failed to save png of status icon");