blob: f4e1ce906a69f9f1555c9379085542796b46fe5b [file] [log] [blame]
Thierry Reding0e6d9a72014-05-27 09:07:54 +02001ACLOCAL_AMFLAGS = -I m4
2
Kristian Høgsberge895f142014-01-27 21:46:30 -08003bin_PROGRAMS =
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -08004noinst_PROGRAMS =
Kristian Høgsberge73eccd2014-01-31 16:15:11 -08005libexec_PROGRAMS =
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -08006moduledir = $(libdir)/weston
7module_LTLIBRARIES =
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -08008noinst_LTLIBRARIES =
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -08009BUILT_SOURCES =
Kristian Høgsberge895f142014-01-27 21:46:30 -080010
Pekka Paalanen3d3f4852014-08-20 12:11:04 +030011# Do not run xwayland test while it is known broken.
12AM_DISTCHECK_CONFIGURE_FLAGS = --disable-setuid-install --disable-xwayland-test
Kristian Høgsberg24639cc2013-02-25 13:03:15 -050013
Kristian Høgsberg08229422014-02-01 00:33:04 -080014EXTRA_DIST = weston.ini.in
Neil Robertse3de16e2013-11-22 16:46:00 +000015
16weston.ini : $(srcdir)/weston.ini.in
17 $(AM_V_GEN)$(SED) \
18 -e 's|@bindir[@]|$(bindir)|g' \
19 -e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
20 -e 's|@libexecdir[@]|$(libexecdir)|g' \
21 $< > $@
22
Kristian Høgsbergcd312752014-02-01 00:38:15 -080023all-local : weston.ini
Kristian Høgsberg98463742013-12-16 23:12:46 -080024
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080025AM_CFLAGS = $(GCC_CFLAGS)
26
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080027AM_CPPFLAGS = \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080028 -I$(top_srcdir)/src \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080029 -I$(top_builddir)/src \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -080030 -I$(top_builddir)/clients \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080031 -I$(top_builddir)/tests \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080032 -I$(top_srcdir)/shared \
Quentin Glidic088ba5e2014-02-01 21:39:12 +010033 -I$(top_builddir)/protocol \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080034 -DDATADIR='"$(datadir)"' \
35 -DMODULEDIR='"$(moduledir)"' \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -080036 -DLIBEXECDIR='"$(libexecdir)"' \
37 -DBINDIR='"$(bindir)"'
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080038
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -080039CLEANFILES = weston.ini $(BUILT_SOURCES)
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -080040
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080041bin_PROGRAMS += weston
42
43weston_LDFLAGS = -export-dynamic
44weston_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON
45weston_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS) $(LIBUNWIND_CFLAGS)
46weston_LDADD = $(COMPOSITOR_LIBS) $(LIBUNWIND_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -080047 $(DLOPEN_LIBS) -lm libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080048
49weston_SOURCES = \
50 src/git-version.h \
51 src/log.c \
52 src/compositor.c \
53 src/compositor.h \
54 src/input.c \
55 src/data-device.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080056 src/screenshooter.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080057 src/clipboard.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080058 src/zoom.c \
59 src/text-backend.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080060 src/bindings.c \
61 src/animation.c \
62 src/noop-renderer.c \
63 src/pixman-renderer.c \
64 src/pixman-renderer.h \
65 shared/matrix.c \
66 shared/matrix.h \
67 shared/zalloc.h \
68 src/weston-egl-ext.h
69
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -080070nodist_weston_SOURCES = \
71 protocol/screenshooter-protocol.c \
72 protocol/screenshooter-server-protocol.h \
73 protocol/text-cursor-position-protocol.c \
74 protocol/text-cursor-position-server-protocol.h \
75 protocol/text-protocol.c \
76 protocol/text-server-protocol.h \
77 protocol/input-method-protocol.c \
78 protocol/input-method-server-protocol.h \
79 protocol/workspaces-protocol.c \
80 protocol/workspaces-server-protocol.h \
Pekka Paalanen7e62d252014-09-23 22:08:42 -040081 protocol/presentation_timing-protocol.c \
82 protocol/presentation_timing-server-protocol.h \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -080083 protocol/scaler-protocol.c \
84 protocol/scaler-server-protocol.h
85
86BUILT_SOURCES += $(nodist_weston_SOURCES)
87
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -080088# Track this dependency explicitly instead of using BUILT_SOURCES. We
89# add BUILT_SOURCES to CLEANFILES, but we want to keep git-version.h
90# in case we're building from tarballs.
91
92src/compositor.c : $(top_builddir)/src/git-version.h
93
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080094noinst_LTLIBRARIES += \
95 libsession-helper.la
96
97libsession_helper_la_SOURCES = \
98 src/weston-launch.h \
99 src/launcher-util.c \
100 src/launcher-util.h
101libsession_helper_la_CFLAGS = $(GCC_CFLAGS) $(LIBDRM_CFLAGS) $(PIXMAN_CFLAGS) $(COMPOSITOR_CFLAGS)
102libsession_helper_la_LIBADD = $(LIBDRM_LIBS)
103
104if ENABLE_DBUS
105if HAVE_SYSTEMD_LOGIN
106libsession_helper_la_SOURCES += \
107 src/dbus.h \
108 src/dbus.c \
109 src/logind-util.h \
110 src/logind-util.c
111libsession_helper_la_CFLAGS += $(SYSTEMD_LOGIN_CFLAGS) $(DBUS_CFLAGS)
112libsession_helper_la_LIBADD += $(SYSTEMD_LOGIN_LIBS) $(DBUS_LIBS)
113endif
114endif
115
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800116if HAVE_GIT_REPO
117src/git-version.h : $(top_srcdir)/.git/logs/HEAD
118 $(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 -0800119else
120src/git-version.h :
121 $(AM_V_GEN)echo "#define BUILD_ID \"unknown (not built from git or tarball)\"" > $@
122
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800123endif
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800124
125.FORCE :
126
127if BUILD_WESTON_LAUNCH
128bin_PROGRAMS += weston-launch
129weston_launch_SOURCES = src/weston-launch.c src/weston-launch.h
130weston_launch_CPPFLAGS = -DBINDIR='"$(bindir)"'
131weston_launch_CFLAGS= \
132 $(GCC_CFLAGS) \
133 $(PAM_CFLAGS) \
134 $(SYSTEMD_LOGIN_CFLAGS) \
135 $(LIBDRM_CFLAGS)
136weston_launch_LDADD = $(PAM_LIBS) $(SYSTEMD_LOGIN_LIBS) $(LIBDRM_LIBS)
137
138if ENABLE_SETUID_INSTALL
139install-exec-hook:
140 chown root $(DESTDIR)$(bindir)/weston-launch
141 chmod u+s $(DESTDIR)$(bindir)/weston-launch
142endif
143
144endif # BUILD_WESTON_LAUNCH
145
146pkgconfigdir = $(libdir)/pkgconfig
147pkgconfig_DATA = src/weston.pc
148
149westonincludedir = $(includedir)/weston
150westoninclude_HEADERS = \
151 src/version.h \
152 src/compositor.h \
153 shared/matrix.h \
154 shared/config-parser.h \
155 shared/zalloc.h
156
157if ENABLE_EGL
158module_LTLIBRARIES += gl-renderer.la
159gl_renderer_la_LDFLAGS = -module -avoid-version
160gl_renderer_la_LIBADD = $(COMPOSITOR_LIBS) $(EGL_LIBS)
161gl_renderer_la_CFLAGS = \
162 $(COMPOSITOR_CFLAGS) \
163 $(EGL_CFLAGS) \
164 $(GCC_CFLAGS)
165gl_renderer_la_SOURCES = \
166 src/gl-renderer.h \
167 src/gl-renderer.c \
168 src/vertex-clipping.c \
169 src/vertex-clipping.h
170endif
171
172if ENABLE_X11_COMPOSITOR
173module_LTLIBRARIES += x11-backend.la
174x11_backend_la_LDFLAGS = -module -avoid-version
175x11_backend_la_LIBADD = $(COMPOSITOR_LIBS) $(X11_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800176 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800177x11_backend_la_CFLAGS = \
178 $(COMPOSITOR_CFLAGS) \
179 $(EGL_CFLAGS) \
180 $(PIXMAN_CFLAGS) \
181 $(CAIRO_CFLAGS) \
182 $(X11_COMPOSITOR_CFLAGS) \
183 $(GCC_CFLAGS)
184x11_backend_la_SOURCES = src/compositor-x11.c
185endif
186
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100187INPUT_BACKEND_LIBS = $(LIBINPUT_BACKEND_LIBS)
Peter Hutterer823ad332014-11-26 07:06:31 +1000188INPUT_BACKEND_SOURCES = \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100189 src/libinput-seat.c \
190 src/libinput-seat.h \
191 src/libinput-device.c \
192 src/libinput-device.h
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100193
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800194if ENABLE_DRM_COMPOSITOR
195module_LTLIBRARIES += drm-backend.la
196drm_backend_la_LDFLAGS = -module -avoid-version
197drm_backend_la_LIBADD = \
198 $(COMPOSITOR_LIBS) \
199 $(DRM_COMPOSITOR_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100200 $(INPUT_BACKEND_LIBS) \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100201 libshared.la -lrt \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800202 libsession-helper.la
203drm_backend_la_CFLAGS = \
204 $(COMPOSITOR_CFLAGS) \
205 $(EGL_CFLAGS) \
206 $(DRM_COMPOSITOR_CFLAGS) \
207 $(GCC_CFLAGS)
208drm_backend_la_SOURCES = \
209 src/compositor-drm.c \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100210 $(INPUT_BACKEND_SOURCES) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800211 src/libbacklight.c \
212 src/libbacklight.h
213
214if ENABLE_VAAPI_RECORDER
215drm_backend_la_SOURCES += src/vaapi-recorder.c src/vaapi-recorder.h
216drm_backend_la_LIBADD += $(LIBVA_LIBS)
217drm_backend_la_CFLAGS += $(LIBVA_CFLAGS)
218endif
219endif
220
221if ENABLE_WAYLAND_COMPOSITOR
222module_LTLIBRARIES += wayland-backend.la
223wayland_backend_la_LDFLAGS = -module -avoid-version
224wayland_backend_la_LIBADD = \
225 $(COMPOSITOR_LIBS) \
226 $(WAYLAND_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800227 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800228wayland_backend_la_CFLAGS = \
229 $(COMPOSITOR_CFLAGS) \
230 $(EGL_CFLAGS) \
231 $(PIXMAN_CFLAGS) \
232 $(CAIRO_CFLAGS) \
233 $(WAYLAND_COMPOSITOR_CFLAGS) \
234 $(GCC_CFLAGS)
235wayland_backend_la_SOURCES = src/compositor-wayland.c
Jason Ekstrand53ee0dc2014-04-02 19:53:54 -0500236nodist_wayland_backend_la_SOURCES = \
237 protocol/fullscreen-shell-protocol.c \
238 protocol/fullscreen-shell-client-protocol.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800239endif
240
241if ENABLE_RPI_COMPOSITOR
242if INSTALL_RPI_COMPOSITOR
243module_LTLIBRARIES += rpi-backend.la
244else
245noinst_LTLIBRARIES += rpi-backend.la
246endif
247
248rpi_backend_la_LDFLAGS = -module -avoid-version
249rpi_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
250 $(RPI_COMPOSITOR_LIBS) \
251 $(RPI_BCM_HOST_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100252 $(INPUT_BACKEND_LIBS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800253 libsession-helper.la \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800254 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800255rpi_backend_la_CFLAGS = \
256 $(GCC_CFLAGS) \
257 $(COMPOSITOR_CFLAGS) \
258 $(RPI_COMPOSITOR_CFLAGS) \
259 $(RPI_BCM_HOST_CFLAGS)
260rpi_backend_la_SOURCES = \
261 src/compositor-rpi.c \
262 src/rpi-renderer.c \
263 src/rpi-renderer.h \
264 src/rpi-bcm-stubs.h \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100265 $(INPUT_BACKEND_SOURCES)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800266
267if ENABLE_EGL
268rpi_backend_la_LIBADD += $(EGL_LIBS)
269rpi_backend_la_CFLAGS += $(EGL_CFLAGS)
270endif
271
272endif
273
274if ENABLE_HEADLESS_COMPOSITOR
275module_LTLIBRARIES += headless-backend.la
276headless_backend_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800277headless_backend_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
278headless_backend_la_CFLAGS = $(COMPOSITOR_CFLAGS) $(GCC_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800279headless_backend_la_SOURCES = src/compositor-headless.c
280endif
281
282if ENABLE_FBDEV_COMPOSITOR
283module_LTLIBRARIES += fbdev-backend.la
284fbdev_backend_la_LDFLAGS = -module -avoid-version
285fbdev_backend_la_LIBADD = \
286 $(COMPOSITOR_LIBS) \
287 $(FBDEV_COMPOSITOR_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100288 $(INPUT_BACKEND_LIBS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800289 libsession-helper.la \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800290 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800291fbdev_backend_la_CFLAGS = \
292 $(COMPOSITOR_CFLAGS) \
293 $(EGL_CFLAGS) \
294 $(FBDEV_COMPOSITOR_CFLAGS) \
295 $(PIXMAN_CFLAGS) \
296 $(GCC_CFLAGS)
297fbdev_backend_la_SOURCES = \
298 src/compositor-fbdev.c \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100299 $(INPUT_BACKEND_SOURCES)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800300endif
301
302if ENABLE_RDP_COMPOSITOR
303module_LTLIBRARIES += rdp-backend.la
304rdp_backend_la_LDFLAGS = -module -avoid-version
305rdp_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
306 $(RDP_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800307 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800308rdp_backend_la_CFLAGS = \
309 $(COMPOSITOR_CFLAGS) \
310 $(RDP_COMPOSITOR_CFLAGS) \
311 $(GCC_CFLAGS)
312rdp_backend_la_SOURCES = src/compositor-rdp.c
313endif
314
315if HAVE_LCMS
316module_LTLIBRARIES += cms-static.la
317cms_static_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800318cms_static_la_LIBADD = $(COMPOSITOR_LIBS) $(LCMS_LIBS) libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800319cms_static_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS) $(LCMS_CFLAGS)
320cms_static_la_SOURCES = \
321 src/cms-static.c \
322 src/cms-helper.c \
323 src/cms-helper.h
324if ENABLE_COLORD
325module_LTLIBRARIES += cms-colord.la
326cms_colord_la_LDFLAGS = -module -avoid-version
327cms_colord_la_LIBADD = $(COMPOSITOR_LIBS) $(COLORD_LIBS)
328cms_colord_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS) $(COLORD_CFLAGS)
329cms_colord_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100330 src/cms-colord.c \
331 src/cms-helper.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800332 src/cms-helper.h
333endif
334endif
335
336noinst_PROGRAMS += spring-tool
337spring_tool_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
338spring_tool_LDADD = $(COMPOSITOR_LIBS) -lm
339spring_tool_SOURCES = \
340 src/spring-tool.c \
341 src/animation.c \
342 shared/matrix.c \
343 shared/matrix.h \
344 src/compositor.h
345
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800346if BUILD_CLIENTS
347
348bin_PROGRAMS += weston-terminal weston-info
349
350libexec_PROGRAMS += \
351 weston-desktop-shell \
352 weston-screenshooter \
353 weston-keyboard \
354 weston-simple-im
355
356demo_clients = \
357 weston-flower \
358 weston-image \
359 weston-cliptest \
360 weston-dnd \
361 weston-smoke \
362 weston-resizor \
363 weston-eventdemo \
364 weston-clickdot \
365 weston-transformed \
366 weston-fullscreen \
367 weston-stacking \
368 weston-calibrator \
369 weston-scaler
370
371if INSTALL_DEMO_CLIENTS
372bin_PROGRAMS += $(demo_clients)
373else
374noinst_PROGRAMS += $(demo_clients)
375endif
376
377
378if BUILD_SIMPLE_CLIENTS
379demo_clients += \
380 weston-simple-shm \
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500381 weston-simple-damage \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800382 weston-simple-touch \
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400383 weston-presentation-shm \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800384 weston-multi-resource
385
Kristian Høgsbergfe84a972014-02-11 14:23:19 -0800386weston_simple_shm_SOURCES = clients/simple-shm.c
387nodist_weston_simple_shm_SOURCES = \
Kristian Høgsbergdfaf65b2014-02-07 17:01:57 -0800388 protocol/xdg-shell-protocol.c \
Jason Ekstrand428c24e2014-04-02 19:53:48 -0500389 protocol/xdg-shell-client-protocol.h \
390 protocol/fullscreen-shell-protocol.c \
391 protocol/fullscreen-shell-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800392weston_simple_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800393weston_simple_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800394
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500395weston_simple_damage_SOURCES = clients/simple-damage.c
396nodist_weston_simple_damage_SOURCES = \
397 protocol/scaler-protocol.c \
398 protocol/scaler-client-protocol.h \
399 protocol/xdg-shell-protocol.c \
400 protocol/xdg-shell-client-protocol.h \
401 protocol/fullscreen-shell-protocol.c \
402 protocol/fullscreen-shell-client-protocol.h
403weston_simple_damage_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
404weston_simple_damage_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
405
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800406weston_simple_touch_SOURCES = clients/simple-touch.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800407weston_simple_touch_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800408weston_simple_touch_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800409
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400410weston_presentation_shm_SOURCES = clients/presentation-shm.c
411nodist_weston_presentation_shm_SOURCES = \
412 protocol/presentation_timing-protocol.c \
413 protocol/presentation_timing-client-protocol.h
414weston_presentation_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
415weston_presentation_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la -lm
416
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800417weston_multi_resource_SOURCES = clients/multi-resource.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800418weston_multi_resource_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Javier Jardónc47931e2014-10-27 15:13:19 +0000419weston_multi_resource_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la -lrt -lm
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800420endif
421
422if BUILD_SIMPLE_EGL_CLIENTS
423demo_clients += weston-simple-egl
Kristian Høgsbergfe84a972014-02-11 14:23:19 -0800424weston_simple_egl_SOURCES = clients/simple-egl.c
425nodist_weston_simple_egl_SOURCES = \
Kristian Høgsbergdfaf65b2014-02-07 17:01:57 -0800426 protocol/xdg-shell-protocol.c \
427 protocol/xdg-shell-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800428weston_simple_egl_CFLAGS = $(AM_CFLAGS) $(SIMPLE_EGL_CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800429weston_simple_egl_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
430endif
431
432noinst_LTLIBRARIES += libtoytoolkit.la
433
434libtoytoolkit_la_SOURCES = \
435 clients/window.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800436 clients/window.h
437
438nodist_libtoytoolkit_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100439 protocol/text-cursor-position-protocol.c \
440 protocol/text-cursor-position-client-protocol.h \
441 protocol/scaler-protocol.c \
442 protocol/scaler-client-protocol.h \
443 protocol/workspaces-protocol.c \
444 protocol/workspaces-client-protocol.h \
Pekka Paalanen7e62d252014-09-23 22:08:42 -0400445 protocol/presentation_timing-protocol.c \
446 protocol/presentation_timing-client-protocol.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100447 protocol/xdg-shell-protocol.c \
Nobuhiko Tanibatabff1b4a2014-11-27 13:21:34 +0900448 protocol/xdg-shell-client-protocol.h \
449 protocol/ivi-application-protocol.c \
450 protocol/ivi-application-client-protocol.h
Jasper St. Pierre0790e392013-12-09 14:58:00 -0500451
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800452BUILT_SOURCES += $(nodist_libtoytoolkit_la_SOURCES)
453
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800454
455libtoytoolkit_la_LIBADD = \
456 $(CLIENT_LIBS) \
457 $(CAIRO_EGL_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800458 libshared-cairo.la -lrt -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800459libtoytoolkit_la_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(CAIRO_EGL_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800460
461weston_flower_SOURCES = clients/flower.c
462weston_flower_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800463weston_flower_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800464
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100465weston_screenshooter_SOURCES = \
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800466 clients/screenshot.c
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800467nodist_weston_screenshooter_SOURCES = \
468 protocol/screenshooter-protocol.c \
469 protocol/screenshooter-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800470weston_screenshooter_LDADD = $(CLIENT_LIBS) libshared.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800471weston_screenshooter_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800472
473weston_terminal_SOURCES = clients/terminal.c
474weston_terminal_LDADD = libtoytoolkit.la -lutil
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800475weston_terminal_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800476
477weston_image_SOURCES = clients/image.c
478weston_image_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800479weston_image_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800480
Pekka Paalanen461e93c2014-08-20 11:58:47 +0300481weston_cliptest_SOURCES = \
482 clients/cliptest.c \
483 src/vertex-clipping.c \
484 src/vertex-clipping.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800485weston_cliptest_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800486weston_cliptest_LDADD = libtoytoolkit.la
487
488weston_dnd_SOURCES = clients/dnd.c
489weston_dnd_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800490weston_dnd_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800491
492weston_smoke_SOURCES = clients/smoke.c
493weston_smoke_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800494weston_smoke_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800495
496weston_resizor_SOURCES = clients/resizor.c
497weston_resizor_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800498weston_resizor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800499
500weston_scaler_SOURCES = clients/scaler.c
501weston_scaler_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800502weston_scaler_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800503
504if HAVE_CAIRO_GLESV2
505demo_clients += weston-nested weston-nested-client
506
507weston_nested_SOURCES = clients/nested.c
508weston_nested_LDADD = libtoytoolkit.la $(SERVER_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800509weston_nested_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800510
511weston_nested_client_SOURCES = clients/nested-client.c
512weston_nested_client_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800513weston_nested_client_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800514endif
515
516weston_eventdemo_SOURCES = clients/eventdemo.c
517weston_eventdemo_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800518weston_eventdemo_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800519
520weston_clickdot_SOURCES = clients/clickdot.c
521weston_clickdot_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800522weston_clickdot_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800523
524weston_transformed_SOURCES = clients/transformed.c
525weston_transformed_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800526weston_transformed_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800527
528weston_fullscreen_SOURCES = clients/fullscreen.c
Jason Ekstrand2bb72fe2014-04-02 19:53:52 -0500529nodist_weston_fullscreen_SOURCES = \
530 protocol/fullscreen-shell-protocol.c \
531 protocol/fullscreen-shell-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800532weston_fullscreen_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800533weston_fullscreen_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800534
535weston_stacking_SOURCES = clients/stacking.c
536weston_stacking_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800537weston_stacking_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800538
539weston_calibrator_SOURCES = clients/calibrator.c \
540 shared/matrix.c \
541 shared/matrix.h
542weston_calibrator_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800543weston_calibrator_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800544
545if BUILD_SUBSURFACES_CLIENT
546demo_clients += weston-subsurfaces
547weston_subsurfaces_SOURCES = clients/subsurfaces.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800548weston_subsurfaces_CFLAGS = \
549 $(AM_CFLAGS) \
550 $(SIMPLE_EGL_CLIENT_CFLAGS) \
551 $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800552weston_subsurfaces_LDADD = libtoytoolkit.la $(SIMPLE_EGL_CLIENT_LIBS) -lm
553endif
554
555if HAVE_PANGO
556demo_clients += weston-editor
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800557weston_editor_SOURCES = clients/editor.c
558nodist_weston_editor_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100559 protocol/text-protocol.c \
560 protocol/text-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800561weston_editor_LDADD = libtoytoolkit.la $(PANGO_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800562weston_editor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(PANGO_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800563endif
564
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800565weston_keyboard_SOURCES = clients/keyboard.c
566nodist_weston_keyboard_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100567 protocol/desktop-shell-client-protocol.h \
568 protocol/desktop-shell-protocol.c \
569 protocol/input-method-protocol.c \
570 protocol/input-method-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800571weston_keyboard_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800572weston_keyboard_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800573
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800574weston_simple_im_SOURCES = clients/weston-simple-im.c
575nodist_weston_simple_im_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100576 protocol/input-method-protocol.c \
577 protocol/input-method-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800578weston_simple_im_LDADD = $(CLIENT_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800579weston_simple_im_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800580
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800581weston_info_SOURCES = clients/weston-info.c
Pekka Paalanen93a6afd2014-09-23 22:08:44 -0400582nodist_weston_info_SOURCES = \
583 protocol/presentation_timing-protocol.c \
584 protocol/presentation_timing-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800585weston_info_LDADD = $(WESTON_INFO_LIBS) libshared.la
Pekka Paalanen5124b532014-02-03 13:12:34 +0200586weston_info_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800587
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800588weston_desktop_shell_SOURCES = clients/desktop-shell.c
589nodist_weston_desktop_shell_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100590 protocol/desktop-shell-client-protocol.h \
591 protocol/desktop-shell-protocol.c
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800592weston_desktop_shell_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800593weston_desktop_shell_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800594
595if BUILD_FULL_GL_CLIENTS
596demo_clients += weston-gears
597weston_gears_SOURCES = clients/gears.c
598weston_gears_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800599weston_gears_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800600
601if HAVE_GLU
602libexec_PROGRAMS += weston-screensaver
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100603weston_screensaver_SOURCES = \
604 clients/wscreensaver.c \
605 clients/wscreensaver.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100606 clients/wscreensaver-glue.c \
607 clients/wscreensaver-glue.h \
608 clients/glmatrix.c \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800609 clients/matrix3.xpm
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800610nodist_weston_screensaver_SOURCES = \
611 protocol/desktop-shell-client-protocol.h \
612 protocol/desktop-shell-protocol.c
613
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800614weston_screensaver_LDADD = libtoytoolkit.la $(GLU_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800615weston_screensaver_CFLAGS = $(AM_CFLAGS) $(GLU_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800616
617endif
618
619endif
620
621endif
622
623BUILT_SOURCES += \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100624 protocol/screenshooter-protocol.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800625 protocol/screenshooter-client-protocol.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100626 protocol/text-cursor-position-client-protocol.h \
627 protocol/text-cursor-position-protocol.c \
628 protocol/text-protocol.c \
629 protocol/text-client-protocol.h \
630 protocol/input-method-protocol.c \
631 protocol/input-method-client-protocol.h \
632 protocol/desktop-shell-client-protocol.h \
633 protocol/desktop-shell-protocol.c \
634 protocol/scaler-client-protocol.h \
635 protocol/scaler-protocol.c \
636 protocol/workspaces-client-protocol.h \
637 protocol/workspaces-protocol.c \
Jason Ekstrand428c24e2014-04-02 19:53:48 -0500638 protocol/fullscreen-shell-protocol.c \
639 protocol/fullscreen-shell-client-protocol.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100640 protocol/xdg-shell-protocol.c \
641 protocol/xdg-shell-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800642
643
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -0800644westondatadir = $(datadir)/weston
645dist_westondata_DATA = \
646 data/wayland.svg \
647 data/wayland.png \
648 data/pattern.png \
649 data/terminal.png \
650 data/border.png \
651 data/icon_window.png \
652 data/sign_close.png \
653 data/sign_maximize.png \
654 data/sign_minimize.png
Kristian Høgsberge895f142014-01-27 21:46:30 -0800655
656
657if BUILD_WCAP_TOOLS
658bin_PROGRAMS += wcap-decode
659
660wcap_decode_SOURCES = \
661 wcap/main.c \
662 wcap/wcap-decode.c \
663 wcap/wcap-decode.h
664
665wcap_decode_CFLAGS = $(GCC_CFLAGS) $(WCAP_CFLAGS)
666wcap_decode_LDADD = $(WCAP_LIBS)
667endif
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800668
669
670if ENABLE_DESKTOP_SHELL
671
672module_LTLIBRARIES += desktop-shell.la
673
674desktop_shell_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100675 -I$(top_builddir)/protocol \
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800676 -I$(top_srcdir)/shared \
677 -I$(top_srcdir)/src \
678 -I$(top_builddir)/src \
679 -I$(top_builddir)/desktop-shell \
680 -DDATADIR='"$(datadir)"' \
681 -DMODULEDIR='"$(moduledir)"' \
682 -DLIBEXECDIR='"$(libexecdir)"' \
683 -DIN_WESTON
684
685desktop_shell_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800686desktop_shell_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800687desktop_shell_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
688desktop_shell_la_SOURCES = \
689 desktop-shell/shell.h \
690 desktop-shell/shell.c \
691 desktop-shell/exposay.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800692 desktop-shell/input-panel.c
693nodist_desktop_shell_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100694 protocol/desktop-shell-protocol.c \
695 protocol/desktop-shell-server-protocol.h \
696 protocol/xdg-shell-protocol.c \
697 protocol/xdg-shell-server-protocol.h
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800698
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800699BUILT_SOURCES += $(nodist_desktop_shell_la_SOURCES)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800700endif
701
Jason Ekstrand946a9482014-04-02 19:53:47 -0500702if ENABLE_FULLSCREEN_SHELL
703
704module_LTLIBRARIES += fullscreen-shell.la
705
706fullscreen_shell_la_CPPFLAGS = \
707 -I$(top_builddir)/protocol \
708 -I$(top_srcdir)/shared \
709 -I$(top_srcdir)/src \
710 -I$(top_builddir)/src \
711 -DIN_WESTON
712
713fullscreen_shell_la_LDFLAGS = -module -avoid-version
714fullscreen_shell_la_LIBADD = $(COMPOSITOR_LIBS)
715fullscreen_shell_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
716fullscreen_shell_la_SOURCES = \
717 fullscreen-shell/fullscreen-shell.c
718nodist_fullscreen_shell_la_SOURCES = \
719 protocol/fullscreen-shell-protocol.c \
720 protocol/fullscreen-shell-server-protocol.h
721
722BUILT_SOURCES += $(nodist_fullscreen_shell_la_SOURCES)
723endif
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800724
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900725if ENABLE_IVI_SHELL
726
727module_LTLIBRARIES += \
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900728 $(ivi_layout) \
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900729 $(ivi_shell) \
730 $(hmi_controller)
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900731
732ivi_layout = ivi-layout.la
733ivi_layout_la_LDFLAGS = -module -avoid-version
734ivi_layout_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
735ivi_layout_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
736ivi_layout_la_SOURCES = \
737 ivi-shell/ivi-layout-export.h \
738 ivi-shell/ivi-layout-private.h \
739 ivi-shell/ivi-layout.c \
740 ivi-shell/ivi-layout-transition.c
741
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900742ivi_shell = ivi-shell.la
743ivi_shell_la_LDFLAGS = -module -avoid-version
744ivi_shell_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
745ivi_shell_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
746ivi_shell_la_SOURCES = \
747 ivi-shell/ivi-shell.h \
748 ivi-shell/ivi-shell.c \
749 ivi-shell/ivi-layout-private.h
750nodist_ivi_shell_la_SOURCES = \
751 protocol/ivi-application-protocol.c \
752 protocol/ivi-application-server-protocol.h
753
754BUILT_SOURCES += $(nodist_ivi_shell_la_SOURCES)
755
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900756hmi_controller = hmi-controller.la
757hmi_controller_la_LDFLAGS = -module -avoid-version
758hmi_controller_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
759hmi_controller_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
760hmi_controller_la_SOURCES = \
761 ivi-shell/ivi-layout-export.h \
762 ivi-shell/hmi-controller.c
763nodist_hmi_controller_la_SOURCES = \
764 protocol/ivi-hmi-controller-protocol.c \
765 protocol/ivi-hmi-controller-server-protocol.h
766
767BUILT_SOURCES += $(nodist_hmi_controller_la_SOURCES)
768
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900769endif
770
771
Jason Ekstrand47928d82014-04-02 19:54:01 -0500772if ENABLE_SCREEN_SHARING
773
774module_LTLIBRARIES += screen-share.la
775
776screen_share_la_CPPFLAGS = $(AM_CPPFLAGS) -DBINDIR='"$(bindir)"'
777screen_share_la_LDFLAGS = -module -avoid-version
778screen_share_la_LIBADD = \
779 $(COMPOSITOR_LIBS) \
780 $(SCREEN_SHARE_LIBS) \
781 libshared-cairo.la
782screen_share_la_CFLAGS = \
783 $(COMPOSITOR_CFLAGS) \
784 $(SCREEN_SHARE_CFLAGS) \
785 $(GCC_CFLAGS)
786screen_share_la_SOURCES = \
787 src/screen-share.c
788nodist_screen_share_la_SOURCES = \
789 protocol/fullscreen-shell-protocol.c \
790 protocol/fullscreen-shell-client-protocol.h
791
792endif
793
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800794if ENABLE_XWAYLAND
795
796module_LTLIBRARIES += xwayland.la
797
798xwayland_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100799 -I$(top_builddir)/protocol \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800800 -I$(top_srcdir)/shared \
801 -I$(top_srcdir)/src \
802 -I$(top_builddir)/src \
803 -I$(top_builddir)/xwayland \
804 -DDATADIR='"$(datadir)"' \
805 -DMODULEDIR='"$(moduledir)"' \
806 -DLIBEXECDIR='"$(libexecdir)"' \
807 -DXSERVER_PATH='"@XSERVER_PATH@"'
808
809xwayland_la_LDFLAGS = -module -avoid-version
810xwayland_la_LIBADD = \
811 $(XWAYLAND_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800812 $(top_builddir)/libshared-cairo.la
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800813xwayland_la_CFLAGS = \
814 $(GCC_CFLAGS) \
815 $(COMPOSITOR_CFLAGS) \
816 $(PIXMAN_CFLAGS) \
817 $(CAIRO_CFLAGS)
818xwayland_la_SOURCES = \
819 xwayland/xwayland.h \
820 xwayland/window-manager.c \
821 xwayland/selection.c \
822 xwayland/dnd.c \
823 xwayland/launcher.c \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800824 xwayland/hash.c \
825 xwayland/hash.h
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800826endif
827
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -0800828
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800829#
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800830# Shared utilities
831#
832
833noinst_LTLIBRARIES += libshared.la libshared-cairo.la
834
835libshared_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
836
837libshared_la_SOURCES = \
838 shared/config-parser.c \
839 shared/option-parser.c \
840 shared/config-parser.h \
841 shared/os-compatibility.c \
842 shared/os-compatibility.h
843
844libshared_cairo_la_CFLAGS = \
845 -DDATADIR='"$(datadir)"' \
846 $(GCC_CFLAGS) \
847 $(COMPOSITOR_CFLAGS) \
848 $(PIXMAN_CFLAGS) \
849 $(CAIRO_CFLAGS) \
850 $(PNG_CFLAGS) \
851 $(WEBP_CFLAGS)
852
853libshared_cairo_la_LIBADD = \
854 $(PIXMAN_LIBS) \
855 $(CAIRO_LIBS) \
856 $(PNG_LIBS) \
857 $(WEBP_LIBS) \
858 $(JPEG_LIBS)
859
860libshared_cairo_la_SOURCES = \
861 $(libshared_la_SOURCES) \
862 shared/image-loader.c \
863 shared/image-loader.h \
864 shared/cairo-util.c \
865 shared/frame.c \
866 shared/cairo-util.h
867
868
869#
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800870# tests subdirectory
871#
872
873TESTS = $(shared_tests) $(module_tests) $(weston_tests)
874
875shared_tests = \
876 config-parser.test \
877 vertex-clip.test
878
879module_tests = \
880 surface-test.la \
881 surface-global-test.la
882
883weston_tests = \
884 bad_buffer.weston \
885 keyboard.weston \
886 event.weston \
887 button.weston \
888 text.weston \
Pekka Paalanende7f5c82014-09-23 22:08:48 -0400889 presentation.weston \
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +0300890 roles.weston \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800891 subsurface.weston
892
893
894AM_TESTS_ENVIRONMENT = \
895 abs_builddir='$(abs_builddir)'; export abs_builddir;
896
897TEST_EXTENSIONS = .la .weston
898LA_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
899WESTON_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
900
901clean-local:
Pekka Paalanen15f85632014-05-12 10:08:57 +0300902 -rm -rf logs
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800903
904# To remove when automake 1.11 support is dropped
905export abs_builddir
906
907noinst_LTLIBRARIES += \
908 weston-test.la \
909 $(module_tests) \
910 libtest-runner.la \
911 libtest-client.la
912
913noinst_PROGRAMS += \
914 $(setbacklight) \
915 $(shared_tests) \
916 $(weston_tests) \
917 matrix-test
918
919test_module_ldflags = \
920 -module -avoid-version -rpath $(libdir) $(COMPOSITOR_LIBS)
921
922surface_global_test_la_SOURCES = tests/surface-global-test.c
923surface_global_test_la_LDFLAGS = $(test_module_ldflags)
924surface_global_test_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
925
926surface_test_la_SOURCES = tests/surface-test.c
927surface_test_la_LDFLAGS = $(test_module_ldflags)
928surface_test_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
929
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800930weston_test_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800931weston_test_la_LDFLAGS = $(test_module_ldflags)
932weston_test_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800933weston_test_la_SOURCES = tests/weston-test.c
934nodist_weston_test_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100935 protocol/wayland-test-protocol.c \
936 protocol/wayland-test-server-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800937
938if ENABLE_EGL
939weston_test_la_CFLAGS += $(EGL_TESTS_CFLAGS)
940weston_test_la_LDFLAGS += $(EGL_TESTS_LIBS)
941endif
942
943libtest_runner_la_SOURCES = \
944 tests/weston-test-runner.c \
945 tests/weston-test-runner.h
946libtest_runner_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
947
948config_parser_test_SOURCES = tests/config-parser-test.c
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800949config_parser_test_LDADD = libshared.la libtest-runner.la $(COMPOSITOR_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800950
951vertex_clip_test_SOURCES = \
952 tests/vertex-clip-test.c \
953 src/vertex-clipping.c \
954 src/vertex-clipping.h
955vertex_clip_test_LDADD = libtest-runner.la -lm -lrt
956
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100957libtest_client_la_SOURCES = \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800958 tests/weston-test-client-helper.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800959 tests/weston-test-client-helper.h
960nodist_libtest_client_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100961 protocol/wayland-test-protocol.c \
962 protocol/wayland-test-client-protocol.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800963libtest_client_la_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800964libtest_client_la_LIBADD = $(TEST_CLIENT_LIBS) libshared.la libtest-runner.la
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800965
966bad_buffer_weston_SOURCES = tests/bad-buffer-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800967bad_buffer_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800968bad_buffer_weston_LDADD = libtest-client.la
969
970keyboard_weston_SOURCES = tests/keyboard-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800971keyboard_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800972keyboard_weston_LDADD = libtest-client.la
973
974event_weston_SOURCES = tests/event-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800975event_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800976event_weston_LDADD = libtest-client.la
977
978button_weston_SOURCES = tests/button-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800979button_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800980button_weston_LDADD = libtest-client.la
981
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800982text_weston_SOURCES = tests/text-test.c
983nodist_text_weston_SOURCES = \
984 protocol/text-protocol.c \
985 protocol/text-client-protocol.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800986text_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800987text_weston_LDADD = libtest-client.la
988
989subsurface_weston_SOURCES = tests/subsurface-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800990subsurface_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800991subsurface_weston_LDADD = libtest-client.la
992
Pekka Paalanende7f5c82014-09-23 22:08:48 -0400993presentation_weston_SOURCES = tests/presentation-test.c
994nodist_presentation_weston_SOURCES = \
995 protocol/presentation_timing-protocol.c \
996 protocol/presentation_timing-client-protocol.h
997presentation_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
998presentation_weston_LDADD = libtest-client.la
999
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +03001000roles_weston_SOURCES = tests/roles-test.c
1001roles_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1002roles_weston_LDADD = libtest-client.la
1003
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001004if ENABLE_EGL
1005weston_tests += buffer-count.weston
1006buffer_count_weston_SOURCES = tests/buffer-count-test.c
1007buffer_count_weston_CFLAGS = $(GCC_CFLAGS) $(EGL_TESTS_CFLAGS)
1008buffer_count_weston_LDADD = libtest-client.la $(EGL_TESTS_LIBS)
1009endif
1010
1011if ENABLE_XWAYLAND_TEST
Pekka Paalanenf9a26262014-05-07 16:26:29 +03001012weston_tests += xwayland-test.weston
1013xwayland_test_weston_SOURCES = tests/xwayland-test.c
1014xwayland_test_weston_CFLAGS = $(GCC_CFLAGS) $(XWAYLAND_TEST_CFLAGS)
1015xwayland_test_weston_LDADD = libtest-client.la $(XWAYLAND_TEST_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001016endif
1017
1018matrix_test_SOURCES = \
1019 tests/matrix-test.c \
1020 shared/matrix.c \
1021 shared/matrix.h
1022matrix_test_CPPFLAGS = -DUNIT_TEST
1023matrix_test_LDADD = -lm -lrt
1024
1025if BUILD_SETBACKLIGHT
1026noinst_PROGRAMS += setbacklight
1027setbacklight_SOURCES = \
1028 tests/setbacklight.c \
1029 src/libbacklight.c \
1030 src/libbacklight.h
1031setbacklight_CFLAGS = $(AM_CFLAGS) $(SETBACKLIGHT_CFLAGS)
1032setbacklight_LDADD = $(SETBACKLIGHT_LIBS)
1033endif
1034
1035EXTRA_DIST += tests/weston-tests-env
1036
1037BUILT_SOURCES += \
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001038 protocol/wayland-test-protocol.c \
1039 protocol/wayland-test-server-protocol.h \
1040 protocol/wayland-test-client-protocol.h \
1041 protocol/text-protocol.c \
1042 protocol/text-client-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001043
Kristian Høgsbergcd312752014-02-01 00:38:15 -08001044EXTRA_DIST += \
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001045 protocol/desktop-shell.xml \
1046 protocol/screenshooter.xml \
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001047 protocol/text.xml \
1048 protocol/input-method.xml \
1049 protocol/workspaces.xml \
1050 protocol/text-cursor-position.xml \
1051 protocol/wayland-test.xml \
1052 protocol/xdg-shell.xml \
Jason Ekstrand27e11672014-04-02 19:53:44 -05001053 protocol/fullscreen-shell.xml \
Pekka Paalanen7e62d252014-09-23 22:08:42 -04001054 protocol/presentation_timing.xml \
Nobuhiko Tanibatabff1b4a2014-11-27 13:21:34 +09001055 protocol/scaler.xml \
Nobuhiko Tanibata68cfabb2014-11-27 13:22:53 +09001056 protocol/ivi-application.xml \
1057 protocol/ivi-hmi-controller.xml
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001058
Kristian Høgsberg68c5c102014-01-27 22:33:04 -08001059man_MANS = weston.1 weston.ini.5
1060
1061if ENABLE_DRM_COMPOSITOR
1062man_MANS += weston-drm.7
1063endif
1064
1065MAN_SUBSTS = \
1066 -e 's|__weston_native_backend__|$(WESTON_NATIVE_BACKEND)|g' \
1067 -e 's|__weston_modules_dir__|$(pkglibdir)|g' \
1068 -e 's|__weston_shell_client__|$(WESTON_SHELL_CLIENT)|g' \
1069 -e 's|__version__|$(PACKAGE_VERSION)|g'
1070
1071SUFFIXES = .1 .5 .7 .man
1072
1073%.1 %.5 %.7 : man/%.man
1074 $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
1075
1076EXTRA_DIST += \
1077 man/weston.man \
1078 man/weston-drm.man \
1079 man/weston.ini.man
1080
1081CLEANFILES += $(man_MANS)
1082
1083
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001084protocol/%-protocol.c : $(top_srcdir)/protocol/%.xml
1085 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001086
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001087protocol/%-server-protocol.h : $(top_srcdir)/protocol/%.xml
1088 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001089
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001090protocol/%-client-protocol.h : $(top_srcdir)/protocol/%.xml
1091 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@