blob: 1feb1a82b805839d3760e2b03afff508adef3477 [file] [log] [blame]
Kristian Høgsberge895f142014-01-27 21:46:30 -08001bin_PROGRAMS =
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -08002noinst_PROGRAMS =
Kristian Høgsberge73eccd2014-01-31 16:15:11 -08003libexec_PROGRAMS =
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -08004moduledir = $(libdir)/weston
5module_LTLIBRARIES =
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -08006noinst_LTLIBRARIES =
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -08007BUILT_SOURCES =
Kristian Høgsberge895f142014-01-27 21:46:30 -08008
Kristian Høgsberg850f24c2012-02-09 09:20:44 -05009DISTCHECK_CONFIGURE_FLAGS = --disable-setuid-install
Kristian Høgsberg24639cc2013-02-25 13:03:15 -050010
Kristian Høgsberg08229422014-02-01 00:33:04 -080011EXTRA_DIST = weston.ini.in
Neil Robertse3de16e2013-11-22 16:46:00 +000012
13weston.ini : $(srcdir)/weston.ini.in
14 $(AM_V_GEN)$(SED) \
15 -e 's|@bindir[@]|$(bindir)|g' \
16 -e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
17 -e 's|@libexecdir[@]|$(libexecdir)|g' \
18 $< > $@
19
Kristian Høgsbergcd312752014-02-01 00:38:15 -080020all-local : weston.ini
Kristian Høgsberg98463742013-12-16 23:12:46 -080021
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080022AM_CFLAGS = $(GCC_CFLAGS)
23
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080024AM_CPPFLAGS = \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080025 -I$(top_srcdir)/src \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080026 -I$(top_builddir)/src \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -080027 -I$(top_builddir)/clients \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080028 -I$(top_builddir)/tests \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080029 -I$(top_srcdir)/shared \
Quentin Glidic088ba5e2014-02-01 21:39:12 +010030 -I$(top_builddir)/protocol \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080031 -DDATADIR='"$(datadir)"' \
32 -DMODULEDIR='"$(moduledir)"' \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -080033 -DLIBEXECDIR='"$(libexecdir)"' \
34 -DBINDIR='"$(bindir)"'
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080035
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -080036CLEANFILES = weston.ini $(BUILT_SOURCES)
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -080037
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080038bin_PROGRAMS += weston
39
40weston_LDFLAGS = -export-dynamic
41weston_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON
42weston_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS) $(LIBUNWIND_CFLAGS)
43weston_LDADD = $(COMPOSITOR_LIBS) $(LIBUNWIND_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -080044 $(DLOPEN_LIBS) -lm libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080045
46weston_SOURCES = \
47 src/git-version.h \
48 src/log.c \
49 src/compositor.c \
50 src/compositor.h \
51 src/input.c \
52 src/data-device.c \
53 src/filter.c \
54 src/filter.h \
55 src/screenshooter.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080056 src/clipboard.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080057 src/zoom.c \
58 src/text-backend.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080059 src/bindings.c \
60 src/animation.c \
61 src/noop-renderer.c \
62 src/pixman-renderer.c \
63 src/pixman-renderer.h \
64 shared/matrix.c \
65 shared/matrix.h \
66 shared/zalloc.h \
67 src/weston-egl-ext.h
68
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -080069nodist_weston_SOURCES = \
70 protocol/screenshooter-protocol.c \
71 protocol/screenshooter-server-protocol.h \
72 protocol/text-cursor-position-protocol.c \
73 protocol/text-cursor-position-server-protocol.h \
74 protocol/text-protocol.c \
75 protocol/text-server-protocol.h \
76 protocol/input-method-protocol.c \
77 protocol/input-method-server-protocol.h \
78 protocol/workspaces-protocol.c \
79 protocol/workspaces-server-protocol.h \
80 protocol/scaler-protocol.c \
81 protocol/scaler-server-protocol.h
82
83BUILT_SOURCES += $(nodist_weston_SOURCES)
84
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -080085# Track this dependency explicitly instead of using BUILT_SOURCES. We
86# add BUILT_SOURCES to CLEANFILES, but we want to keep git-version.h
87# in case we're building from tarballs.
88
89src/compositor.c : $(top_builddir)/src/git-version.h
90
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080091noinst_LTLIBRARIES += \
92 libsession-helper.la
93
94libsession_helper_la_SOURCES = \
95 src/weston-launch.h \
96 src/launcher-util.c \
97 src/launcher-util.h
98libsession_helper_la_CFLAGS = $(GCC_CFLAGS) $(LIBDRM_CFLAGS) $(PIXMAN_CFLAGS) $(COMPOSITOR_CFLAGS)
99libsession_helper_la_LIBADD = $(LIBDRM_LIBS)
100
101if ENABLE_DBUS
102if HAVE_SYSTEMD_LOGIN
103libsession_helper_la_SOURCES += \
104 src/dbus.h \
105 src/dbus.c \
106 src/logind-util.h \
107 src/logind-util.c
108libsession_helper_la_CFLAGS += $(SYSTEMD_LOGIN_CFLAGS) $(DBUS_CFLAGS)
109libsession_helper_la_LIBADD += $(SYSTEMD_LOGIN_LIBS) $(DBUS_LIBS)
110endif
111endif
112
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800113if HAVE_GIT_REPO
114src/git-version.h : $(top_srcdir)/.git/logs/HEAD
115 $(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)')\"" > $@
Kristian Høgsberg1d2dd072014-02-03 10:55:51 -0800116else
117src/git-version.h :
118 $(AM_V_GEN)echo "#define BUILD_ID \"unknown (not built from git or tarball)\"" > $@
119
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800120endif
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800121
122.FORCE :
123
124if BUILD_WESTON_LAUNCH
125bin_PROGRAMS += weston-launch
126weston_launch_SOURCES = src/weston-launch.c src/weston-launch.h
127weston_launch_CPPFLAGS = -DBINDIR='"$(bindir)"'
128weston_launch_CFLAGS= \
129 $(GCC_CFLAGS) \
130 $(PAM_CFLAGS) \
131 $(SYSTEMD_LOGIN_CFLAGS) \
132 $(LIBDRM_CFLAGS)
133weston_launch_LDADD = $(PAM_LIBS) $(SYSTEMD_LOGIN_LIBS) $(LIBDRM_LIBS)
134
135if ENABLE_SETUID_INSTALL
136install-exec-hook:
137 chown root $(DESTDIR)$(bindir)/weston-launch
138 chmod u+s $(DESTDIR)$(bindir)/weston-launch
139endif
140
141endif # BUILD_WESTON_LAUNCH
142
143pkgconfigdir = $(libdir)/pkgconfig
144pkgconfig_DATA = src/weston.pc
145
146westonincludedir = $(includedir)/weston
147westoninclude_HEADERS = \
148 src/version.h \
149 src/compositor.h \
150 shared/matrix.h \
151 shared/config-parser.h \
152 shared/zalloc.h
153
154if ENABLE_EGL
155module_LTLIBRARIES += gl-renderer.la
156gl_renderer_la_LDFLAGS = -module -avoid-version
157gl_renderer_la_LIBADD = $(COMPOSITOR_LIBS) $(EGL_LIBS)
158gl_renderer_la_CFLAGS = \
159 $(COMPOSITOR_CFLAGS) \
160 $(EGL_CFLAGS) \
161 $(GCC_CFLAGS)
162gl_renderer_la_SOURCES = \
163 src/gl-renderer.h \
164 src/gl-renderer.c \
165 src/vertex-clipping.c \
166 src/vertex-clipping.h
167endif
168
169if ENABLE_X11_COMPOSITOR
170module_LTLIBRARIES += x11-backend.la
171x11_backend_la_LDFLAGS = -module -avoid-version
172x11_backend_la_LIBADD = $(COMPOSITOR_LIBS) $(X11_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800173 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800174x11_backend_la_CFLAGS = \
175 $(COMPOSITOR_CFLAGS) \
176 $(EGL_CFLAGS) \
177 $(PIXMAN_CFLAGS) \
178 $(CAIRO_CFLAGS) \
179 $(X11_COMPOSITOR_CFLAGS) \
180 $(GCC_CFLAGS)
181x11_backend_la_SOURCES = src/compositor-x11.c
182endif
183
184if ENABLE_DRM_COMPOSITOR
185module_LTLIBRARIES += drm-backend.la
186drm_backend_la_LDFLAGS = -module -avoid-version
187drm_backend_la_LIBADD = \
188 $(COMPOSITOR_LIBS) \
189 $(DRM_COMPOSITOR_LIBS) \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100190 libshared.la -lrt \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800191 libsession-helper.la
192drm_backend_la_CFLAGS = \
193 $(COMPOSITOR_CFLAGS) \
194 $(EGL_CFLAGS) \
195 $(DRM_COMPOSITOR_CFLAGS) \
196 $(GCC_CFLAGS)
197drm_backend_la_SOURCES = \
198 src/compositor-drm.c \
199 src/udev-seat.c \
200 src/udev-seat.h \
201 src/evdev.c \
202 src/evdev.h \
203 src/evdev-touchpad.c \
204 src/libbacklight.c \
205 src/libbacklight.h
206
207if ENABLE_VAAPI_RECORDER
208drm_backend_la_SOURCES += src/vaapi-recorder.c src/vaapi-recorder.h
209drm_backend_la_LIBADD += $(LIBVA_LIBS)
210drm_backend_la_CFLAGS += $(LIBVA_CFLAGS)
211endif
212endif
213
214if ENABLE_WAYLAND_COMPOSITOR
215module_LTLIBRARIES += wayland-backend.la
216wayland_backend_la_LDFLAGS = -module -avoid-version
217wayland_backend_la_LIBADD = \
218 $(COMPOSITOR_LIBS) \
219 $(WAYLAND_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800220 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800221wayland_backend_la_CFLAGS = \
222 $(COMPOSITOR_CFLAGS) \
223 $(EGL_CFLAGS) \
224 $(PIXMAN_CFLAGS) \
225 $(CAIRO_CFLAGS) \
226 $(WAYLAND_COMPOSITOR_CFLAGS) \
227 $(GCC_CFLAGS)
228wayland_backend_la_SOURCES = src/compositor-wayland.c
229endif
230
231if ENABLE_RPI_COMPOSITOR
232if INSTALL_RPI_COMPOSITOR
233module_LTLIBRARIES += rpi-backend.la
234else
235noinst_LTLIBRARIES += rpi-backend.la
236endif
237
238rpi_backend_la_LDFLAGS = -module -avoid-version
239rpi_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
240 $(RPI_COMPOSITOR_LIBS) \
241 $(RPI_BCM_HOST_LIBS) \
242 libsession-helper.la \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800243 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800244rpi_backend_la_CFLAGS = \
245 $(GCC_CFLAGS) \
246 $(COMPOSITOR_CFLAGS) \
247 $(RPI_COMPOSITOR_CFLAGS) \
248 $(RPI_BCM_HOST_CFLAGS)
249rpi_backend_la_SOURCES = \
250 src/compositor-rpi.c \
251 src/rpi-renderer.c \
252 src/rpi-renderer.h \
253 src/rpi-bcm-stubs.h \
254 src/udev-seat.c \
255 src/udev-seat.h \
256 src/evdev.c \
257 src/evdev.h \
258 src/evdev-touchpad.c
259
260if ENABLE_EGL
261rpi_backend_la_LIBADD += $(EGL_LIBS)
262rpi_backend_la_CFLAGS += $(EGL_CFLAGS)
263endif
264
265endif
266
267if ENABLE_HEADLESS_COMPOSITOR
268module_LTLIBRARIES += headless-backend.la
269headless_backend_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800270headless_backend_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
271headless_backend_la_CFLAGS = $(COMPOSITOR_CFLAGS) $(GCC_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800272headless_backend_la_SOURCES = src/compositor-headless.c
273endif
274
275if ENABLE_FBDEV_COMPOSITOR
276module_LTLIBRARIES += fbdev-backend.la
277fbdev_backend_la_LDFLAGS = -module -avoid-version
278fbdev_backend_la_LIBADD = \
279 $(COMPOSITOR_LIBS) \
280 $(FBDEV_COMPOSITOR_LIBS) \
281 libsession-helper.la \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800282 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800283fbdev_backend_la_CFLAGS = \
284 $(COMPOSITOR_CFLAGS) \
285 $(EGL_CFLAGS) \
286 $(FBDEV_COMPOSITOR_CFLAGS) \
287 $(PIXMAN_CFLAGS) \
288 $(GCC_CFLAGS)
289fbdev_backend_la_SOURCES = \
290 src/compositor-fbdev.c \
291 src/udev-seat.c \
292 src/udev-seat.h \
293 src/evdev.c \
294 src/evdev.h \
295 src/evdev-touchpad.c
296endif
297
298if ENABLE_RDP_COMPOSITOR
299module_LTLIBRARIES += rdp-backend.la
300rdp_backend_la_LDFLAGS = -module -avoid-version
301rdp_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
302 $(RDP_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800303 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800304rdp_backend_la_CFLAGS = \
305 $(COMPOSITOR_CFLAGS) \
306 $(RDP_COMPOSITOR_CFLAGS) \
307 $(GCC_CFLAGS)
308rdp_backend_la_SOURCES = src/compositor-rdp.c
309endif
310
311if HAVE_LCMS
312module_LTLIBRARIES += cms-static.la
313cms_static_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800314cms_static_la_LIBADD = $(COMPOSITOR_LIBS) $(LCMS_LIBS) libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800315cms_static_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS) $(LCMS_CFLAGS)
316cms_static_la_SOURCES = \
317 src/cms-static.c \
318 src/cms-helper.c \
319 src/cms-helper.h
320if ENABLE_COLORD
321module_LTLIBRARIES += cms-colord.la
322cms_colord_la_LDFLAGS = -module -avoid-version
323cms_colord_la_LIBADD = $(COMPOSITOR_LIBS) $(COLORD_LIBS)
324cms_colord_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS) $(COLORD_CFLAGS)
325cms_colord_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100326 src/cms-colord.c \
327 src/cms-helper.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800328 src/cms-helper.h
329endif
330endif
331
332noinst_PROGRAMS += spring-tool
333spring_tool_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
334spring_tool_LDADD = $(COMPOSITOR_LIBS) -lm
335spring_tool_SOURCES = \
336 src/spring-tool.c \
337 src/animation.c \
338 shared/matrix.c \
339 shared/matrix.h \
340 src/compositor.h
341
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800342if BUILD_CLIENTS
343
344bin_PROGRAMS += weston-terminal weston-info
345
346libexec_PROGRAMS += \
347 weston-desktop-shell \
348 weston-screenshooter \
349 weston-keyboard \
350 weston-simple-im
351
352demo_clients = \
353 weston-flower \
354 weston-image \
355 weston-cliptest \
356 weston-dnd \
357 weston-smoke \
358 weston-resizor \
359 weston-eventdemo \
360 weston-clickdot \
361 weston-transformed \
362 weston-fullscreen \
363 weston-stacking \
364 weston-calibrator \
365 weston-scaler
366
367if INSTALL_DEMO_CLIENTS
368bin_PROGRAMS += $(demo_clients)
369else
370noinst_PROGRAMS += $(demo_clients)
371endif
372
373
374if BUILD_SIMPLE_CLIENTS
375demo_clients += \
376 weston-simple-shm \
377 weston-simple-touch \
378 weston-multi-resource
379
380weston_simple_shm_SOURCES = \
381 clients/simple-shm.c \
Kristian Høgsbergdfaf65b2014-02-07 17:01:57 -0800382 protocol/xdg-shell-protocol.c \
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800383 protocol/xdg-shell-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800384weston_simple_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800385weston_simple_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800386
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800387weston_simple_touch_SOURCES = clients/simple-touch.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800388weston_simple_touch_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800389weston_simple_touch_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800390
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800391weston_multi_resource_SOURCES = clients/multi-resource.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800392weston_multi_resource_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800393weston_multi_resource_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la -lm
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800394endif
395
396if BUILD_SIMPLE_EGL_CLIENTS
397demo_clients += weston-simple-egl
Kristian Høgsbergdfaf65b2014-02-07 17:01:57 -0800398weston_simple_egl_SOURCES = \
399 clients/simple-egl.c \
400 protocol/xdg-shell-protocol.c \
401 protocol/xdg-shell-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800402weston_simple_egl_CFLAGS = $(AM_CFLAGS) $(SIMPLE_EGL_CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800403weston_simple_egl_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
404endif
405
406noinst_LTLIBRARIES += libtoytoolkit.la
407
408libtoytoolkit_la_SOURCES = \
409 clients/window.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800410 clients/window.h
411
412nodist_libtoytoolkit_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100413 protocol/text-cursor-position-protocol.c \
414 protocol/text-cursor-position-client-protocol.h \
415 protocol/scaler-protocol.c \
416 protocol/scaler-client-protocol.h \
417 protocol/workspaces-protocol.c \
418 protocol/workspaces-client-protocol.h \
419 protocol/xdg-shell-protocol.c \
420 protocol/xdg-shell-client-protocol.h
Jasper St. Pierre0790e392013-12-09 14:58:00 -0500421
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800422BUILT_SOURCES += $(nodist_libtoytoolkit_la_SOURCES)
423
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800424
425libtoytoolkit_la_LIBADD = \
426 $(CLIENT_LIBS) \
427 $(CAIRO_EGL_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800428 libshared-cairo.la -lrt -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800429libtoytoolkit_la_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(CAIRO_EGL_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800430
431weston_flower_SOURCES = clients/flower.c
432weston_flower_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800433weston_flower_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800434
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100435weston_screenshooter_SOURCES = \
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800436 clients/screenshot.c
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800437nodist_weston_screenshooter_SOURCES = \
438 protocol/screenshooter-protocol.c \
439 protocol/screenshooter-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800440weston_screenshooter_LDADD = $(CLIENT_LIBS) libshared.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800441weston_screenshooter_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800442
443weston_terminal_SOURCES = clients/terminal.c
444weston_terminal_LDADD = libtoytoolkit.la -lutil
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800445weston_terminal_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800446
447weston_image_SOURCES = clients/image.c
448weston_image_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800449weston_image_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800450
451weston_cliptest_SOURCES = clients/cliptest.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800452weston_cliptest_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800453weston_cliptest_LDADD = libtoytoolkit.la
454
455weston_dnd_SOURCES = clients/dnd.c
456weston_dnd_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800457weston_dnd_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800458
459weston_smoke_SOURCES = clients/smoke.c
460weston_smoke_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800461weston_smoke_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800462
463weston_resizor_SOURCES = clients/resizor.c
464weston_resizor_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800465weston_resizor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800466
467weston_scaler_SOURCES = clients/scaler.c
468weston_scaler_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800469weston_scaler_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800470
471if HAVE_CAIRO_GLESV2
472demo_clients += weston-nested weston-nested-client
473
474weston_nested_SOURCES = clients/nested.c
475weston_nested_LDADD = libtoytoolkit.la $(SERVER_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800476weston_nested_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800477
478weston_nested_client_SOURCES = clients/nested-client.c
479weston_nested_client_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800480weston_nested_client_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800481endif
482
483weston_eventdemo_SOURCES = clients/eventdemo.c
484weston_eventdemo_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800485weston_eventdemo_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800486
487weston_clickdot_SOURCES = clients/clickdot.c
488weston_clickdot_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800489weston_clickdot_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800490
491weston_transformed_SOURCES = clients/transformed.c
492weston_transformed_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800493weston_transformed_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800494
495weston_fullscreen_SOURCES = clients/fullscreen.c
496weston_fullscreen_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800497weston_fullscreen_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800498
499weston_stacking_SOURCES = clients/stacking.c
500weston_stacking_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800501weston_stacking_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800502
503weston_calibrator_SOURCES = clients/calibrator.c \
504 shared/matrix.c \
505 shared/matrix.h
506weston_calibrator_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800507weston_calibrator_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800508
509if BUILD_SUBSURFACES_CLIENT
510demo_clients += weston-subsurfaces
511weston_subsurfaces_SOURCES = clients/subsurfaces.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800512weston_subsurfaces_CFLAGS = \
513 $(AM_CFLAGS) \
514 $(SIMPLE_EGL_CLIENT_CFLAGS) \
515 $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800516weston_subsurfaces_LDADD = libtoytoolkit.la $(SIMPLE_EGL_CLIENT_LIBS) -lm
517endif
518
519if HAVE_PANGO
520demo_clients += weston-editor
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800521weston_editor_SOURCES = clients/editor.c
522nodist_weston_editor_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100523 protocol/text-protocol.c \
524 protocol/text-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800525weston_editor_LDADD = libtoytoolkit.la $(PANGO_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800526weston_editor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(PANGO_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800527endif
528
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800529weston_keyboard_SOURCES = clients/keyboard.c
530nodist_weston_keyboard_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100531 protocol/desktop-shell-client-protocol.h \
532 protocol/desktop-shell-protocol.c \
533 protocol/input-method-protocol.c \
534 protocol/input-method-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800535weston_keyboard_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800536weston_keyboard_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800537
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800538weston_simple_im_SOURCES = clients/weston-simple-im.c
539nodist_weston_simple_im_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100540 protocol/input-method-protocol.c \
541 protocol/input-method-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800542weston_simple_im_LDADD = $(CLIENT_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800543weston_simple_im_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800544
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800545weston_info_SOURCES = clients/weston-info.c
546weston_info_LDADD = $(WESTON_INFO_LIBS) libshared.la
Pekka Paalanen5124b532014-02-03 13:12:34 +0200547weston_info_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800548
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800549weston_desktop_shell_SOURCES = clients/desktop-shell.c
550nodist_weston_desktop_shell_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100551 protocol/desktop-shell-client-protocol.h \
552 protocol/desktop-shell-protocol.c
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800553weston_desktop_shell_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800554weston_desktop_shell_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800555
556if BUILD_FULL_GL_CLIENTS
557demo_clients += weston-gears
558weston_gears_SOURCES = clients/gears.c
559weston_gears_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800560weston_gears_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800561
562if HAVE_GLU
563libexec_PROGRAMS += weston-screensaver
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100564weston_screensaver_SOURCES = \
565 clients/wscreensaver.c \
566 clients/wscreensaver.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100567 clients/wscreensaver-glue.c \
568 clients/wscreensaver-glue.h \
569 clients/glmatrix.c \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800570 clients/matrix3.xpm
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800571nodist_weston_screensaver_SOURCES = \
572 protocol/desktop-shell-client-protocol.h \
573 protocol/desktop-shell-protocol.c
574
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800575weston_screensaver_LDADD = libtoytoolkit.la $(GLU_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800576weston_screensaver_CFLAGS = $(AM_CFLAGS) $(GLU_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800577
578endif
579
580endif
581
582endif
583
584BUILT_SOURCES += \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100585 protocol/screenshooter-protocol.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800586 protocol/screenshooter-client-protocol.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100587 protocol/text-cursor-position-client-protocol.h \
588 protocol/text-cursor-position-protocol.c \
589 protocol/text-protocol.c \
590 protocol/text-client-protocol.h \
591 protocol/input-method-protocol.c \
592 protocol/input-method-client-protocol.h \
593 protocol/desktop-shell-client-protocol.h \
594 protocol/desktop-shell-protocol.c \
595 protocol/scaler-client-protocol.h \
596 protocol/scaler-protocol.c \
597 protocol/workspaces-client-protocol.h \
598 protocol/workspaces-protocol.c \
599 protocol/xdg-shell-protocol.c \
600 protocol/xdg-shell-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800601
602
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -0800603westondatadir = $(datadir)/weston
604dist_westondata_DATA = \
605 data/wayland.svg \
606 data/wayland.png \
607 data/pattern.png \
608 data/terminal.png \
609 data/border.png \
610 data/icon_window.png \
611 data/sign_close.png \
612 data/sign_maximize.png \
613 data/sign_minimize.png
Kristian Høgsberge895f142014-01-27 21:46:30 -0800614
615
616if BUILD_WCAP_TOOLS
617bin_PROGRAMS += wcap-decode
618
619wcap_decode_SOURCES = \
620 wcap/main.c \
621 wcap/wcap-decode.c \
622 wcap/wcap-decode.h
623
624wcap_decode_CFLAGS = $(GCC_CFLAGS) $(WCAP_CFLAGS)
625wcap_decode_LDADD = $(WCAP_LIBS)
626endif
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800627
628
629if ENABLE_DESKTOP_SHELL
630
631module_LTLIBRARIES += desktop-shell.la
632
633desktop_shell_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100634 -I$(top_builddir)/protocol \
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800635 -I$(top_srcdir)/shared \
636 -I$(top_srcdir)/src \
637 -I$(top_builddir)/src \
638 -I$(top_builddir)/desktop-shell \
639 -DDATADIR='"$(datadir)"' \
640 -DMODULEDIR='"$(moduledir)"' \
641 -DLIBEXECDIR='"$(libexecdir)"' \
642 -DIN_WESTON
643
644desktop_shell_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800645desktop_shell_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800646desktop_shell_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
647desktop_shell_la_SOURCES = \
648 desktop-shell/shell.h \
649 desktop-shell/shell.c \
650 desktop-shell/exposay.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800651 desktop-shell/input-panel.c
652nodist_desktop_shell_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100653 protocol/desktop-shell-protocol.c \
654 protocol/desktop-shell-server-protocol.h \
655 protocol/xdg-shell-protocol.c \
656 protocol/xdg-shell-server-protocol.h
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800657
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800658BUILT_SOURCES += $(nodist_desktop_shell_la_SOURCES)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800659endif
660
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800661
662if ENABLE_XWAYLAND
663
664module_LTLIBRARIES += xwayland.la
665
666xwayland_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100667 -I$(top_builddir)/protocol \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800668 -I$(top_srcdir)/shared \
669 -I$(top_srcdir)/src \
670 -I$(top_builddir)/src \
671 -I$(top_builddir)/xwayland \
672 -DDATADIR='"$(datadir)"' \
673 -DMODULEDIR='"$(moduledir)"' \
674 -DLIBEXECDIR='"$(libexecdir)"' \
675 -DXSERVER_PATH='"@XSERVER_PATH@"'
676
677xwayland_la_LDFLAGS = -module -avoid-version
678xwayland_la_LIBADD = \
679 $(XWAYLAND_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800680 $(top_builddir)/libshared-cairo.la
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800681xwayland_la_CFLAGS = \
682 $(GCC_CFLAGS) \
683 $(COMPOSITOR_CFLAGS) \
684 $(PIXMAN_CFLAGS) \
685 $(CAIRO_CFLAGS)
686xwayland_la_SOURCES = \
687 xwayland/xwayland.h \
688 xwayland/window-manager.c \
689 xwayland/selection.c \
690 xwayland/dnd.c \
691 xwayland/launcher.c \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800692 xwayland/hash.c \
693 xwayland/hash.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800694nodist_xwayland_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100695 protocol/xserver-protocol.c \
696 protocol/xserver-server-protocol.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800697
698BUILT_SOURCES += $(nodist_xwayland_la_SOURCES)
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800699endif
700
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -0800701
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800702#
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800703# Shared utilities
704#
705
706noinst_LTLIBRARIES += libshared.la libshared-cairo.la
707
708libshared_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
709
710libshared_la_SOURCES = \
711 shared/config-parser.c \
712 shared/option-parser.c \
713 shared/config-parser.h \
714 shared/os-compatibility.c \
715 shared/os-compatibility.h
716
717libshared_cairo_la_CFLAGS = \
718 -DDATADIR='"$(datadir)"' \
719 $(GCC_CFLAGS) \
720 $(COMPOSITOR_CFLAGS) \
721 $(PIXMAN_CFLAGS) \
722 $(CAIRO_CFLAGS) \
723 $(PNG_CFLAGS) \
724 $(WEBP_CFLAGS)
725
726libshared_cairo_la_LIBADD = \
727 $(PIXMAN_LIBS) \
728 $(CAIRO_LIBS) \
729 $(PNG_LIBS) \
730 $(WEBP_LIBS) \
731 $(JPEG_LIBS)
732
733libshared_cairo_la_SOURCES = \
734 $(libshared_la_SOURCES) \
735 shared/image-loader.c \
736 shared/image-loader.h \
737 shared/cairo-util.c \
738 shared/frame.c \
739 shared/cairo-util.h
740
741
742#
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800743# tests subdirectory
744#
745
746TESTS = $(shared_tests) $(module_tests) $(weston_tests)
747
748shared_tests = \
749 config-parser.test \
750 vertex-clip.test
751
752module_tests = \
753 surface-test.la \
754 surface-global-test.la
755
756weston_tests = \
757 bad_buffer.weston \
758 keyboard.weston \
759 event.weston \
760 button.weston \
761 text.weston \
762 subsurface.weston
763
764
765AM_TESTS_ENVIRONMENT = \
766 abs_builddir='$(abs_builddir)'; export abs_builddir;
767
768TEST_EXTENSIONS = .la .weston
769LA_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
770WESTON_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
771
772clean-local:
773 -rm -rf tests/logs
774
775# To remove when automake 1.11 support is dropped
776export abs_builddir
777
778noinst_LTLIBRARIES += \
779 weston-test.la \
780 $(module_tests) \
781 libtest-runner.la \
782 libtest-client.la
783
784noinst_PROGRAMS += \
785 $(setbacklight) \
786 $(shared_tests) \
787 $(weston_tests) \
788 matrix-test
789
790test_module_ldflags = \
791 -module -avoid-version -rpath $(libdir) $(COMPOSITOR_LIBS)
792
793surface_global_test_la_SOURCES = tests/surface-global-test.c
794surface_global_test_la_LDFLAGS = $(test_module_ldflags)
795surface_global_test_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
796
797surface_test_la_SOURCES = tests/surface-test.c
798surface_test_la_LDFLAGS = $(test_module_ldflags)
799surface_test_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
800
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800801weston_test_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800802weston_test_la_LDFLAGS = $(test_module_ldflags)
803weston_test_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800804weston_test_la_SOURCES = tests/weston-test.c
805nodist_weston_test_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100806 protocol/wayland-test-protocol.c \
807 protocol/wayland-test-server-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800808
809if ENABLE_EGL
810weston_test_la_CFLAGS += $(EGL_TESTS_CFLAGS)
811weston_test_la_LDFLAGS += $(EGL_TESTS_LIBS)
812endif
813
814libtest_runner_la_SOURCES = \
815 tests/weston-test-runner.c \
816 tests/weston-test-runner.h
817libtest_runner_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
818
819config_parser_test_SOURCES = tests/config-parser-test.c
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800820config_parser_test_LDADD = libshared.la libtest-runner.la $(COMPOSITOR_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800821
822vertex_clip_test_SOURCES = \
823 tests/vertex-clip-test.c \
824 src/vertex-clipping.c \
825 src/vertex-clipping.h
826vertex_clip_test_LDADD = libtest-runner.la -lm -lrt
827
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100828libtest_client_la_SOURCES = \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800829 tests/weston-test-client-helper.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800830 tests/weston-test-client-helper.h
831nodist_libtest_client_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100832 protocol/wayland-test-protocol.c \
833 protocol/wayland-test-client-protocol.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800834libtest_client_la_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800835libtest_client_la_LIBADD = $(TEST_CLIENT_LIBS) libshared.la libtest-runner.la
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800836
837bad_buffer_weston_SOURCES = tests/bad-buffer-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800838bad_buffer_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800839bad_buffer_weston_LDADD = libtest-client.la
840
841keyboard_weston_SOURCES = tests/keyboard-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800842keyboard_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800843keyboard_weston_LDADD = libtest-client.la
844
845event_weston_SOURCES = tests/event-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800846event_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800847event_weston_LDADD = libtest-client.la
848
849button_weston_SOURCES = tests/button-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800850button_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800851button_weston_LDADD = libtest-client.la
852
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800853text_weston_SOURCES = tests/text-test.c
854nodist_text_weston_SOURCES = \
855 protocol/text-protocol.c \
856 protocol/text-client-protocol.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800857text_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800858text_weston_LDADD = libtest-client.la
859
860subsurface_weston_SOURCES = tests/subsurface-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800861subsurface_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800862subsurface_weston_LDADD = libtest-client.la
863
864if ENABLE_EGL
865weston_tests += buffer-count.weston
866buffer_count_weston_SOURCES = tests/buffer-count-test.c
867buffer_count_weston_CFLAGS = $(GCC_CFLAGS) $(EGL_TESTS_CFLAGS)
868buffer_count_weston_LDADD = libtest-client.la $(EGL_TESTS_LIBS)
869endif
870
871if ENABLE_XWAYLAND_TEST
872weston_tests += xwayland.weston
873xwayland_weston_SOURCES = tests/xwayland-test.c
874xwayland_weston_CFLAGS = $(GCC_CFLAGS) $(XWAYLAND_TEST_CFLAGS)
875xwayland_weston_LDADD = libtest-client.la $(XWAYLAND_TEST_LIBS)
876endif
877
878matrix_test_SOURCES = \
879 tests/matrix-test.c \
880 shared/matrix.c \
881 shared/matrix.h
882matrix_test_CPPFLAGS = -DUNIT_TEST
883matrix_test_LDADD = -lm -lrt
884
885if BUILD_SETBACKLIGHT
886noinst_PROGRAMS += setbacklight
887setbacklight_SOURCES = \
888 tests/setbacklight.c \
889 src/libbacklight.c \
890 src/libbacklight.h
891setbacklight_CFLAGS = $(AM_CFLAGS) $(SETBACKLIGHT_CFLAGS)
892setbacklight_LDADD = $(SETBACKLIGHT_LIBS)
893endif
894
895EXTRA_DIST += tests/weston-tests-env
896
897BUILT_SOURCES += \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100898 protocol/wayland-test-protocol.c \
899 protocol/wayland-test-server-protocol.h \
900 protocol/wayland-test-client-protocol.h \
901 protocol/text-protocol.c \
902 protocol/text-client-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800903
Kristian Høgsbergcd312752014-02-01 00:38:15 -0800904EXTRA_DIST += \
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -0800905 protocol/desktop-shell.xml \
906 protocol/screenshooter.xml \
907 protocol/xserver.xml \
908 protocol/text.xml \
909 protocol/input-method.xml \
910 protocol/workspaces.xml \
911 protocol/text-cursor-position.xml \
912 protocol/wayland-test.xml \
913 protocol/xdg-shell.xml \
914 protocol/scaler.xml
915
Kristian Høgsberg68c5c102014-01-27 22:33:04 -0800916man_MANS = weston.1 weston.ini.5
917
918if ENABLE_DRM_COMPOSITOR
919man_MANS += weston-drm.7
920endif
921
922MAN_SUBSTS = \
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'
927
928SUFFIXES = .1 .5 .7 .man
929
930%.1 %.5 %.7 : man/%.man
931 $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
932
933EXTRA_DIST += \
934 man/weston.man \
935 man/weston-drm.man \
936 man/weston.ini.man
937
938CLEANFILES += $(man_MANS)
939
940
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100941protocol/%-protocol.c : $(top_srcdir)/protocol/%.xml
942 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -0800943
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100944protocol/%-server-protocol.h : $(top_srcdir)/protocol/%.xml
945 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -0800946
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100947protocol/%-client-protocol.h : $(top_srcdir)/protocol/%.xml
948 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@