blob: 4f4bb28bb2c8d1e89a53ea1b8ebbcf66476642d4 [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
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090014EXTRA_DIST = weston.ini.in ivi-shell/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
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090023ivi-shell/weston.ini : $(srcdir)/ivi-shell/weston.ini.in
24 $(AM_V_GEN)$(SED) \
25 -e 's|@bindir[@]|$(bindir)|g' \
26 -e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
27 -e 's|@libexecdir[@]|$(libexecdir)|g' \
28 $< > $@
29
30all-local : weston.ini ivi-shell/weston.ini
Kristian Høgsberg98463742013-12-16 23:12:46 -080031
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080032AM_CFLAGS = $(GCC_CFLAGS)
33
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080034AM_CPPFLAGS = \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080035 -I$(top_srcdir)/src \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080036 -I$(top_builddir)/src \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -080037 -I$(top_builddir)/clients \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080038 -I$(top_builddir)/tests \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080039 -I$(top_srcdir)/shared \
Quentin Glidic088ba5e2014-02-01 21:39:12 +010040 -I$(top_builddir)/protocol \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080041 -DDATADIR='"$(datadir)"' \
42 -DMODULEDIR='"$(moduledir)"' \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -080043 -DLIBEXECDIR='"$(libexecdir)"' \
44 -DBINDIR='"$(bindir)"'
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080045
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090046CLEANFILES = weston.ini ivi-shell/weston.ini $(BUILT_SOURCES)
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -080047
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080048bin_PROGRAMS += weston
49
50weston_LDFLAGS = -export-dynamic
51weston_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON
52weston_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS) $(LIBUNWIND_CFLAGS)
53weston_LDADD = $(COMPOSITOR_LIBS) $(LIBUNWIND_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -080054 $(DLOPEN_LIBS) -lm libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080055
56weston_SOURCES = \
57 src/git-version.h \
58 src/log.c \
59 src/compositor.c \
60 src/compositor.h \
61 src/input.c \
62 src/data-device.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080063 src/screenshooter.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080064 src/clipboard.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080065 src/zoom.c \
66 src/text-backend.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080067 src/bindings.c \
68 src/animation.c \
69 src/noop-renderer.c \
70 src/pixman-renderer.c \
71 src/pixman-renderer.h \
72 shared/matrix.c \
73 shared/matrix.h \
74 shared/zalloc.h \
75 src/weston-egl-ext.h
76
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -080077nodist_weston_SOURCES = \
78 protocol/screenshooter-protocol.c \
79 protocol/screenshooter-server-protocol.h \
80 protocol/text-cursor-position-protocol.c \
81 protocol/text-cursor-position-server-protocol.h \
82 protocol/text-protocol.c \
83 protocol/text-server-protocol.h \
84 protocol/input-method-protocol.c \
85 protocol/input-method-server-protocol.h \
86 protocol/workspaces-protocol.c \
87 protocol/workspaces-server-protocol.h \
Pekka Paalanen7e62d252014-09-23 22:08:42 -040088 protocol/presentation_timing-protocol.c \
89 protocol/presentation_timing-server-protocol.h \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -080090 protocol/scaler-protocol.c \
91 protocol/scaler-server-protocol.h
92
93BUILT_SOURCES += $(nodist_weston_SOURCES)
94
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -080095# Track this dependency explicitly instead of using BUILT_SOURCES. We
96# add BUILT_SOURCES to CLEANFILES, but we want to keep git-version.h
97# in case we're building from tarballs.
98
99src/compositor.c : $(top_builddir)/src/git-version.h
100
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800101noinst_LTLIBRARIES += \
102 libsession-helper.la
103
104libsession_helper_la_SOURCES = \
105 src/weston-launch.h \
106 src/launcher-util.c \
107 src/launcher-util.h
108libsession_helper_la_CFLAGS = $(GCC_CFLAGS) $(LIBDRM_CFLAGS) $(PIXMAN_CFLAGS) $(COMPOSITOR_CFLAGS)
109libsession_helper_la_LIBADD = $(LIBDRM_LIBS)
110
111if ENABLE_DBUS
112if HAVE_SYSTEMD_LOGIN
113libsession_helper_la_SOURCES += \
114 src/dbus.h \
115 src/dbus.c \
116 src/logind-util.h \
117 src/logind-util.c
118libsession_helper_la_CFLAGS += $(SYSTEMD_LOGIN_CFLAGS) $(DBUS_CFLAGS)
119libsession_helper_la_LIBADD += $(SYSTEMD_LOGIN_LIBS) $(DBUS_LIBS)
120endif
121endif
122
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800123if HAVE_GIT_REPO
124src/git-version.h : $(top_srcdir)/.git/logs/HEAD
125 $(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 -0800126else
127src/git-version.h :
128 $(AM_V_GEN)echo "#define BUILD_ID \"unknown (not built from git or tarball)\"" > $@
129
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800130endif
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800131
132.FORCE :
133
134if BUILD_WESTON_LAUNCH
135bin_PROGRAMS += weston-launch
136weston_launch_SOURCES = src/weston-launch.c src/weston-launch.h
137weston_launch_CPPFLAGS = -DBINDIR='"$(bindir)"'
138weston_launch_CFLAGS= \
139 $(GCC_CFLAGS) \
140 $(PAM_CFLAGS) \
141 $(SYSTEMD_LOGIN_CFLAGS) \
142 $(LIBDRM_CFLAGS)
143weston_launch_LDADD = $(PAM_LIBS) $(SYSTEMD_LOGIN_LIBS) $(LIBDRM_LIBS)
144
145if ENABLE_SETUID_INSTALL
146install-exec-hook:
147 chown root $(DESTDIR)$(bindir)/weston-launch
148 chmod u+s $(DESTDIR)$(bindir)/weston-launch
149endif
150
151endif # BUILD_WESTON_LAUNCH
152
153pkgconfigdir = $(libdir)/pkgconfig
154pkgconfig_DATA = src/weston.pc
155
156westonincludedir = $(includedir)/weston
157westoninclude_HEADERS = \
158 src/version.h \
159 src/compositor.h \
160 shared/matrix.h \
161 shared/config-parser.h \
162 shared/zalloc.h
163
164if ENABLE_EGL
165module_LTLIBRARIES += gl-renderer.la
166gl_renderer_la_LDFLAGS = -module -avoid-version
167gl_renderer_la_LIBADD = $(COMPOSITOR_LIBS) $(EGL_LIBS)
168gl_renderer_la_CFLAGS = \
169 $(COMPOSITOR_CFLAGS) \
170 $(EGL_CFLAGS) \
171 $(GCC_CFLAGS)
172gl_renderer_la_SOURCES = \
173 src/gl-renderer.h \
174 src/gl-renderer.c \
175 src/vertex-clipping.c \
176 src/vertex-clipping.h
177endif
178
179if ENABLE_X11_COMPOSITOR
180module_LTLIBRARIES += x11-backend.la
181x11_backend_la_LDFLAGS = -module -avoid-version
182x11_backend_la_LIBADD = $(COMPOSITOR_LIBS) $(X11_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800183 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800184x11_backend_la_CFLAGS = \
185 $(COMPOSITOR_CFLAGS) \
186 $(EGL_CFLAGS) \
187 $(PIXMAN_CFLAGS) \
188 $(CAIRO_CFLAGS) \
189 $(X11_COMPOSITOR_CFLAGS) \
190 $(GCC_CFLAGS)
191x11_backend_la_SOURCES = src/compositor-x11.c
192endif
193
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100194INPUT_BACKEND_LIBS = $(LIBINPUT_BACKEND_LIBS)
Peter Hutterer823ad332014-11-26 07:06:31 +1000195INPUT_BACKEND_SOURCES = \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100196 src/libinput-seat.c \
197 src/libinput-seat.h \
198 src/libinput-device.c \
199 src/libinput-device.h
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100200
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800201if ENABLE_DRM_COMPOSITOR
202module_LTLIBRARIES += drm-backend.la
203drm_backend_la_LDFLAGS = -module -avoid-version
204drm_backend_la_LIBADD = \
205 $(COMPOSITOR_LIBS) \
206 $(DRM_COMPOSITOR_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100207 $(INPUT_BACKEND_LIBS) \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100208 libshared.la -lrt \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800209 libsession-helper.la
210drm_backend_la_CFLAGS = \
211 $(COMPOSITOR_CFLAGS) \
212 $(EGL_CFLAGS) \
213 $(DRM_COMPOSITOR_CFLAGS) \
214 $(GCC_CFLAGS)
215drm_backend_la_SOURCES = \
216 src/compositor-drm.c \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100217 $(INPUT_BACKEND_SOURCES) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800218 src/libbacklight.c \
219 src/libbacklight.h
220
221if ENABLE_VAAPI_RECORDER
222drm_backend_la_SOURCES += src/vaapi-recorder.c src/vaapi-recorder.h
223drm_backend_la_LIBADD += $(LIBVA_LIBS)
224drm_backend_la_CFLAGS += $(LIBVA_CFLAGS)
225endif
226endif
227
228if ENABLE_WAYLAND_COMPOSITOR
229module_LTLIBRARIES += wayland-backend.la
230wayland_backend_la_LDFLAGS = -module -avoid-version
231wayland_backend_la_LIBADD = \
232 $(COMPOSITOR_LIBS) \
233 $(WAYLAND_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800234 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800235wayland_backend_la_CFLAGS = \
236 $(COMPOSITOR_CFLAGS) \
237 $(EGL_CFLAGS) \
238 $(PIXMAN_CFLAGS) \
239 $(CAIRO_CFLAGS) \
240 $(WAYLAND_COMPOSITOR_CFLAGS) \
241 $(GCC_CFLAGS)
242wayland_backend_la_SOURCES = src/compositor-wayland.c
Jason Ekstrand53ee0dc2014-04-02 19:53:54 -0500243nodist_wayland_backend_la_SOURCES = \
244 protocol/fullscreen-shell-protocol.c \
245 protocol/fullscreen-shell-client-protocol.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800246endif
247
248if ENABLE_RPI_COMPOSITOR
249if INSTALL_RPI_COMPOSITOR
250module_LTLIBRARIES += rpi-backend.la
251else
252noinst_LTLIBRARIES += rpi-backend.la
253endif
254
255rpi_backend_la_LDFLAGS = -module -avoid-version
256rpi_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
257 $(RPI_COMPOSITOR_LIBS) \
258 $(RPI_BCM_HOST_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100259 $(INPUT_BACKEND_LIBS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800260 libsession-helper.la \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800261 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800262rpi_backend_la_CFLAGS = \
263 $(GCC_CFLAGS) \
264 $(COMPOSITOR_CFLAGS) \
265 $(RPI_COMPOSITOR_CFLAGS) \
266 $(RPI_BCM_HOST_CFLAGS)
267rpi_backend_la_SOURCES = \
268 src/compositor-rpi.c \
269 src/rpi-renderer.c \
270 src/rpi-renderer.h \
271 src/rpi-bcm-stubs.h \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100272 $(INPUT_BACKEND_SOURCES)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800273
274if ENABLE_EGL
275rpi_backend_la_LIBADD += $(EGL_LIBS)
276rpi_backend_la_CFLAGS += $(EGL_CFLAGS)
277endif
278
279endif
280
281if ENABLE_HEADLESS_COMPOSITOR
282module_LTLIBRARIES += headless-backend.la
283headless_backend_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800284headless_backend_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
285headless_backend_la_CFLAGS = $(COMPOSITOR_CFLAGS) $(GCC_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800286headless_backend_la_SOURCES = src/compositor-headless.c
287endif
288
289if ENABLE_FBDEV_COMPOSITOR
290module_LTLIBRARIES += fbdev-backend.la
291fbdev_backend_la_LDFLAGS = -module -avoid-version
292fbdev_backend_la_LIBADD = \
293 $(COMPOSITOR_LIBS) \
294 $(FBDEV_COMPOSITOR_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100295 $(INPUT_BACKEND_LIBS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800296 libsession-helper.la \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800297 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800298fbdev_backend_la_CFLAGS = \
299 $(COMPOSITOR_CFLAGS) \
300 $(EGL_CFLAGS) \
301 $(FBDEV_COMPOSITOR_CFLAGS) \
302 $(PIXMAN_CFLAGS) \
303 $(GCC_CFLAGS)
304fbdev_backend_la_SOURCES = \
305 src/compositor-fbdev.c \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100306 $(INPUT_BACKEND_SOURCES)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800307endif
308
309if ENABLE_RDP_COMPOSITOR
310module_LTLIBRARIES += rdp-backend.la
311rdp_backend_la_LDFLAGS = -module -avoid-version
312rdp_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
313 $(RDP_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800314 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800315rdp_backend_la_CFLAGS = \
316 $(COMPOSITOR_CFLAGS) \
317 $(RDP_COMPOSITOR_CFLAGS) \
318 $(GCC_CFLAGS)
319rdp_backend_la_SOURCES = src/compositor-rdp.c
320endif
321
322if HAVE_LCMS
323module_LTLIBRARIES += cms-static.la
324cms_static_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800325cms_static_la_LIBADD = $(COMPOSITOR_LIBS) $(LCMS_LIBS) libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800326cms_static_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS) $(LCMS_CFLAGS)
327cms_static_la_SOURCES = \
328 src/cms-static.c \
329 src/cms-helper.c \
330 src/cms-helper.h
331if ENABLE_COLORD
332module_LTLIBRARIES += cms-colord.la
333cms_colord_la_LDFLAGS = -module -avoid-version
334cms_colord_la_LIBADD = $(COMPOSITOR_LIBS) $(COLORD_LIBS)
335cms_colord_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS) $(COLORD_CFLAGS)
336cms_colord_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100337 src/cms-colord.c \
338 src/cms-helper.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800339 src/cms-helper.h
340endif
341endif
342
343noinst_PROGRAMS += spring-tool
344spring_tool_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
345spring_tool_LDADD = $(COMPOSITOR_LIBS) -lm
346spring_tool_SOURCES = \
347 src/spring-tool.c \
348 src/animation.c \
349 shared/matrix.c \
350 shared/matrix.h \
351 src/compositor.h
352
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800353if BUILD_CLIENTS
354
355bin_PROGRAMS += weston-terminal weston-info
356
357libexec_PROGRAMS += \
358 weston-desktop-shell \
359 weston-screenshooter \
360 weston-keyboard \
361 weston-simple-im
362
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900363if ENABLE_IVI_SHELL
364libexec_PROGRAMS += \
365 weston-ivi-shell-user-interface
366endif
367
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800368demo_clients = \
369 weston-flower \
370 weston-image \
371 weston-cliptest \
372 weston-dnd \
373 weston-smoke \
374 weston-resizor \
375 weston-eventdemo \
376 weston-clickdot \
377 weston-transformed \
378 weston-fullscreen \
379 weston-stacking \
380 weston-calibrator \
381 weston-scaler
382
383if INSTALL_DEMO_CLIENTS
384bin_PROGRAMS += $(demo_clients)
385else
386noinst_PROGRAMS += $(demo_clients)
387endif
388
389
390if BUILD_SIMPLE_CLIENTS
391demo_clients += \
392 weston-simple-shm \
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500393 weston-simple-damage \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800394 weston-simple-touch \
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400395 weston-presentation-shm \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800396 weston-multi-resource
397
Kristian Høgsbergfe84a972014-02-11 14:23:19 -0800398weston_simple_shm_SOURCES = clients/simple-shm.c
399nodist_weston_simple_shm_SOURCES = \
Kristian Høgsbergdfaf65b2014-02-07 17:01:57 -0800400 protocol/xdg-shell-protocol.c \
Jason Ekstrand428c24e2014-04-02 19:53:48 -0500401 protocol/xdg-shell-client-protocol.h \
402 protocol/fullscreen-shell-protocol.c \
Nobuhiko Tanibatafba4ea32014-11-27 13:24:29 +0900403 protocol/fullscreen-shell-client-protocol.h \
404 protocol/ivi-application-protocol.c \
405 protocol/ivi-application-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800406weston_simple_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800407weston_simple_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800408
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500409weston_simple_damage_SOURCES = clients/simple-damage.c
410nodist_weston_simple_damage_SOURCES = \
411 protocol/scaler-protocol.c \
412 protocol/scaler-client-protocol.h \
413 protocol/xdg-shell-protocol.c \
414 protocol/xdg-shell-client-protocol.h \
415 protocol/fullscreen-shell-protocol.c \
416 protocol/fullscreen-shell-client-protocol.h
417weston_simple_damage_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
418weston_simple_damage_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
419
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800420weston_simple_touch_SOURCES = clients/simple-touch.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800421weston_simple_touch_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800422weston_simple_touch_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800423
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400424weston_presentation_shm_SOURCES = clients/presentation-shm.c
425nodist_weston_presentation_shm_SOURCES = \
426 protocol/presentation_timing-protocol.c \
427 protocol/presentation_timing-client-protocol.h
428weston_presentation_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
429weston_presentation_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la -lm
430
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800431weston_multi_resource_SOURCES = clients/multi-resource.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800432weston_multi_resource_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Javier Jardónc47931e2014-10-27 15:13:19 +0000433weston_multi_resource_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la -lrt -lm
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800434endif
435
436if BUILD_SIMPLE_EGL_CLIENTS
437demo_clients += weston-simple-egl
Kristian Høgsbergfe84a972014-02-11 14:23:19 -0800438weston_simple_egl_SOURCES = clients/simple-egl.c
439nodist_weston_simple_egl_SOURCES = \
Kristian Høgsbergdfaf65b2014-02-07 17:01:57 -0800440 protocol/xdg-shell-protocol.c \
Nobuhiko Tanibata4f01a0b2014-11-27 13:24:42 +0900441 protocol/xdg-shell-client-protocol.h \
442 protocol/ivi-application-protocol.c \
443 protocol/ivi-application-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800444weston_simple_egl_CFLAGS = $(AM_CFLAGS) $(SIMPLE_EGL_CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800445weston_simple_egl_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
446endif
447
448noinst_LTLIBRARIES += libtoytoolkit.la
449
450libtoytoolkit_la_SOURCES = \
451 clients/window.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800452 clients/window.h
453
454nodist_libtoytoolkit_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100455 protocol/text-cursor-position-protocol.c \
456 protocol/text-cursor-position-client-protocol.h \
457 protocol/scaler-protocol.c \
458 protocol/scaler-client-protocol.h \
459 protocol/workspaces-protocol.c \
460 protocol/workspaces-client-protocol.h \
Pekka Paalanen7e62d252014-09-23 22:08:42 -0400461 protocol/presentation_timing-protocol.c \
462 protocol/presentation_timing-client-protocol.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100463 protocol/xdg-shell-protocol.c \
Nobuhiko Tanibatabff1b4a2014-11-27 13:21:34 +0900464 protocol/xdg-shell-client-protocol.h \
465 protocol/ivi-application-protocol.c \
466 protocol/ivi-application-client-protocol.h
Jasper St. Pierre0790e392013-12-09 14:58:00 -0500467
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800468BUILT_SOURCES += $(nodist_libtoytoolkit_la_SOURCES)
469
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800470
471libtoytoolkit_la_LIBADD = \
472 $(CLIENT_LIBS) \
473 $(CAIRO_EGL_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800474 libshared-cairo.la -lrt -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800475libtoytoolkit_la_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(CAIRO_EGL_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800476
477weston_flower_SOURCES = clients/flower.c
478weston_flower_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800479weston_flower_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800480
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100481weston_screenshooter_SOURCES = \
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800482 clients/screenshot.c
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800483nodist_weston_screenshooter_SOURCES = \
484 protocol/screenshooter-protocol.c \
485 protocol/screenshooter-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800486weston_screenshooter_LDADD = $(CLIENT_LIBS) libshared.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800487weston_screenshooter_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800488
489weston_terminal_SOURCES = clients/terminal.c
490weston_terminal_LDADD = libtoytoolkit.la -lutil
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800491weston_terminal_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800492
493weston_image_SOURCES = clients/image.c
494weston_image_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800495weston_image_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800496
Pekka Paalanen461e93c2014-08-20 11:58:47 +0300497weston_cliptest_SOURCES = \
498 clients/cliptest.c \
499 src/vertex-clipping.c \
500 src/vertex-clipping.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800501weston_cliptest_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800502weston_cliptest_LDADD = libtoytoolkit.la
503
504weston_dnd_SOURCES = clients/dnd.c
505weston_dnd_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800506weston_dnd_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800507
508weston_smoke_SOURCES = clients/smoke.c
509weston_smoke_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800510weston_smoke_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800511
512weston_resizor_SOURCES = clients/resizor.c
513weston_resizor_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800514weston_resizor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800515
516weston_scaler_SOURCES = clients/scaler.c
517weston_scaler_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800518weston_scaler_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800519
520if HAVE_CAIRO_GLESV2
521demo_clients += weston-nested weston-nested-client
522
523weston_nested_SOURCES = clients/nested.c
524weston_nested_LDADD = libtoytoolkit.la $(SERVER_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800525weston_nested_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800526
527weston_nested_client_SOURCES = clients/nested-client.c
528weston_nested_client_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800529weston_nested_client_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800530endif
531
532weston_eventdemo_SOURCES = clients/eventdemo.c
533weston_eventdemo_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800534weston_eventdemo_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800535
536weston_clickdot_SOURCES = clients/clickdot.c
537weston_clickdot_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800538weston_clickdot_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800539
540weston_transformed_SOURCES = clients/transformed.c
541weston_transformed_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800542weston_transformed_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800543
544weston_fullscreen_SOURCES = clients/fullscreen.c
Jason Ekstrand2bb72fe2014-04-02 19:53:52 -0500545nodist_weston_fullscreen_SOURCES = \
546 protocol/fullscreen-shell-protocol.c \
547 protocol/fullscreen-shell-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800548weston_fullscreen_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800549weston_fullscreen_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800550
551weston_stacking_SOURCES = clients/stacking.c
552weston_stacking_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800553weston_stacking_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800554
555weston_calibrator_SOURCES = clients/calibrator.c \
556 shared/matrix.c \
557 shared/matrix.h
558weston_calibrator_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800559weston_calibrator_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800560
561if BUILD_SUBSURFACES_CLIENT
562demo_clients += weston-subsurfaces
563weston_subsurfaces_SOURCES = clients/subsurfaces.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800564weston_subsurfaces_CFLAGS = \
565 $(AM_CFLAGS) \
566 $(SIMPLE_EGL_CLIENT_CFLAGS) \
567 $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800568weston_subsurfaces_LDADD = libtoytoolkit.la $(SIMPLE_EGL_CLIENT_LIBS) -lm
569endif
570
571if HAVE_PANGO
572demo_clients += weston-editor
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800573weston_editor_SOURCES = clients/editor.c
574nodist_weston_editor_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100575 protocol/text-protocol.c \
576 protocol/text-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800577weston_editor_LDADD = libtoytoolkit.la $(PANGO_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800578weston_editor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(PANGO_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800579endif
580
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800581weston_keyboard_SOURCES = clients/keyboard.c
582nodist_weston_keyboard_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100583 protocol/desktop-shell-client-protocol.h \
584 protocol/desktop-shell-protocol.c \
585 protocol/input-method-protocol.c \
586 protocol/input-method-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800587weston_keyboard_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800588weston_keyboard_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800589
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800590weston_simple_im_SOURCES = clients/weston-simple-im.c
591nodist_weston_simple_im_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100592 protocol/input-method-protocol.c \
593 protocol/input-method-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800594weston_simple_im_LDADD = $(CLIENT_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800595weston_simple_im_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800596
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800597weston_info_SOURCES = clients/weston-info.c
Pekka Paalanen93a6afd2014-09-23 22:08:44 -0400598nodist_weston_info_SOURCES = \
599 protocol/presentation_timing-protocol.c \
600 protocol/presentation_timing-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800601weston_info_LDADD = $(WESTON_INFO_LIBS) libshared.la
Pekka Paalanen5124b532014-02-03 13:12:34 +0200602weston_info_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800603
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800604weston_desktop_shell_SOURCES = clients/desktop-shell.c
605nodist_weston_desktop_shell_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100606 protocol/desktop-shell-client-protocol.h \
607 protocol/desktop-shell-protocol.c
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800608weston_desktop_shell_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800609weston_desktop_shell_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800610
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900611if ENABLE_IVI_SHELL
612weston_ivi_shell_user_interface_SOURCES = clients/ivi-shell-user-interface.c
613nodist_weston_ivi_shell_user_interface_SOURCES = \
614 protocol/ivi-hmi-controller-client-protocol.h \
615 protocol/ivi-hmi-controller-protocol.c \
616 protocol/ivi-application-client-protocol.h \
617 protocol/ivi-application-protocol.c
618weston_ivi_shell_user_interface_LDADD = libtoytoolkit.la
619weston_ivi_shell_user_interface_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
620endif
621
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800622if BUILD_FULL_GL_CLIENTS
623demo_clients += weston-gears
624weston_gears_SOURCES = clients/gears.c
625weston_gears_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800626weston_gears_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800627
628if HAVE_GLU
629libexec_PROGRAMS += weston-screensaver
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100630weston_screensaver_SOURCES = \
631 clients/wscreensaver.c \
632 clients/wscreensaver.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100633 clients/wscreensaver-glue.c \
634 clients/wscreensaver-glue.h \
635 clients/glmatrix.c \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800636 clients/matrix3.xpm
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800637nodist_weston_screensaver_SOURCES = \
638 protocol/desktop-shell-client-protocol.h \
639 protocol/desktop-shell-protocol.c
640
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800641weston_screensaver_LDADD = libtoytoolkit.la $(GLU_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800642weston_screensaver_CFLAGS = $(AM_CFLAGS) $(GLU_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800643
644endif
645
646endif
647
648endif
649
650BUILT_SOURCES += \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100651 protocol/screenshooter-protocol.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800652 protocol/screenshooter-client-protocol.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100653 protocol/text-cursor-position-client-protocol.h \
654 protocol/text-cursor-position-protocol.c \
655 protocol/text-protocol.c \
656 protocol/text-client-protocol.h \
657 protocol/input-method-protocol.c \
658 protocol/input-method-client-protocol.h \
659 protocol/desktop-shell-client-protocol.h \
660 protocol/desktop-shell-protocol.c \
661 protocol/scaler-client-protocol.h \
662 protocol/scaler-protocol.c \
663 protocol/workspaces-client-protocol.h \
664 protocol/workspaces-protocol.c \
Jason Ekstrand428c24e2014-04-02 19:53:48 -0500665 protocol/fullscreen-shell-protocol.c \
666 protocol/fullscreen-shell-client-protocol.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100667 protocol/xdg-shell-protocol.c \
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900668 protocol/xdg-shell-client-protocol.h \
669 protocol/ivi-hmi-controller-protocol.c \
670 protocol/ivi-hmi-controller-client-protocol.h \
671 protocol/ivi-application-protocol.c \
672 protocol/ivi-application-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800673
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -0800674westondatadir = $(datadir)/weston
675dist_westondata_DATA = \
676 data/wayland.svg \
677 data/wayland.png \
678 data/pattern.png \
679 data/terminal.png \
680 data/border.png \
681 data/icon_window.png \
682 data/sign_close.png \
683 data/sign_maximize.png \
Nobuhiko Tanibata001a5432014-03-11 11:54:45 +0900684 data/sign_minimize.png \
685 data/background.png \
686 data/tiling.png \
687 data/fullscreen.png \
688 data/panel.png \
689 data/random.png \
690 data/sidebyside.png \
691 data/home.png \
692 data/icon_ivi_clickdot.png \
693 data/icon_ivi_flower.png \
694 data/icon_ivi_simple-egl.png \
695 data/icon_ivi_simple-shm.png \
696 data/icon_ivi_smoke.png
Kristian Høgsberge895f142014-01-27 21:46:30 -0800697
698
699if BUILD_WCAP_TOOLS
700bin_PROGRAMS += wcap-decode
701
702wcap_decode_SOURCES = \
703 wcap/main.c \
704 wcap/wcap-decode.c \
705 wcap/wcap-decode.h
706
707wcap_decode_CFLAGS = $(GCC_CFLAGS) $(WCAP_CFLAGS)
708wcap_decode_LDADD = $(WCAP_LIBS)
709endif
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800710
711
712if ENABLE_DESKTOP_SHELL
713
714module_LTLIBRARIES += desktop-shell.la
715
716desktop_shell_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100717 -I$(top_builddir)/protocol \
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800718 -I$(top_srcdir)/shared \
719 -I$(top_srcdir)/src \
720 -I$(top_builddir)/src \
721 -I$(top_builddir)/desktop-shell \
722 -DDATADIR='"$(datadir)"' \
723 -DMODULEDIR='"$(moduledir)"' \
724 -DLIBEXECDIR='"$(libexecdir)"' \
725 -DIN_WESTON
726
727desktop_shell_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800728desktop_shell_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800729desktop_shell_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
730desktop_shell_la_SOURCES = \
731 desktop-shell/shell.h \
732 desktop-shell/shell.c \
733 desktop-shell/exposay.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800734 desktop-shell/input-panel.c
735nodist_desktop_shell_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100736 protocol/desktop-shell-protocol.c \
737 protocol/desktop-shell-server-protocol.h \
738 protocol/xdg-shell-protocol.c \
739 protocol/xdg-shell-server-protocol.h
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800740
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800741BUILT_SOURCES += $(nodist_desktop_shell_la_SOURCES)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800742endif
743
Jason Ekstrand946a9482014-04-02 19:53:47 -0500744if ENABLE_FULLSCREEN_SHELL
745
746module_LTLIBRARIES += fullscreen-shell.la
747
748fullscreen_shell_la_CPPFLAGS = \
749 -I$(top_builddir)/protocol \
750 -I$(top_srcdir)/shared \
751 -I$(top_srcdir)/src \
752 -I$(top_builddir)/src \
753 -DIN_WESTON
754
755fullscreen_shell_la_LDFLAGS = -module -avoid-version
756fullscreen_shell_la_LIBADD = $(COMPOSITOR_LIBS)
757fullscreen_shell_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
758fullscreen_shell_la_SOURCES = \
759 fullscreen-shell/fullscreen-shell.c
760nodist_fullscreen_shell_la_SOURCES = \
761 protocol/fullscreen-shell-protocol.c \
762 protocol/fullscreen-shell-server-protocol.h
763
764BUILT_SOURCES += $(nodist_fullscreen_shell_la_SOURCES)
765endif
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800766
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900767if ENABLE_IVI_SHELL
768
769module_LTLIBRARIES += \
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900770 $(ivi_layout) \
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900771 $(ivi_shell) \
772 $(hmi_controller)
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900773
774ivi_layout = ivi-layout.la
775ivi_layout_la_LDFLAGS = -module -avoid-version
776ivi_layout_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
777ivi_layout_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
778ivi_layout_la_SOURCES = \
779 ivi-shell/ivi-layout-export.h \
780 ivi-shell/ivi-layout-private.h \
781 ivi-shell/ivi-layout.c \
782 ivi-shell/ivi-layout-transition.c
783
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900784ivi_shell = ivi-shell.la
785ivi_shell_la_LDFLAGS = -module -avoid-version
786ivi_shell_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
787ivi_shell_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
788ivi_shell_la_SOURCES = \
789 ivi-shell/ivi-shell.h \
790 ivi-shell/ivi-shell.c \
Nobuhiko Tanibata0038b732014-11-27 13:25:34 +0900791 ivi-shell/ivi-layout-private.h \
792 ivi-shell/input-panel-ivi.c
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900793nodist_ivi_shell_la_SOURCES = \
794 protocol/ivi-application-protocol.c \
795 protocol/ivi-application-server-protocol.h
796
797BUILT_SOURCES += $(nodist_ivi_shell_la_SOURCES)
798
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900799hmi_controller = hmi-controller.la
800hmi_controller_la_LDFLAGS = -module -avoid-version
801hmi_controller_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
802hmi_controller_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
803hmi_controller_la_SOURCES = \
804 ivi-shell/ivi-layout-export.h \
805 ivi-shell/hmi-controller.c
806nodist_hmi_controller_la_SOURCES = \
807 protocol/ivi-hmi-controller-protocol.c \
808 protocol/ivi-hmi-controller-server-protocol.h
809
810BUILT_SOURCES += $(nodist_hmi_controller_la_SOURCES)
811
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900812endif
813
814
Jason Ekstrand47928d82014-04-02 19:54:01 -0500815if ENABLE_SCREEN_SHARING
816
817module_LTLIBRARIES += screen-share.la
818
819screen_share_la_CPPFLAGS = $(AM_CPPFLAGS) -DBINDIR='"$(bindir)"'
820screen_share_la_LDFLAGS = -module -avoid-version
821screen_share_la_LIBADD = \
822 $(COMPOSITOR_LIBS) \
823 $(SCREEN_SHARE_LIBS) \
824 libshared-cairo.la
825screen_share_la_CFLAGS = \
826 $(COMPOSITOR_CFLAGS) \
827 $(SCREEN_SHARE_CFLAGS) \
828 $(GCC_CFLAGS)
829screen_share_la_SOURCES = \
830 src/screen-share.c
831nodist_screen_share_la_SOURCES = \
832 protocol/fullscreen-shell-protocol.c \
833 protocol/fullscreen-shell-client-protocol.h
834
835endif
836
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800837if ENABLE_XWAYLAND
838
839module_LTLIBRARIES += xwayland.la
840
841xwayland_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100842 -I$(top_builddir)/protocol \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800843 -I$(top_srcdir)/shared \
844 -I$(top_srcdir)/src \
845 -I$(top_builddir)/src \
846 -I$(top_builddir)/xwayland \
847 -DDATADIR='"$(datadir)"' \
848 -DMODULEDIR='"$(moduledir)"' \
849 -DLIBEXECDIR='"$(libexecdir)"' \
850 -DXSERVER_PATH='"@XSERVER_PATH@"'
851
852xwayland_la_LDFLAGS = -module -avoid-version
853xwayland_la_LIBADD = \
854 $(XWAYLAND_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800855 $(top_builddir)/libshared-cairo.la
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800856xwayland_la_CFLAGS = \
857 $(GCC_CFLAGS) \
858 $(COMPOSITOR_CFLAGS) \
859 $(PIXMAN_CFLAGS) \
860 $(CAIRO_CFLAGS)
861xwayland_la_SOURCES = \
862 xwayland/xwayland.h \
863 xwayland/window-manager.c \
864 xwayland/selection.c \
865 xwayland/dnd.c \
866 xwayland/launcher.c \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800867 xwayland/hash.c \
868 xwayland/hash.h
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800869endif
870
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -0800871
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800872#
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800873# Shared utilities
874#
875
876noinst_LTLIBRARIES += libshared.la libshared-cairo.la
877
878libshared_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
879
880libshared_la_SOURCES = \
881 shared/config-parser.c \
882 shared/option-parser.c \
883 shared/config-parser.h \
884 shared/os-compatibility.c \
885 shared/os-compatibility.h
886
887libshared_cairo_la_CFLAGS = \
888 -DDATADIR='"$(datadir)"' \
889 $(GCC_CFLAGS) \
890 $(COMPOSITOR_CFLAGS) \
891 $(PIXMAN_CFLAGS) \
892 $(CAIRO_CFLAGS) \
893 $(PNG_CFLAGS) \
894 $(WEBP_CFLAGS)
895
896libshared_cairo_la_LIBADD = \
897 $(PIXMAN_LIBS) \
898 $(CAIRO_LIBS) \
899 $(PNG_LIBS) \
900 $(WEBP_LIBS) \
901 $(JPEG_LIBS)
902
903libshared_cairo_la_SOURCES = \
904 $(libshared_la_SOURCES) \
905 shared/image-loader.c \
906 shared/image-loader.h \
907 shared/cairo-util.c \
908 shared/frame.c \
909 shared/cairo-util.h
910
911
912#
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800913# tests subdirectory
914#
915
916TESTS = $(shared_tests) $(module_tests) $(weston_tests)
917
918shared_tests = \
919 config-parser.test \
920 vertex-clip.test
921
922module_tests = \
923 surface-test.la \
924 surface-global-test.la
925
926weston_tests = \
927 bad_buffer.weston \
928 keyboard.weston \
929 event.weston \
930 button.weston \
931 text.weston \
Pekka Paalanende7f5c82014-09-23 22:08:48 -0400932 presentation.weston \
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +0300933 roles.weston \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800934 subsurface.weston
935
936
937AM_TESTS_ENVIRONMENT = \
938 abs_builddir='$(abs_builddir)'; export abs_builddir;
939
940TEST_EXTENSIONS = .la .weston
941LA_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
942WESTON_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
943
944clean-local:
Pekka Paalanen15f85632014-05-12 10:08:57 +0300945 -rm -rf logs
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800946
947# To remove when automake 1.11 support is dropped
948export abs_builddir
949
950noinst_LTLIBRARIES += \
951 weston-test.la \
952 $(module_tests) \
953 libtest-runner.la \
954 libtest-client.la
955
956noinst_PROGRAMS += \
957 $(setbacklight) \
958 $(shared_tests) \
959 $(weston_tests) \
960 matrix-test
961
962test_module_ldflags = \
963 -module -avoid-version -rpath $(libdir) $(COMPOSITOR_LIBS)
964
965surface_global_test_la_SOURCES = tests/surface-global-test.c
966surface_global_test_la_LDFLAGS = $(test_module_ldflags)
967surface_global_test_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
968
969surface_test_la_SOURCES = tests/surface-test.c
970surface_test_la_LDFLAGS = $(test_module_ldflags)
971surface_test_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
972
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800973weston_test_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800974weston_test_la_LDFLAGS = $(test_module_ldflags)
975weston_test_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800976weston_test_la_SOURCES = tests/weston-test.c
977nodist_weston_test_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100978 protocol/wayland-test-protocol.c \
979 protocol/wayland-test-server-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800980
981if ENABLE_EGL
982weston_test_la_CFLAGS += $(EGL_TESTS_CFLAGS)
983weston_test_la_LDFLAGS += $(EGL_TESTS_LIBS)
984endif
985
986libtest_runner_la_SOURCES = \
987 tests/weston-test-runner.c \
988 tests/weston-test-runner.h
989libtest_runner_la_CFLAGS = $(GCC_CFLAGS) $(COMPOSITOR_CFLAGS)
990
991config_parser_test_SOURCES = tests/config-parser-test.c
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800992config_parser_test_LDADD = libshared.la libtest-runner.la $(COMPOSITOR_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800993
994vertex_clip_test_SOURCES = \
995 tests/vertex-clip-test.c \
996 src/vertex-clipping.c \
997 src/vertex-clipping.h
998vertex_clip_test_LDADD = libtest-runner.la -lm -lrt
999
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001000libtest_client_la_SOURCES = \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001001 tests/weston-test-client-helper.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001002 tests/weston-test-client-helper.h
1003nodist_libtest_client_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001004 protocol/wayland-test-protocol.c \
1005 protocol/wayland-test-client-protocol.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001006libtest_client_la_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001007libtest_client_la_LIBADD = $(TEST_CLIENT_LIBS) libshared.la libtest-runner.la
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001008
1009bad_buffer_weston_SOURCES = tests/bad-buffer-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001010bad_buffer_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001011bad_buffer_weston_LDADD = libtest-client.la
1012
1013keyboard_weston_SOURCES = tests/keyboard-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001014keyboard_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001015keyboard_weston_LDADD = libtest-client.la
1016
1017event_weston_SOURCES = tests/event-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001018event_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001019event_weston_LDADD = libtest-client.la
1020
1021button_weston_SOURCES = tests/button-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001022button_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001023button_weston_LDADD = libtest-client.la
1024
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001025text_weston_SOURCES = tests/text-test.c
1026nodist_text_weston_SOURCES = \
1027 protocol/text-protocol.c \
1028 protocol/text-client-protocol.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001029text_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001030text_weston_LDADD = libtest-client.la
1031
1032subsurface_weston_SOURCES = tests/subsurface-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001033subsurface_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001034subsurface_weston_LDADD = libtest-client.la
1035
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001036presentation_weston_SOURCES = tests/presentation-test.c
1037nodist_presentation_weston_SOURCES = \
1038 protocol/presentation_timing-protocol.c \
1039 protocol/presentation_timing-client-protocol.h
1040presentation_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1041presentation_weston_LDADD = libtest-client.la
1042
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +03001043roles_weston_SOURCES = tests/roles-test.c
1044roles_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1045roles_weston_LDADD = libtest-client.la
1046
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001047if ENABLE_EGL
1048weston_tests += buffer-count.weston
1049buffer_count_weston_SOURCES = tests/buffer-count-test.c
1050buffer_count_weston_CFLAGS = $(GCC_CFLAGS) $(EGL_TESTS_CFLAGS)
1051buffer_count_weston_LDADD = libtest-client.la $(EGL_TESTS_LIBS)
1052endif
1053
1054if ENABLE_XWAYLAND_TEST
Pekka Paalanenf9a26262014-05-07 16:26:29 +03001055weston_tests += xwayland-test.weston
1056xwayland_test_weston_SOURCES = tests/xwayland-test.c
1057xwayland_test_weston_CFLAGS = $(GCC_CFLAGS) $(XWAYLAND_TEST_CFLAGS)
1058xwayland_test_weston_LDADD = libtest-client.la $(XWAYLAND_TEST_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001059endif
1060
1061matrix_test_SOURCES = \
1062 tests/matrix-test.c \
1063 shared/matrix.c \
1064 shared/matrix.h
1065matrix_test_CPPFLAGS = -DUNIT_TEST
1066matrix_test_LDADD = -lm -lrt
1067
1068if BUILD_SETBACKLIGHT
1069noinst_PROGRAMS += setbacklight
1070setbacklight_SOURCES = \
1071 tests/setbacklight.c \
1072 src/libbacklight.c \
1073 src/libbacklight.h
1074setbacklight_CFLAGS = $(AM_CFLAGS) $(SETBACKLIGHT_CFLAGS)
1075setbacklight_LDADD = $(SETBACKLIGHT_LIBS)
1076endif
1077
1078EXTRA_DIST += tests/weston-tests-env
1079
1080BUILT_SOURCES += \
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001081 protocol/wayland-test-protocol.c \
1082 protocol/wayland-test-server-protocol.h \
1083 protocol/wayland-test-client-protocol.h \
1084 protocol/text-protocol.c \
1085 protocol/text-client-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001086
Kristian Høgsbergcd312752014-02-01 00:38:15 -08001087EXTRA_DIST += \
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001088 protocol/desktop-shell.xml \
1089 protocol/screenshooter.xml \
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001090 protocol/text.xml \
1091 protocol/input-method.xml \
1092 protocol/workspaces.xml \
1093 protocol/text-cursor-position.xml \
1094 protocol/wayland-test.xml \
1095 protocol/xdg-shell.xml \
Jason Ekstrand27e11672014-04-02 19:53:44 -05001096 protocol/fullscreen-shell.xml \
Pekka Paalanen7e62d252014-09-23 22:08:42 -04001097 protocol/presentation_timing.xml \
Nobuhiko Tanibatabff1b4a2014-11-27 13:21:34 +09001098 protocol/scaler.xml \
Nobuhiko Tanibata68cfabb2014-11-27 13:22:53 +09001099 protocol/ivi-application.xml \
1100 protocol/ivi-hmi-controller.xml
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001101
Kristian Høgsberg68c5c102014-01-27 22:33:04 -08001102man_MANS = weston.1 weston.ini.5
1103
1104if ENABLE_DRM_COMPOSITOR
1105man_MANS += weston-drm.7
1106endif
1107
1108MAN_SUBSTS = \
1109 -e 's|__weston_native_backend__|$(WESTON_NATIVE_BACKEND)|g' \
1110 -e 's|__weston_modules_dir__|$(pkglibdir)|g' \
1111 -e 's|__weston_shell_client__|$(WESTON_SHELL_CLIENT)|g' \
1112 -e 's|__version__|$(PACKAGE_VERSION)|g'
1113
1114SUFFIXES = .1 .5 .7 .man
1115
1116%.1 %.5 %.7 : man/%.man
1117 $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
1118
1119EXTRA_DIST += \
1120 man/weston.man \
1121 man/weston-drm.man \
1122 man/weston.ini.man
1123
1124CLEANFILES += $(man_MANS)
1125
1126
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001127protocol/%-protocol.c : $(top_srcdir)/protocol/%.xml
1128 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001129
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001130protocol/%-server-protocol.h : $(top_srcdir)/protocol/%.xml
1131 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001132
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001133protocol/%-client-protocol.h : $(top_srcdir)/protocol/%.xml
1134 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@