4 moduledir = $(libdir)/weston
9 DISTCHECK_CONFIGURE_FLAGS = --disable-setuid-install
11 EXTRA_DIST = weston.ini.in wayland-scanner.mk
13 weston.ini : $(srcdir)/weston.ini.in
15 -e 's|@bindir[@]|$(bindir)|g' \
16 -e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
17 -e 's|@libexecdir[@]|$(libexecdir)|g' \
20 all-local : weston.ini validate-protocol-xml
22 AM_CFLAGS = $(GCC_CFLAGS)
26 -I$(top_builddir)/src \
27 -I$(top_builddir)/clients \
28 -I$(top_builddir)/tests \
29 -I$(top_srcdir)/shared \
30 -DDATADIR='"$(datadir)"' \
31 -DMODULEDIR='"$(moduledir)"' \
32 -DLIBEXECDIR='"$(libexecdir)"' \
33 -DBINDIR='"$(bindir)"'
35 CLEANFILES = weston.ini $(BUILT_SOURCES)
37 bin_PROGRAMS += weston
39 weston_LDFLAGS = -export-dynamic
40 weston_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON
41 weston_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS) $(LIBUNWIND_CFLAGS)
42 weston_LDADD = $(COMPOSITOR_LIBS) $(LIBUNWIND_LIBS) \
43 $(DLOPEN_LIBS) -lm libshared.la
55 src/screenshooter-protocol.c \
56 src/screenshooter-server-protocol.h \
58 src/text-cursor-position-protocol.c \
59 src/text-cursor-position-server-protocol.h \
63 src/text-server-protocol.h \
64 src/input-method-protocol.c \
65 src/input-method-server-protocol.h \
66 src/workspaces-protocol.c \
67 src/workspaces-server-protocol.h \
68 src/scaler-protocol.c \
69 src/scaler-server-protocol.h \
73 src/pixman-renderer.c \
74 src/pixman-renderer.h \
80 noinst_LTLIBRARIES += \
83 libsession_helper_la_SOURCES = \
87 libsession_helper_la_CFLAGS = $(GCC_CFLAGS) $(LIBDRM_CFLAGS) $(PIXMAN_CFLAGS) $(COMPOSITOR_CFLAGS)
88 libsession_helper_la_LIBADD = $(LIBDRM_LIBS)
92 libsession_helper_la_SOURCES += \
97 libsession_helper_la_CFLAGS += $(SYSTEMD_LOGIN_CFLAGS) $(DBUS_CFLAGS)
98 libsession_helper_la_LIBADD += $(SYSTEMD_LOGIN_LIBS) $(DBUS_LIBS)
102 src/git-version.h : .FORCE
103 $(AM_V_GEN)(echo "#define BUILD_ID \"$(shell git --git-dir=$(top_srcdir)/.git describe --always --dirty) $(shell git --git-dir=$(top_srcdir)/.git log -1 --format='%s (%ci)')\"" > $@-new; \
104 cmp -s $@ $@-new || cp $@-new $@; \
109 if BUILD_WESTON_LAUNCH
110 bin_PROGRAMS += weston-launch
111 weston_launch_SOURCES = src/weston-launch.c src/weston-launch.h
112 weston_launch_CPPFLAGS = -DBINDIR='"$(bindir)"'
113 weston_launch_CFLAGS= \
116 $(SYSTEMD_LOGIN_CFLAGS) \
118 weston_launch_LDADD = $(PAM_LIBS) $(SYSTEMD_LOGIN_LIBS) $(LIBDRM_LIBS)
120 if ENABLE_SETUID_INSTALL
122 chown root $(DESTDIR)$(bindir)/weston-launch
123 chmod u+s $(DESTDIR)$(bindir)/weston-launch
126 endif # BUILD_WESTON_LAUNCH
128 pkgconfigdir = $(libdir)/pkgconfig
129 pkgconfig_DATA = src/weston.pc
131 westonincludedir = $(includedir)/weston
132 westoninclude_HEADERS = \
136 shared/config-parser.h \
140 module_LTLIBRARIES += gl-renderer.la
141 gl_renderer_la_LDFLAGS = -module -avoid-version
142 gl_renderer_la_LIBADD = $(COMPOSITOR_LIBS) $(EGL_LIBS)
143 gl_renderer_la_CFLAGS = \
144 $(COMPOSITOR_CFLAGS) \
147 gl_renderer_la_SOURCES = \
150 src/vertex-clipping.c \
151 src/vertex-clipping.h
154 if ENABLE_X11_COMPOSITOR
155 module_LTLIBRARIES += x11-backend.la
156 x11_backend_la_LDFLAGS = -module -avoid-version
157 x11_backend_la_LIBADD = $(COMPOSITOR_LIBS) $(X11_COMPOSITOR_LIBS) \
159 x11_backend_la_CFLAGS = \
160 $(COMPOSITOR_CFLAGS) \
164 $(X11_COMPOSITOR_CFLAGS) \
166 x11_backend_la_SOURCES = src/compositor-x11.c
169 if ENABLE_DRM_COMPOSITOR
170 module_LTLIBRARIES += drm-backend.la
171 drm_backend_la_LDFLAGS = -module -avoid-version
172 drm_backend_la_LIBADD = \
174 $(DRM_COMPOSITOR_LIBS) \
177 drm_backend_la_CFLAGS = \
178 $(COMPOSITOR_CFLAGS) \
180 $(DRM_COMPOSITOR_CFLAGS) \
182 drm_backend_la_SOURCES = \
183 src/compositor-drm.c \
188 src/evdev-touchpad.c \
192 if ENABLE_VAAPI_RECORDER
193 drm_backend_la_SOURCES += src/vaapi-recorder.c src/vaapi-recorder.h
194 drm_backend_la_LIBADD += $(LIBVA_LIBS)
195 drm_backend_la_CFLAGS += $(LIBVA_CFLAGS)
199 if ENABLE_WAYLAND_COMPOSITOR
200 module_LTLIBRARIES += wayland-backend.la
201 wayland_backend_la_LDFLAGS = -module -avoid-version
202 wayland_backend_la_LIBADD = \
204 $(WAYLAND_COMPOSITOR_LIBS) \
206 wayland_backend_la_CFLAGS = \
207 $(COMPOSITOR_CFLAGS) \
211 $(WAYLAND_COMPOSITOR_CFLAGS) \
213 wayland_backend_la_SOURCES = src/compositor-wayland.c
216 if ENABLE_RPI_COMPOSITOR
217 if INSTALL_RPI_COMPOSITOR
218 module_LTLIBRARIES += rpi-backend.la
220 noinst_LTLIBRARIES += rpi-backend.la
223 rpi_backend_la_LDFLAGS = -module -avoid-version
224 rpi_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
225 $(RPI_COMPOSITOR_LIBS) \
226 $(RPI_BCM_HOST_LIBS) \
227 libsession-helper.la \
229 rpi_backend_la_CFLAGS = \
231 $(COMPOSITOR_CFLAGS) \
232 $(RPI_COMPOSITOR_CFLAGS) \
233 $(RPI_BCM_HOST_CFLAGS)
234 rpi_backend_la_SOURCES = \
235 src/compositor-rpi.c \
238 src/rpi-bcm-stubs.h \
246 rpi_backend_la_LIBADD += $(EGL_LIBS)
247 rpi_backend_la_CFLAGS += $(EGL_CFLAGS)
252 if ENABLE_HEADLESS_COMPOSITOR
253 module_LTLIBRARIES += headless-backend.la
254 headless_backend_la_LDFLAGS = -module -avoid-version
255 headless_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
257 headless_backend_la_CFLAGS = \
258 $(COMPOSITOR_CFLAGS) \
260 headless_backend_la_SOURCES = src/compositor-headless.c
263 if ENABLE_FBDEV_COMPOSITOR
264 module_LTLIBRARIES += fbdev-backend.la
265 fbdev_backend_la_LDFLAGS = -module -avoid-version
266 fbdev_backend_la_LIBADD = \
268 $(FBDEV_COMPOSITOR_LIBS) \
269 libsession-helper.la \
271 fbdev_backend_la_CFLAGS = \
272 $(COMPOSITOR_CFLAGS) \
274 $(FBDEV_COMPOSITOR_CFLAGS) \
277 fbdev_backend_la_SOURCES = \
278 src/compositor-fbdev.c \
286 if ENABLE_RDP_COMPOSITOR
287 module_LTLIBRARIES += rdp-backend.la
288 rdp_backend_la_LDFLAGS = -module -avoid-version
289 rdp_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
290 $(RDP_COMPOSITOR_LIBS) \
292 rdp_backend_la_CFLAGS = \
293 $(COMPOSITOR_CFLAGS) \
294 $(RDP_COMPOSITOR_CFLAGS) \
296 rdp_backend_la_SOURCES = src/compositor-rdp.c
300 module_LTLIBRARIES += cms-static.la
301 cms_static_la_LDFLAGS = -module -avoid-version
302 cms_static_la_LIBADD = $(COMPOSITOR_LIBS) $(LCMS_LIBS) libshared.la
303 cms_static_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS) $(LCMS_CFLAGS)
304 cms_static_la_SOURCES = \
309 module_LTLIBRARIES += cms-colord.la
310 cms_colord_la_LDFLAGS = -module -avoid-version
311 cms_colord_la_LIBADD = $(COMPOSITOR_LIBS) $(COLORD_LIBS)
312 cms_colord_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS) $(COLORD_CFLAGS)
313 cms_colord_la_SOURCES = \
320 noinst_PROGRAMS += spring-tool
321 spring_tool_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
322 spring_tool_LDADD = $(COMPOSITOR_LIBS) -lm
323 spring_tool_SOURCES = \
331 src/screenshooter-server-protocol.h \
332 src/screenshooter-protocol.c \
333 src/text-cursor-position-server-protocol.h \
334 src/text-cursor-position-protocol.c \
335 src/text-protocol.c \
336 src/text-server-protocol.h \
337 src/input-method-protocol.c \
338 src/input-method-server-protocol.h \
339 src/workspaces-server-protocol.h \
340 src/workspaces-protocol.c \
341 src/scaler-server-protocol.h \
342 src/scaler-protocol.c \
347 bin_PROGRAMS += weston-terminal weston-info
349 libexec_PROGRAMS += \
350 weston-desktop-shell \
351 weston-screenshooter \
370 if INSTALL_DEMO_CLIENTS
371 bin_PROGRAMS += $(demo_clients)
373 noinst_PROGRAMS += $(demo_clients)
377 if BUILD_SIMPLE_CLIENTS
380 weston-simple-touch \
381 weston-multi-resource
383 weston_simple_shm_SOURCES = \
384 clients/simple-shm.c \
385 shared/os-compatibility.c \
386 shared/os-compatibility.h
387 weston_simple_shm_CPPFLAGS = $(SIMPLE_CLIENT_CFLAGS)
388 weston_simple_shm_LDADD = $(SIMPLE_CLIENT_LIBS)
390 weston_simple_touch_SOURCES = \
391 clients/simple-touch.c \
392 shared/os-compatibility.c \
393 shared/os-compatibility.h
394 weston_simple_touch_CPPFLAGS = $(SIMPLE_CLIENT_CFLAGS)
395 weston_simple_touch_LDADD = $(SIMPLE_CLIENT_LIBS)
397 weston_multi_resource_SOURCES = \
398 clients/multi-resource.c \
399 shared/os-compatibility.c \
400 shared/os-compatibility.h
401 weston_multi_resource_CPPFLAGS = $(SIMPLE_CLIENT_CFLAGS)
402 weston_multi_resource_LDADD = $(SIMPLE_CLIENT_LIBS) -lm
405 if BUILD_SIMPLE_EGL_CLIENTS
406 demo_clients += weston-simple-egl
407 weston_simple_egl_SOURCES = clients/simple-egl.c
408 weston_simple_egl_CPPFLAGS = $(SIMPLE_EGL_CLIENT_CFLAGS)
409 weston_simple_egl_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
412 noinst_LTLIBRARIES += libtoytoolkit.la
414 libtoytoolkit_la_SOURCES = \
417 clients/text-cursor-position-protocol.c \
418 clients/text-cursor-position-client-protocol.h \
419 clients/scaler-protocol.c \
420 clients/scaler-client-protocol.h \
421 clients/workspaces-protocol.c \
422 clients/workspaces-client-protocol.h
424 libtoytoolkit_la_LIBADD = \
427 libshared-cairo.la -lrt -lm
428 libtoytoolkit_la_CFLAGS = $(CLIENT_CFLAGS) $(CAIRO_EGL_CFLAGS)
430 weston_flower_SOURCES = clients/flower.c
431 weston_flower_LDADD = libtoytoolkit.la
432 weston_flower_CFLAGS = $(CLIENT_CFLAGS)
434 weston_screenshooter_SOURCES = \
435 clients/screenshot.c \
436 clients/screenshooter-protocol.c \
437 clients/screenshooter-client-protocol.h \
438 shared/os-compatibility.c \
439 shared/os-compatibility.h
440 weston_screenshooter_LDADD = $(CLIENT_LIBS)
441 weston_screenshooter_CFLAGS = $(CLIENT_CFLAGS)
443 weston_terminal_SOURCES = clients/terminal.c
444 weston_terminal_LDADD = libtoytoolkit.la -lutil
445 weston_terminal_CFLAGS = $(CLIENT_CFLAGS)
447 weston_image_SOURCES = clients/image.c
448 weston_image_LDADD = libtoytoolkit.la
449 weston_image_CFLAGS = $(CLIENT_CFLAGS)
451 weston_cliptest_SOURCES = clients/cliptest.c
452 weston_cliptest_CFLAGS = $(AM_CPPFLAGS) $(CLIENT_CFLAGS)
453 weston_cliptest_LDADD = libtoytoolkit.la
455 weston_dnd_SOURCES = clients/dnd.c
456 weston_dnd_LDADD = libtoytoolkit.la
457 weston_dnd_CFLAGS = $(CLIENT_CFLAGS)
459 weston_smoke_SOURCES = clients/smoke.c
460 weston_smoke_LDADD = libtoytoolkit.la
461 weston_smoke_CFLAGS = $(CLIENT_CFLAGS)
463 weston_resizor_SOURCES = clients/resizor.c
464 weston_resizor_LDADD = libtoytoolkit.la
465 weston_resizor_CFLAGS = $(CLIENT_CFLAGS)
467 weston_scaler_SOURCES = clients/scaler.c
468 weston_scaler_LDADD = libtoytoolkit.la
469 weston_scaler_CFLAGS = $(CLIENT_CFLAGS)
472 demo_clients += weston-nested weston-nested-client
474 weston_nested_SOURCES = clients/nested.c
475 weston_nested_LDADD = libtoytoolkit.la $(SERVER_LIBS)
476 weston_nested_CFLAGS = $(CLIENT_CFLAGS)
478 weston_nested_client_SOURCES = clients/nested-client.c
479 weston_nested_client_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
482 weston_eventdemo_SOURCES = clients/eventdemo.c
483 weston_eventdemo_LDADD = libtoytoolkit.la
484 weston_eventdemo_CFLAGS = $(CLIENT_CFLAGS)
486 weston_clickdot_SOURCES = clients/clickdot.c
487 weston_clickdot_LDADD = libtoytoolkit.la
488 weston_clickdot_CFLAGS = $(CLIENT_CFLAGS)
490 weston_transformed_SOURCES = clients/transformed.c
491 weston_transformed_LDADD = libtoytoolkit.la
492 weston_transformed_CFLAGS = $(CLIENT_CFLAGS)
494 weston_fullscreen_SOURCES = clients/fullscreen.c
495 weston_fullscreen_LDADD = libtoytoolkit.la
496 weston_fullscreen_CFLAGS = $(CLIENT_CFLAGS)
498 weston_stacking_SOURCES = clients/stacking.c
499 weston_stacking_LDADD = libtoytoolkit.la
500 weston_stacking_CFLAGS = $(CLIENT_CFLAGS)
502 weston_calibrator_SOURCES = clients/calibrator.c \
505 weston_calibrator_LDADD = libtoytoolkit.la
506 weston_calibrator_CFLAGS = $(CLIENT_CFLAGS)
508 if BUILD_SUBSURFACES_CLIENT
509 demo_clients += weston-subsurfaces
510 weston_subsurfaces_SOURCES = clients/subsurfaces.c
511 weston_subsurfaces_CFLAGS = $(SIMPLE_EGL_CLIENT_CFLAGS) $(CLIENT_CFLAGS)
512 weston_subsurfaces_LDADD = libtoytoolkit.la $(SIMPLE_EGL_CLIENT_LIBS) -lm
516 demo_clients += weston-editor
517 weston_editor_SOURCES = \
519 clients/text-protocol.c \
520 clients/text-client-protocol.h
521 weston_editor_LDADD = libtoytoolkit.la $(PANGO_LIBS)
522 weston_editor_CFLAGS = $(CLIENT_CFLAGS) $(PANGO_CFLAGS)
525 weston_keyboard_SOURCES = \
527 clients/desktop-shell-client-protocol.h \
528 clients/desktop-shell-protocol.c \
529 clients/input-method-protocol.c \
530 clients/input-method-client-protocol.h
531 weston_keyboard_LDADD = libtoytoolkit.la
532 weston_keyboard_CFLAGS = $(CLIENT_CFLAGS)
534 weston_simple_im_SOURCES = \
535 clients/weston-simple-im.c \
536 clients/input-method-protocol.c \
537 clients/input-method-client-protocol.h
538 weston_simple_im_LDADD = $(CLIENT_LIBS)
539 weston_simple_im_CFLAGS = $(CLIENT_CFLAGS)
541 weston_info_SOURCES = \
542 clients/weston-info.c \
543 shared/os-compatibility.c \
544 shared/os-compatibility.h
545 weston_info_LDADD = $(WESTON_INFO_LIBS)
547 weston_desktop_shell_SOURCES = \
548 clients/desktop-shell.c \
549 clients/desktop-shell-client-protocol.h \
550 clients/desktop-shell-protocol.c
551 weston_desktop_shell_LDADD = libtoytoolkit.la
552 weston_desktop_shell_CFLAGS = $(CLIENT_CFLAGS)
554 if BUILD_FULL_GL_CLIENTS
555 demo_clients += weston-gears
556 weston_gears_SOURCES = clients/gears.c
557 weston_gears_LDADD = libtoytoolkit.la
558 weston_gears_CFLAGS = $(CLIENT_CFLAGS)
561 libexec_PROGRAMS += weston-screensaver
562 weston_screensaver_SOURCES = \
563 clients/wscreensaver.c \
564 clients/wscreensaver.h \
565 clients/desktop-shell-client-protocol.h \
566 clients/desktop-shell-protocol.c \
567 clients/wscreensaver-glue.c \
568 clients/wscreensaver-glue.h \
571 weston_screensaver_LDADD = libtoytoolkit.la $(GLU_LIBS)
572 weston_screensaver_CFLAGS = $(GLU_CFLAGS) $(CLIENT_CFLAGS)
581 clients/screenshooter-client-protocol.h \
582 clients/screenshooter-protocol.c \
583 clients/text-cursor-position-client-protocol.h \
584 clients/text-cursor-position-protocol.c \
585 clients/text-protocol.c \
586 clients/text-client-protocol.h \
587 clients/input-method-protocol.c \
588 clients/input-method-client-protocol.h \
589 clients/desktop-shell-client-protocol.h \
590 clients/desktop-shell-protocol.c \
591 clients/scaler-client-protocol.h \
592 clients/scaler-protocol.c \
593 clients/workspaces-client-protocol.h \
594 clients/workspaces-protocol.c
597 westondatadir = $(datadir)/weston
598 dist_westondata_DATA = \
604 data/icon_window.png \
605 data/sign_close.png \
606 data/sign_maximize.png \
607 data/sign_minimize.png
611 bin_PROGRAMS += wcap-decode
613 wcap_decode_SOURCES = \
618 wcap_decode_CFLAGS = $(GCC_CFLAGS) $(WCAP_CFLAGS)
619 wcap_decode_LDADD = $(WCAP_LIBS)
623 if ENABLE_DESKTOP_SHELL
625 module_LTLIBRARIES += desktop-shell.la
627 desktop_shell_la_CPPFLAGS = \
628 -I$(top_srcdir)/shared \
629 -I$(top_srcdir)/src \
630 -I$(top_builddir)/src \
631 -I$(top_builddir)/desktop-shell \
632 -DDATADIR='"$(datadir)"' \
633 -DMODULEDIR='"$(moduledir)"' \
634 -DLIBEXECDIR='"$(libexecdir)"' \
637 desktop_shell_la_LDFLAGS = -module -avoid-version
638 desktop_shell_la_LIBADD = $(COMPOSITOR_LIBS) \
640 desktop_shell_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
641 desktop_shell_la_SOURCES = \
642 desktop-shell/shell.h \
643 desktop-shell/shell.c \
644 desktop-shell/exposay.c \
645 desktop-shell/input-panel.c \
646 desktop-shell/desktop-shell-protocol.c \
647 desktop-shell/desktop-shell-server-protocol.h \
648 desktop-shell/xdg-shell-protocol.c \
649 desktop-shell/xdg-shell-server-protocol.h
652 desktop-shell/desktop-shell-protocol.c \
653 desktop-shell/desktop-shell-server-protocol.h \
654 desktop-shell/xdg-shell-protocol.c \
655 desktop-shell/xdg-shell-server-protocol.h
661 module_LTLIBRARIES += xwayland.la
663 xwayland_la_CPPFLAGS = \
664 -I$(top_srcdir)/shared \
665 -I$(top_srcdir)/src \
666 -I$(top_builddir)/src \
667 -I$(top_builddir)/xwayland \
668 -DDATADIR='"$(datadir)"' \
669 -DMODULEDIR='"$(moduledir)"' \
670 -DLIBEXECDIR='"$(libexecdir)"' \
671 -DXSERVER_PATH='"@XSERVER_PATH@"'
673 xwayland_la_LDFLAGS = -module -avoid-version
674 xwayland_la_LIBADD = \
676 $(top_builddir)/libshared-cairo.la
677 xwayland_la_CFLAGS = \
679 $(COMPOSITOR_CFLAGS) \
682 xwayland_la_SOURCES = \
683 xwayland/xwayland.h \
684 xwayland/window-manager.c \
685 xwayland/selection.c \
687 xwayland/launcher.c \
688 xwayland/xserver-protocol.c \
689 xwayland/xserver-server-protocol.h \
694 xwayland/xserver-protocol.c \
695 xwayland/xserver-server-protocol.h
703 noinst_LTLIBRARIES += libshared.la libshared-cairo.la
705 libshared_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
707 libshared_la_SOURCES = \
708 shared/config-parser.c \
709 shared/option-parser.c \
710 shared/config-parser.h \
711 shared/os-compatibility.c \
712 shared/os-compatibility.h
714 libshared_cairo_la_CFLAGS = \
715 -DDATADIR='"$(datadir)"' \
717 $(COMPOSITOR_CFLAGS) \
723 libshared_cairo_la_LIBADD = \
730 libshared_cairo_la_SOURCES = \
731 $(libshared_la_SOURCES) \
732 shared/image-loader.c \
733 shared/image-loader.h \
734 shared/cairo-util.c \
743 TESTS = $(shared_tests) $(module_tests) $(weston_tests)
751 surface-global-test.la
762 AM_TESTS_ENVIRONMENT = \
763 abs_builddir='$(abs_builddir)'; export abs_builddir;
765 TEST_EXTENSIONS = .la .weston
766 LA_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
767 WESTON_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
772 # To remove when automake 1.11 support is dropped
775 noinst_LTLIBRARIES += \
787 test_module_ldflags = \
788 -module -avoid-version -rpath $(libdir) $(COMPOSITOR_LIBS)
790 surface_global_test_la_SOURCES = tests/surface-global-test.c
791 surface_global_test_la_LDFLAGS = $(test_module_ldflags)
792 surface_global_test_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
794 surface_test_la_SOURCES = tests/surface-test.c
795 surface_test_la_LDFLAGS = $(test_module_ldflags)
796 surface_test_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
798 weston_test_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
799 weston_test_la_LDFLAGS = $(test_module_ldflags)
800 weston_test_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
801 weston_test_la_SOURCES = \
802 tests/weston-test.c \
803 tests/wayland-test-protocol.c \
804 tests/wayland-test-server-protocol.h
807 weston_test_la_CFLAGS += $(EGL_TESTS_CFLAGS)
808 weston_test_la_LDFLAGS += $(EGL_TESTS_LIBS)
811 libtest_runner_la_SOURCES = \
812 tests/weston-test-runner.c \
813 tests/weston-test-runner.h
814 libtest_runner_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
816 config_parser_test_SOURCES = tests/config-parser-test.c
817 config_parser_test_LDADD = libshared.la libtest-runner.la $(COMPOSITOR_LIBS)
819 vertex_clip_test_SOURCES = \
820 tests/vertex-clip-test.c \
821 src/vertex-clipping.c \
822 src/vertex-clipping.h
823 vertex_clip_test_LDADD = libtest-runner.la -lm -lrt
825 libtest_client_la_SOURCES = \
826 tests/weston-test-client-helper.c \
827 tests/weston-test-client-helper.h \
828 tests/wayland-test-protocol.c \
829 tests/wayland-test-client-protocol.h
830 libtest_client_la_LIBADD = $(TEST_CLIENT_LIBS) libshared.la libtest-runner.la
832 bad_buffer_weston_SOURCES = tests/bad-buffer-test.c
833 bad_buffer_weston_LDADD = libtest-client.la
835 keyboard_weston_SOURCES = tests/keyboard-test.c
836 keyboard_weston_LDADD = libtest-client.la
838 event_weston_SOURCES = tests/event-test.c
839 event_weston_LDADD = libtest-client.la
841 button_weston_SOURCES = tests/button-test.c
842 button_weston_LDADD = libtest-client.la
844 text_weston_SOURCES = tests/text-test.c tests/text-protocol.c
845 text_weston_LDADD = libtest-client.la
847 subsurface_weston_SOURCES = tests/subsurface-test.c
848 subsurface_weston_LDADD = libtest-client.la
851 weston_tests += buffer-count.weston
852 buffer_count_weston_SOURCES = tests/buffer-count-test.c
853 buffer_count_weston_CFLAGS = $(GCC_CFLAGS) $(EGL_TESTS_CFLAGS)
854 buffer_count_weston_LDADD = libtest-client.la $(EGL_TESTS_LIBS)
857 if ENABLE_XWAYLAND_TEST
858 weston_tests += xwayland.weston
859 xwayland_weston_SOURCES = tests/xwayland-test.c
860 xwayland_weston_CFLAGS = $(GCC_CFLAGS) $(XWAYLAND_TEST_CFLAGS)
861 xwayland_weston_LDADD = libtest-client.la $(XWAYLAND_TEST_LIBS)
864 matrix_test_SOURCES = \
865 tests/matrix-test.c \
868 matrix_test_CPPFLAGS = -DUNIT_TEST
869 matrix_test_LDADD = -lm -lrt
871 if BUILD_SETBACKLIGHT
872 noinst_PROGRAMS += setbacklight
873 setbacklight_SOURCES = \
874 tests/setbacklight.c \
877 setbacklight_CFLAGS = $(AM_CFLAGS) $(SETBACKLIGHT_CFLAGS)
878 setbacklight_LDADD = $(SETBACKLIGHT_LIBS)
881 EXTRA_DIST += tests/weston-tests-env
884 tests/wayland-test-protocol.c \
885 tests/wayland-test-server-protocol.h \
886 tests/wayland-test-client-protocol.h \
887 tests/text-protocol.c \
888 tests/text-client-protocol.h
891 protocol/desktop-shell.xml \
892 protocol/screenshooter.xml \
893 protocol/xserver.xml \
895 protocol/input-method.xml \
896 protocol/workspaces.xml \
897 protocol/text-cursor-position.xml \
898 protocol/wayland-test.xml \
899 protocol/xdg-shell.xml \
903 .PHONY : validate-protocol-xml
905 .%.xml.valid : $(top_srcdir)/protocol/%.xml
906 $(AM_V_GEN)$(XMLLINT) --noout --dtdvalid $(dtddir)/wayland.dtd $^ > $@
908 validate-protocol-xml : $(protocol_sources:protocol/%.xml=.%.xml.valid)
910 CLEANFILES += $(protocol_sources:protocol/%.xml=.%.xml.valid)
911 EXTRA_DIST += $(protocol_sources)
916 man_MANS = weston.1 weston.ini.5
918 if ENABLE_DRM_COMPOSITOR
919 man_MANS += weston-drm.7
923 -e 's|__weston_native_backend__|$(WESTON_NATIVE_BACKEND)|g' \
924 -e 's|__weston_modules_dir__|$(pkglibdir)|g' \
925 -e 's|__weston_shell_client__|$(WESTON_SHELL_CLIENT)|g' \
926 -e 's|__version__|$(PACKAGE_VERSION)|g'
928 SUFFIXES = .1 .5 .7 .man
930 %.1 %.5 %.7 : man/%.man
931 $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
938 CLEANFILES += $(man_MANS)
941 wayland_protocoldir = $(top_srcdir)/protocol
942 include $(top_srcdir)/wayland-scanner.mk