blob: 1eb66aeb2bdebb33b381f12aff8a31f55f81efe7 [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
Derek Foreman2ef9e812015-02-09 09:57:29 -060011AM_DISTCHECK_CONFIGURE_FLAGS = --disable-setuid-install
Kristian Høgsberg24639cc2013-02-25 13:03:15 -050012
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090013EXTRA_DIST = weston.ini.in ivi-shell/weston.ini.in
Neil Robertse3de16e2013-11-22 16:46:00 +000014
15weston.ini : $(srcdir)/weston.ini.in
16 $(AM_V_GEN)$(SED) \
17 -e 's|@bindir[@]|$(bindir)|g' \
18 -e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
19 -e 's|@libexecdir[@]|$(libexecdir)|g' \
20 $< > $@
21
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090022ivi-shell/weston.ini : $(srcdir)/ivi-shell/weston.ini.in
Ross Burton2eff22b2015-07-17 12:33:45 +010023 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(SED) \
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090024 -e 's|@bindir[@]|$(bindir)|g' \
25 -e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
Pekka Paalanen8cb25872015-03-24 14:09:57 +020026 -e 's|@abs_top_srcdir[@]|$(abs_top_srcdir)|g' \
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090027 -e 's|@libexecdir[@]|$(libexecdir)|g' \
Pekka Paalanenf3a34532015-03-24 13:51:05 +020028 -e 's|@plugin_prefix[@]||g' \
29 $< > $@
30
31tests/weston-ivi.ini : $(srcdir)/ivi-shell/weston.ini.in
Ross Burton2eff22b2015-07-17 12:33:45 +010032 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(SED) \
Pekka Paalanenf3a34532015-03-24 13:51:05 +020033 -e 's|@bindir[@]|$(bindir)|g' \
34 -e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
Pekka Paalanen8cb25872015-03-24 14:09:57 +020035 -e 's|@abs_top_srcdir[@]|$(abs_top_srcdir)|g' \
Derek Foremanbbdd9bc2015-06-16 13:30:35 -050036 -e 's|@libexecdir[@]|$(abs_builddir)|g' \
Pekka Paalanenf3a34532015-03-24 13:51:05 +020037 -e 's|@plugin_prefix[@]|$(abs_top_builddir)/.libs/|g' \
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090038 $< > $@
39
40all-local : weston.ini ivi-shell/weston.ini
Kristian Høgsberg98463742013-12-16 23:12:46 -080041
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080042AM_CFLAGS = $(GCC_CFLAGS)
43
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080044AM_CPPFLAGS = \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080045 -I$(top_srcdir)/src \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080046 -I$(top_builddir)/src \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -080047 -I$(top_builddir)/clients \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080048 -I$(top_builddir)/tests \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080049 -I$(top_srcdir)/shared \
Quentin Glidic088ba5e2014-02-01 21:39:12 +010050 -I$(top_builddir)/protocol \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080051 -DDATADIR='"$(datadir)"' \
52 -DMODULEDIR='"$(moduledir)"' \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -080053 -DLIBEXECDIR='"$(libexecdir)"' \
54 -DBINDIR='"$(bindir)"'
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080055
Pekka Paalanenf3a34532015-03-24 13:51:05 +020056CLEANFILES = weston.ini \
57 ivi-shell/weston.ini \
58 tests/weston-ivi.ini \
Derek Foreman1ce2ef52015-05-26 10:21:03 -050059 internal-screenshot-00.png \
Pekka Paalanenf3a34532015-03-24 13:51:05 +020060 $(BUILT_SOURCES)
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -080061
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080062bin_PROGRAMS += weston
63
64weston_LDFLAGS = -export-dynamic
65weston_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON
Derek Foreman4ff38742015-06-18 11:43:11 -050066weston_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(LIBUNWIND_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080067weston_LDADD = $(COMPOSITOR_LIBS) $(LIBUNWIND_LIBS) \
Derek Foremane2926942015-06-29 14:05:38 -050068 $(DLOPEN_LIBS) -lm -lrt libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080069
70weston_SOURCES = \
71 src/git-version.h \
72 src/log.c \
73 src/compositor.c \
74 src/compositor.h \
75 src/input.c \
76 src/data-device.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080077 src/screenshooter.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080078 src/clipboard.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080079 src/zoom.c \
80 src/text-backend.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080081 src/bindings.c \
82 src/animation.c \
83 src/noop-renderer.c \
84 src/pixman-renderer.c \
85 src/pixman-renderer.h \
Pekka Paalanenb5026542014-11-12 15:09:24 +020086 src/timeline.c \
87 src/timeline.h \
88 src/timeline-object.h \
Giulio Camuffobab996e2014-10-12 00:24:25 +030089 src/main.c \
Pekka Paalanen230f3b12014-09-29 14:18:40 -040090 src/linux-dmabuf.c \
91 src/linux-dmabuf.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -070092 shared/helpers.h \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080093 shared/matrix.c \
94 shared/matrix.h \
Pekka Paalanenaa21f622015-07-03 15:44:50 +030095 shared/timespec-util.h \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080096 shared/zalloc.h \
Jonny Lamb51a7ae52015-03-20 15:26:51 +010097 shared/platform.h \
Egor Starkov94fd9a52015-09-29 14:50:41 +030098 src/weston-egl-ext.h
Egor Starkov7ce2e972015-09-25 18:00:27 +030099
100if SYSTEMD_NOTIFY_SUPPORT
101module_LTLIBRARIES += systemd-notify.la
102systemd_notify_la_LDFLAGS = -module -avoid-version
103systemd_notify_la_LIBADD = $(SYSTEMD_DAEMON_LIBS)
104systemd_notify_la_CFLAGS = \
105 $(SYSTEMD_DAEMON_LIBS) \
106 $(PIXMAN_CFLAGS) \
107 $(AM_CFLAGS)
108systemd_notify_la_SOURCES = \
109 src/systemd-notify.c \
Egor Starkov7ce2e972015-09-25 18:00:27 +0300110 shared/helpers.h \
111 shared/zalloc.h \
Bryce Harringtona0dd5b42015-09-25 15:16:25 -0700112 src/compositor.h
Egor Starkov7ce2e972015-09-25 18:00:27 +0300113endif
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800114
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800115nodist_weston_SOURCES = \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800116 protocol/weston-screenshooter-protocol.c \
117 protocol/weston-screenshooter-server-protocol.h \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800118 protocol/text-cursor-position-protocol.c \
119 protocol/text-cursor-position-server-protocol.h \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800120 protocol/text-input-unstable-v1-protocol.c \
121 protocol/text-input-unstable-v1-server-protocol.h \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800122 protocol/input-method-unstable-v1-protocol.c \
123 protocol/input-method-unstable-v1-server-protocol.h \
Pekka Paalanen7e62d252014-09-23 22:08:42 -0400124 protocol/presentation_timing-protocol.c \
125 protocol/presentation_timing-server-protocol.h \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800126 protocol/scaler-protocol.c \
Pekka Paalanen23ab7152014-09-29 14:08:29 -0400127 protocol/scaler-server-protocol.h \
Jonas Ådahl57e48f02015-11-17 16:00:28 +0800128 protocol/linux-dmabuf-unstable-v1-protocol.c \
129 protocol/linux-dmabuf-unstable-v1-server-protocol.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800130
131BUILT_SOURCES += $(nodist_weston_SOURCES)
132
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800133# Track this dependency explicitly instead of using BUILT_SOURCES. We
134# add BUILT_SOURCES to CLEANFILES, but we want to keep git-version.h
135# in case we're building from tarballs.
136
137src/compositor.c : $(top_builddir)/src/git-version.h
138
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800139noinst_LTLIBRARIES += \
140 libsession-helper.la
141
142libsession_helper_la_SOURCES = \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800143 src/launcher-util.c \
Jasper St. Pierre72dea062015-09-23 10:46:47 -0700144 src/launcher-util.h \
Derek Foremancb156202015-09-24 09:26:48 -0500145 src/launcher-impl.h \
Jasper St. Pierre72dea062015-09-23 10:46:47 -0700146 src/weston-launch.h \
147 src/launcher-weston-launch.c \
148 src/launcher-direct.c
Derek Foreman4ff38742015-06-18 11:43:11 -0500149libsession_helper_la_CFLAGS = $(AM_CFLAGS) $(LIBDRM_CFLAGS) $(PIXMAN_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800150libsession_helper_la_LIBADD = $(LIBDRM_LIBS)
151
152if ENABLE_DBUS
153if HAVE_SYSTEMD_LOGIN
154libsession_helper_la_SOURCES += \
155 src/dbus.h \
156 src/dbus.c \
Jasper St. Pierre30bcf352015-09-23 10:46:46 -0700157 src/launcher-logind.c
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800158libsession_helper_la_CFLAGS += $(SYSTEMD_LOGIN_CFLAGS) $(DBUS_CFLAGS)
159libsession_helper_la_LIBADD += $(SYSTEMD_LOGIN_LIBS) $(DBUS_LIBS)
160endif
161endif
162
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800163if HAVE_GIT_REPO
164src/git-version.h : $(top_srcdir)/.git/logs/HEAD
165 $(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 -0800166else
167src/git-version.h :
168 $(AM_V_GEN)echo "#define BUILD_ID \"unknown (not built from git or tarball)\"" > $@
169
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800170endif
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800171
172.FORCE :
173
174if BUILD_WESTON_LAUNCH
175bin_PROGRAMS += weston-launch
176weston_launch_SOURCES = src/weston-launch.c src/weston-launch.h
177weston_launch_CPPFLAGS = -DBINDIR='"$(bindir)"'
178weston_launch_CFLAGS= \
Derek Foreman4ff38742015-06-18 11:43:11 -0500179 $(AM_CFLAGS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800180 $(PAM_CFLAGS) \
181 $(SYSTEMD_LOGIN_CFLAGS) \
182 $(LIBDRM_CFLAGS)
183weston_launch_LDADD = $(PAM_LIBS) $(SYSTEMD_LOGIN_LIBS) $(LIBDRM_LIBS)
184
185if ENABLE_SETUID_INSTALL
186install-exec-hook:
Jon A. Cruz90f23ca2015-04-09 17:52:56 -0700187 can_suid_files=no; \
188 chown root $(DESTDIR)$(bindir)/weston-launch \
189 && chmod u+s $(DESTDIR)$(bindir)/weston-launch \
190 && can_suid_files=yes;\
Derek Foreman6d116792015-04-10 11:55:27 -0500191 if test $$can_suid_files = no; then \
Jon A. Cruz90f23ca2015-04-09 17:52:56 -0700192 echo 'Error: unable to unable to change ownership/setuid on weston-launch.'; \
193 echo 'To skip this step, re-run ./configure using --disable-setuid-install'; \
194 false; \
195 fi
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800196endif
197
198endif # BUILD_WESTON_LAUNCH
199
200pkgconfigdir = $(libdir)/pkgconfig
201pkgconfig_DATA = src/weston.pc
202
Lubomir Rintel4f4b47a2014-12-28 14:20:49 +0100203wayland_sessiondir = $(datadir)/wayland-sessions
Ross Burton315476f2015-07-16 20:56:32 +0100204dist_wayland_session_DATA = src/weston.desktop
Lubomir Rintel4f4b47a2014-12-28 14:20:49 +0100205
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800206westonincludedir = $(includedir)/weston
207westoninclude_HEADERS = \
208 src/version.h \
209 src/compositor.h \
Pekka Paalanenb5026542014-11-12 15:09:24 +0200210 src/timeline-object.h \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800211 shared/matrix.h \
212 shared/config-parser.h \
Jonny Lamb51a7ae52015-03-20 15:26:51 +0100213 shared/zalloc.h \
214 shared/platform.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800215
Ucan, Emre \(ADITG/SW1\)ae2541d2015-10-15 14:51:43 +0000216if ENABLE_IVI_SHELL
217westoninclude_HEADERS += \
218 ivi-shell/ivi-layout-export.h
219endif
220
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800221if ENABLE_EGL
222module_LTLIBRARIES += gl-renderer.la
223gl_renderer_la_LDFLAGS = -module -avoid-version
224gl_renderer_la_LIBADD = $(COMPOSITOR_LIBS) $(EGL_LIBS)
225gl_renderer_la_CFLAGS = \
226 $(COMPOSITOR_CFLAGS) \
227 $(EGL_CFLAGS) \
Pekka Paalanena3525802014-06-12 16:49:29 +0300228 $(GL_RENDERER_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500229 $(AM_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800230gl_renderer_la_SOURCES = \
231 src/gl-renderer.h \
232 src/gl-renderer.c \
233 src/vertex-clipping.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700234 src/vertex-clipping.h \
235 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800236endif
237
238if ENABLE_X11_COMPOSITOR
239module_LTLIBRARIES += x11-backend.la
240x11_backend_la_LDFLAGS = -module -avoid-version
241x11_backend_la_LIBADD = $(COMPOSITOR_LIBS) $(X11_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800242 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800243x11_backend_la_CFLAGS = \
244 $(COMPOSITOR_CFLAGS) \
245 $(EGL_CFLAGS) \
246 $(PIXMAN_CFLAGS) \
247 $(CAIRO_CFLAGS) \
248 $(X11_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500249 $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700250x11_backend_la_SOURCES = \
251 src/compositor-x11.c \
252 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800253endif
254
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100255INPUT_BACKEND_LIBS = $(LIBINPUT_BACKEND_LIBS)
Peter Hutterer823ad332014-11-26 07:06:31 +1000256INPUT_BACKEND_SOURCES = \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100257 src/libinput-seat.c \
258 src/libinput-seat.h \
259 src/libinput-device.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700260 src/libinput-device.h \
261 shared/helpers.h
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100262
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800263if ENABLE_DRM_COMPOSITOR
264module_LTLIBRARIES += drm-backend.la
265drm_backend_la_LDFLAGS = -module -avoid-version
266drm_backend_la_LIBADD = \
267 $(COMPOSITOR_LIBS) \
268 $(DRM_COMPOSITOR_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100269 $(INPUT_BACKEND_LIBS) \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100270 libshared.la -lrt \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800271 libsession-helper.la
272drm_backend_la_CFLAGS = \
273 $(COMPOSITOR_CFLAGS) \
274 $(EGL_CFLAGS) \
275 $(DRM_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500276 $(AM_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800277drm_backend_la_SOURCES = \
278 src/compositor-drm.c \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100279 $(INPUT_BACKEND_SOURCES) \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700280 shared/helpers.h \
Mario Kleinerf507ec32015-06-21 21:25:14 +0200281 shared/timespec-util.h \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800282 src/libbacklight.c \
283 src/libbacklight.h
284
285if ENABLE_VAAPI_RECORDER
286drm_backend_la_SOURCES += src/vaapi-recorder.c src/vaapi-recorder.h
287drm_backend_la_LIBADD += $(LIBVA_LIBS)
288drm_backend_la_CFLAGS += $(LIBVA_CFLAGS)
289endif
290endif
291
292if ENABLE_WAYLAND_COMPOSITOR
293module_LTLIBRARIES += wayland-backend.la
294wayland_backend_la_LDFLAGS = -module -avoid-version
295wayland_backend_la_LIBADD = \
296 $(COMPOSITOR_LIBS) \
297 $(WAYLAND_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800298 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800299wayland_backend_la_CFLAGS = \
300 $(COMPOSITOR_CFLAGS) \
301 $(EGL_CFLAGS) \
302 $(PIXMAN_CFLAGS) \
303 $(CAIRO_CFLAGS) \
304 $(WAYLAND_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500305 $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700306wayland_backend_la_SOURCES = \
307 src/compositor-wayland.c \
308 shared/helpers.h
Jason Ekstrand53ee0dc2014-04-02 19:53:54 -0500309nodist_wayland_backend_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800310 protocol/fullscreen-shell-unstable-v1-protocol.c \
311 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800312endif
313
314if ENABLE_RPI_COMPOSITOR
315if INSTALL_RPI_COMPOSITOR
316module_LTLIBRARIES += rpi-backend.la
317else
318noinst_LTLIBRARIES += rpi-backend.la
319endif
320
321rpi_backend_la_LDFLAGS = -module -avoid-version
322rpi_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
323 $(RPI_COMPOSITOR_LIBS) \
324 $(RPI_BCM_HOST_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100325 $(INPUT_BACKEND_LIBS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800326 libsession-helper.la \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800327 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800328rpi_backend_la_CFLAGS = \
Derek Foreman4ff38742015-06-18 11:43:11 -0500329 $(AM_CFLAGS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800330 $(COMPOSITOR_CFLAGS) \
331 $(RPI_COMPOSITOR_CFLAGS) \
332 $(RPI_BCM_HOST_CFLAGS)
333rpi_backend_la_SOURCES = \
334 src/compositor-rpi.c \
335 src/rpi-renderer.c \
336 src/rpi-renderer.h \
337 src/rpi-bcm-stubs.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700338 shared/helpers.h \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100339 $(INPUT_BACKEND_SOURCES)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800340
341if ENABLE_EGL
342rpi_backend_la_LIBADD += $(EGL_LIBS)
343rpi_backend_la_CFLAGS += $(EGL_CFLAGS)
344endif
345
346endif
347
348if ENABLE_HEADLESS_COMPOSITOR
349module_LTLIBRARIES += headless-backend.la
350headless_backend_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800351headless_backend_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500352headless_backend_la_CFLAGS = $(COMPOSITOR_CFLAGS) $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700353headless_backend_la_SOURCES = \
354 src/compositor-headless.c \
355 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800356endif
357
358if ENABLE_FBDEV_COMPOSITOR
359module_LTLIBRARIES += fbdev-backend.la
360fbdev_backend_la_LDFLAGS = -module -avoid-version
361fbdev_backend_la_LIBADD = \
362 $(COMPOSITOR_LIBS) \
363 $(FBDEV_COMPOSITOR_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100364 $(INPUT_BACKEND_LIBS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800365 libsession-helper.la \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800366 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800367fbdev_backend_la_CFLAGS = \
368 $(COMPOSITOR_CFLAGS) \
369 $(EGL_CFLAGS) \
370 $(FBDEV_COMPOSITOR_CFLAGS) \
371 $(PIXMAN_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500372 $(AM_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800373fbdev_backend_la_SOURCES = \
374 src/compositor-fbdev.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700375 shared/helpers.h \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100376 $(INPUT_BACKEND_SOURCES)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800377endif
378
379if ENABLE_RDP_COMPOSITOR
380module_LTLIBRARIES += rdp-backend.la
381rdp_backend_la_LDFLAGS = -module -avoid-version
382rdp_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
383 $(RDP_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800384 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800385rdp_backend_la_CFLAGS = \
386 $(COMPOSITOR_CFLAGS) \
387 $(RDP_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500388 $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700389rdp_backend_la_SOURCES = \
390 src/compositor-rdp.c \
391 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800392endif
393
394if HAVE_LCMS
395module_LTLIBRARIES += cms-static.la
396cms_static_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800397cms_static_la_LIBADD = $(COMPOSITOR_LIBS) $(LCMS_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500398cms_static_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(LCMS_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800399cms_static_la_SOURCES = \
400 src/cms-static.c \
401 src/cms-helper.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700402 src/cms-helper.h \
403 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800404if ENABLE_COLORD
405module_LTLIBRARIES += cms-colord.la
406cms_colord_la_LDFLAGS = -module -avoid-version
407cms_colord_la_LIBADD = $(COMPOSITOR_LIBS) $(COLORD_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500408cms_colord_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(COLORD_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800409cms_colord_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100410 src/cms-colord.c \
411 src/cms-helper.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700412 src/cms-helper.h \
413 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800414endif
415endif
416
417noinst_PROGRAMS += spring-tool
Derek Foreman4ff38742015-06-18 11:43:11 -0500418spring_tool_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800419spring_tool_LDADD = $(COMPOSITOR_LIBS) -lm
420spring_tool_SOURCES = \
421 src/spring-tool.c \
422 src/animation.c \
423 shared/matrix.c \
424 shared/matrix.h \
425 src/compositor.h
426
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800427if BUILD_CLIENTS
428
429bin_PROGRAMS += weston-terminal weston-info
430
431libexec_PROGRAMS += \
432 weston-desktop-shell \
433 weston-screenshooter \
434 weston-keyboard \
435 weston-simple-im
436
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900437if ENABLE_IVI_SHELL
438libexec_PROGRAMS += \
439 weston-ivi-shell-user-interface
440endif
441
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800442demo_clients = \
443 weston-flower \
444 weston-image \
445 weston-cliptest \
446 weston-dnd \
447 weston-smoke \
448 weston-resizor \
449 weston-eventdemo \
450 weston-clickdot \
451 weston-transformed \
452 weston-fullscreen \
453 weston-stacking \
454 weston-calibrator \
455 weston-scaler
456
457if INSTALL_DEMO_CLIENTS
458bin_PROGRAMS += $(demo_clients)
459else
460noinst_PROGRAMS += $(demo_clients)
461endif
462
463
464if BUILD_SIMPLE_CLIENTS
465demo_clients += \
466 weston-simple-shm \
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500467 weston-simple-damage \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800468 weston-simple-touch \
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400469 weston-presentation-shm \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800470 weston-multi-resource
471
Kristian Høgsbergfe84a972014-02-11 14:23:19 -0800472weston_simple_shm_SOURCES = clients/simple-shm.c
473nodist_weston_simple_shm_SOURCES = \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800474 protocol/xdg-shell-unstable-v5-protocol.c \
475 protocol/xdg-shell-unstable-v5-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800476 protocol/fullscreen-shell-unstable-v1-protocol.c \
477 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Nobuhiko Tanibatafba4ea32014-11-27 13:24:29 +0900478 protocol/ivi-application-protocol.c \
479 protocol/ivi-application-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800480weston_simple_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800481weston_simple_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800482
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500483weston_simple_damage_SOURCES = clients/simple-damage.c
484nodist_weston_simple_damage_SOURCES = \
485 protocol/scaler-protocol.c \
486 protocol/scaler-client-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800487 protocol/xdg-shell-unstable-v5-protocol.c \
488 protocol/xdg-shell-unstable-v5-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800489 protocol/fullscreen-shell-unstable-v1-protocol.c \
490 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500491weston_simple_damage_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
492weston_simple_damage_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
493
Jon A. Cruzb09da242015-06-16 13:15:13 -0700494weston_simple_touch_SOURCES = \
495 clients/simple-touch.c \
496 shared/helpers.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800497weston_simple_touch_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800498weston_simple_touch_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800499
Jon A. Cruzb09da242015-06-16 13:15:13 -0700500weston_presentation_shm_SOURCES = \
501 clients/presentation-shm.c \
502 shared/helpers.h
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400503nodist_weston_presentation_shm_SOURCES = \
504 protocol/presentation_timing-protocol.c \
505 protocol/presentation_timing-client-protocol.h
506weston_presentation_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Derek Foremane2926942015-06-29 14:05:38 -0500507weston_presentation_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la -lm -lrt
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400508
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800509weston_multi_resource_SOURCES = clients/multi-resource.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800510weston_multi_resource_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Javier Jardónc47931e2014-10-27 15:13:19 +0000511weston_multi_resource_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la -lrt -lm
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800512endif
513
514if BUILD_SIMPLE_EGL_CLIENTS
515demo_clients += weston-simple-egl
Kristian Høgsbergfe84a972014-02-11 14:23:19 -0800516weston_simple_egl_SOURCES = clients/simple-egl.c
517nodist_weston_simple_egl_SOURCES = \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800518 protocol/xdg-shell-unstable-v5-protocol.c \
519 protocol/xdg-shell-unstable-v5-client-protocol.h \
Nobuhiko Tanibata4f01a0b2014-11-27 13:24:42 +0900520 protocol/ivi-application-protocol.c \
521 protocol/ivi-application-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800522weston_simple_egl_CFLAGS = $(AM_CFLAGS) $(SIMPLE_EGL_CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800523weston_simple_egl_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
524endif
525
Emmanuel Gil Peyrot3b65b0b2016-01-11 19:04:36 +0000526if BUILD_SIMPLE_DMABUF_INTEL_CLIENT
527demo_clients += weston-simple-dmabuf-intel
528weston_simple_dmabuf_intel_SOURCES = clients/simple-dmabuf-intel.c
529nodist_weston_simple_dmabuf_intel_SOURCES = \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800530 protocol/xdg-shell-unstable-v5-protocol.c \
531 protocol/xdg-shell-unstable-v5-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800532 protocol/fullscreen-shell-unstable-v1-protocol.c \
533 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Jonas Ådahl57e48f02015-11-17 16:00:28 +0800534 protocol/linux-dmabuf-unstable-v1-protocol.c \
535 protocol/linux-dmabuf-unstable-v1-client-protocol.h
Emmanuel Gil Peyrot3b65b0b2016-01-11 19:04:36 +0000536weston_simple_dmabuf_intel_CFLAGS = $(AM_CFLAGS) $(SIMPLE_DMABUF_INTEL_CLIENT_CFLAGS)
537weston_simple_dmabuf_intel_LDADD = $(SIMPLE_DMABUF_INTEL_CLIENT_LIBS) libshared.la
Jonas Ådahl57e48f02015-11-17 16:00:28 +0800538BUILT_SOURCES += protocol/linux-dmabuf-unstable-v1-client-protocol.h
George Kiagiadakis53868982014-06-12 16:26:49 +0200539endif
540
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800541noinst_LTLIBRARIES += libtoytoolkit.la
542
543libtoytoolkit_la_SOURCES = \
544 clients/window.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700545 clients/window.h \
546 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800547
548nodist_libtoytoolkit_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100549 protocol/text-cursor-position-protocol.c \
550 protocol/text-cursor-position-client-protocol.h \
551 protocol/scaler-protocol.c \
552 protocol/scaler-client-protocol.h \
Pekka Paalanen7e62d252014-09-23 22:08:42 -0400553 protocol/presentation_timing-protocol.c \
554 protocol/presentation_timing-client-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800555 protocol/xdg-shell-unstable-v5-protocol.c \
556 protocol/xdg-shell-unstable-v5-client-protocol.h \
Nobuhiko Tanibatabff1b4a2014-11-27 13:21:34 +0900557 protocol/ivi-application-protocol.c \
558 protocol/ivi-application-client-protocol.h
Jasper St. Pierre0790e392013-12-09 14:58:00 -0500559
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800560BUILT_SOURCES += $(nodist_libtoytoolkit_la_SOURCES)
561
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800562
563libtoytoolkit_la_LIBADD = \
564 $(CLIENT_LIBS) \
565 $(CAIRO_EGL_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800566 libshared-cairo.la -lrt -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800567libtoytoolkit_la_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(CAIRO_EGL_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800568
569weston_flower_SOURCES = clients/flower.c
570weston_flower_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800571weston_flower_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800572
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100573weston_screenshooter_SOURCES = \
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800574 clients/screenshot.c
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800575nodist_weston_screenshooter_SOURCES = \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800576 protocol/weston-screenshooter-protocol.c \
577 protocol/weston-screenshooter-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800578weston_screenshooter_LDADD = $(CLIENT_LIBS) libshared.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800579weston_screenshooter_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800580
Jon A. Cruzb09da242015-06-16 13:15:13 -0700581weston_terminal_SOURCES = \
582 clients/terminal.c \
583 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800584weston_terminal_LDADD = libtoytoolkit.la -lutil
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800585weston_terminal_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800586
587weston_image_SOURCES = clients/image.c
588weston_image_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800589weston_image_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800590
Pekka Paalanen461e93c2014-08-20 11:58:47 +0300591weston_cliptest_SOURCES = \
592 clients/cliptest.c \
593 src/vertex-clipping.c \
594 src/vertex-clipping.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800595weston_cliptest_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800596weston_cliptest_LDADD = libtoytoolkit.la
597
Jon A. Cruzb09da242015-06-16 13:15:13 -0700598weston_dnd_SOURCES = \
599 clients/dnd.c \
600 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800601weston_dnd_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800602weston_dnd_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800603
604weston_smoke_SOURCES = clients/smoke.c
605weston_smoke_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800606weston_smoke_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800607
608weston_resizor_SOURCES = clients/resizor.c
609weston_resizor_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800610weston_resizor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800611
612weston_scaler_SOURCES = clients/scaler.c
613weston_scaler_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800614weston_scaler_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800615
616if HAVE_CAIRO_GLESV2
617demo_clients += weston-nested weston-nested-client
618
Jon A. Cruzb09da242015-06-16 13:15:13 -0700619weston_nested_SOURCES = \
620 clients/nested.c \
621 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800622weston_nested_LDADD = libtoytoolkit.la $(SERVER_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800623weston_nested_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800624
625weston_nested_client_SOURCES = clients/nested-client.c
626weston_nested_client_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800627weston_nested_client_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800628endif
629
Jon A. Cruzb09da242015-06-16 13:15:13 -0700630weston_eventdemo_SOURCES = \
631 clients/eventdemo.c \
632 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800633weston_eventdemo_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800634weston_eventdemo_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800635
Jon A. Cruzb09da242015-06-16 13:15:13 -0700636weston_clickdot_SOURCES = \
637 clients/clickdot.c \
638 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800639weston_clickdot_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800640weston_clickdot_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800641
642weston_transformed_SOURCES = clients/transformed.c
643weston_transformed_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800644weston_transformed_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800645
646weston_fullscreen_SOURCES = clients/fullscreen.c
Jason Ekstrand2bb72fe2014-04-02 19:53:52 -0500647nodist_weston_fullscreen_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800648 protocol/fullscreen-shell-unstable-v1-protocol.c \
649 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800650weston_fullscreen_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800651weston_fullscreen_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800652
Jon A. Cruzb09da242015-06-16 13:15:13 -0700653weston_stacking_SOURCES = \
654 clients/stacking.c \
655 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800656weston_stacking_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800657weston_stacking_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800658
Jon A. Cruzb09da242015-06-16 13:15:13 -0700659weston_calibrator_SOURCES = \
660 clients/calibrator.c \
661 shared/helpers.h \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800662 shared/matrix.c \
663 shared/matrix.h
664weston_calibrator_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800665weston_calibrator_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800666
667if BUILD_SUBSURFACES_CLIENT
668demo_clients += weston-subsurfaces
Jon A. Cruzb09da242015-06-16 13:15:13 -0700669weston_subsurfaces_SOURCES = \
670 clients/subsurfaces.c \
671 shared/helpers.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800672weston_subsurfaces_CFLAGS = \
673 $(AM_CFLAGS) \
674 $(SIMPLE_EGL_CLIENT_CFLAGS) \
675 $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800676weston_subsurfaces_LDADD = libtoytoolkit.la $(SIMPLE_EGL_CLIENT_LIBS) -lm
677endif
678
679if HAVE_PANGO
680demo_clients += weston-editor
Jon A. Cruzb09da242015-06-16 13:15:13 -0700681weston_editor_SOURCES = \
682 clients/editor.c \
683 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800684nodist_weston_editor_SOURCES = \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800685 protocol/text-input-unstable-v1-protocol.c \
686 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800687weston_editor_LDADD = libtoytoolkit.la $(PANGO_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800688weston_editor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(PANGO_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800689endif
690
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800691weston_keyboard_SOURCES = clients/keyboard.c
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800692nodist_weston_keyboard_SOURCES = \
693 protocol/weston-desktop-shell-client-protocol.h \
694 protocol/weston-desktop-shell-protocol.c \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800695 protocol/input-method-unstable-v1-protocol.c \
696 protocol/input-method-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800697weston_keyboard_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800698weston_keyboard_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800699
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800700weston_simple_im_SOURCES = clients/weston-simple-im.c
701nodist_weston_simple_im_SOURCES = \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800702 protocol/input-method-unstable-v1-protocol.c \
703 protocol/input-method-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800704weston_simple_im_LDADD = $(CLIENT_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800705weston_simple_im_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800706
Jon A. Cruzb09da242015-06-16 13:15:13 -0700707weston_info_SOURCES = \
708 clients/weston-info.c \
709 shared/helpers.h
Pekka Paalanen93a6afd2014-09-23 22:08:44 -0400710nodist_weston_info_SOURCES = \
711 protocol/presentation_timing-protocol.c \
712 protocol/presentation_timing-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800713weston_info_LDADD = $(WESTON_INFO_LIBS) libshared.la
Pekka Paalanen5124b532014-02-03 13:12:34 +0200714weston_info_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800715
Jon A. Cruzb09da242015-06-16 13:15:13 -0700716weston_desktop_shell_SOURCES = \
717 clients/desktop-shell.c \
718 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800719nodist_weston_desktop_shell_SOURCES = \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800720 protocol/weston-desktop-shell-client-protocol.h \
721 protocol/weston-desktop-shell-protocol.c
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800722weston_desktop_shell_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800723weston_desktop_shell_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800724
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900725if ENABLE_IVI_SHELL
Jon A. Cruzb09da242015-06-16 13:15:13 -0700726weston_ivi_shell_user_interface_SOURCES = \
727 clients/ivi-shell-user-interface.c \
728 shared/helpers.h
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900729nodist_weston_ivi_shell_user_interface_SOURCES = \
730 protocol/ivi-hmi-controller-client-protocol.h \
731 protocol/ivi-hmi-controller-protocol.c \
732 protocol/ivi-application-client-protocol.h \
733 protocol/ivi-application-protocol.c
734weston_ivi_shell_user_interface_LDADD = libtoytoolkit.la
735weston_ivi_shell_user_interface_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
736endif
737
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800738if BUILD_FULL_GL_CLIENTS
739demo_clients += weston-gears
740weston_gears_SOURCES = clients/gears.c
741weston_gears_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800742weston_gears_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800743endif
744
745endif
746
747BUILT_SOURCES += \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800748 protocol/weston-screenshooter-protocol.c \
749 protocol/weston-screenshooter-client-protocol.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100750 protocol/text-cursor-position-client-protocol.h \
751 protocol/text-cursor-position-protocol.c \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800752 protocol/text-input-unstable-v1-protocol.c \
753 protocol/text-input-unstable-v1-client-protocol.h \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800754 protocol/input-method-unstable-v1-protocol.c \
755 protocol/input-method-unstable-v1-client-protocol.h \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800756 protocol/weston-desktop-shell-client-protocol.h \
757 protocol/weston-desktop-shell-protocol.c \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100758 protocol/scaler-client-protocol.h \
759 protocol/scaler-protocol.c \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800760 protocol/fullscreen-shell-unstable-v1-protocol.c \
761 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800762 protocol/xdg-shell-unstable-v5-protocol.c \
763 protocol/xdg-shell-unstable-v5-client-protocol.h \
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900764 protocol/ivi-hmi-controller-protocol.c \
765 protocol/ivi-hmi-controller-client-protocol.h \
766 protocol/ivi-application-protocol.c \
767 protocol/ivi-application-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800768
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -0800769westondatadir = $(datadir)/weston
770dist_westondata_DATA = \
771 data/wayland.svg \
772 data/wayland.png \
773 data/pattern.png \
774 data/terminal.png \
775 data/border.png \
776 data/icon_window.png \
777 data/sign_close.png \
778 data/sign_maximize.png \
Manuel Bachmannd2c68922015-02-16 11:00:36 +0100779 data/sign_minimize.png
780
781if ENABLE_IVI_SHELL
782dist_westondata_DATA += \
Nobuhiko Tanibata001a5432014-03-11 11:54:45 +0900783 data/background.png \
784 data/tiling.png \
785 data/fullscreen.png \
786 data/panel.png \
787 data/random.png \
788 data/sidebyside.png \
789 data/home.png \
790 data/icon_ivi_clickdot.png \
791 data/icon_ivi_flower.png \
792 data/icon_ivi_simple-egl.png \
793 data/icon_ivi_simple-shm.png \
794 data/icon_ivi_smoke.png
Manuel Bachmannd2c68922015-02-16 11:00:36 +0100795endif
Kristian Høgsberge895f142014-01-27 21:46:30 -0800796
797
798if BUILD_WCAP_TOOLS
799bin_PROGRAMS += wcap-decode
800
801wcap_decode_SOURCES = \
802 wcap/main.c \
803 wcap/wcap-decode.c \
804 wcap/wcap-decode.h
805
Derek Foreman4ff38742015-06-18 11:43:11 -0500806wcap_decode_CFLAGS = $(AM_CFLAGS) $(WCAP_CFLAGS)
Kristian Høgsberge895f142014-01-27 21:46:30 -0800807wcap_decode_LDADD = $(WCAP_LIBS)
808endif
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800809
810
811if ENABLE_DESKTOP_SHELL
812
813module_LTLIBRARIES += desktop-shell.la
814
815desktop_shell_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100816 -I$(top_builddir)/protocol \
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800817 -I$(top_srcdir)/shared \
818 -I$(top_srcdir)/src \
819 -I$(top_builddir)/src \
820 -I$(top_builddir)/desktop-shell \
821 -DDATADIR='"$(datadir)"' \
822 -DMODULEDIR='"$(moduledir)"' \
823 -DLIBEXECDIR='"$(libexecdir)"' \
824 -DIN_WESTON
825
826desktop_shell_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800827desktop_shell_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500828desktop_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800829desktop_shell_la_SOURCES = \
830 desktop-shell/shell.h \
831 desktop-shell/shell.c \
832 desktop-shell/exposay.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700833 desktop-shell/input-panel.c \
834 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800835nodist_desktop_shell_la_SOURCES = \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800836 protocol/weston-desktop-shell-protocol.c \
837 protocol/weston-desktop-shell-server-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800838 protocol/xdg-shell-unstable-v5-protocol.c \
839 protocol/xdg-shell-unstable-v5-server-protocol.h
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800840
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800841BUILT_SOURCES += $(nodist_desktop_shell_la_SOURCES)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800842endif
843
Jason Ekstrand946a9482014-04-02 19:53:47 -0500844if ENABLE_FULLSCREEN_SHELL
845
846module_LTLIBRARIES += fullscreen-shell.la
847
848fullscreen_shell_la_CPPFLAGS = \
849 -I$(top_builddir)/protocol \
850 -I$(top_srcdir)/shared \
851 -I$(top_srcdir)/src \
852 -I$(top_builddir)/src \
853 -DIN_WESTON
854
855fullscreen_shell_la_LDFLAGS = -module -avoid-version
856fullscreen_shell_la_LIBADD = $(COMPOSITOR_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500857fullscreen_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Jason Ekstrand946a9482014-04-02 19:53:47 -0500858fullscreen_shell_la_SOURCES = \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700859 fullscreen-shell/fullscreen-shell.c \
860 shared/helpers.h
Jason Ekstrand946a9482014-04-02 19:53:47 -0500861nodist_fullscreen_shell_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800862 protocol/fullscreen-shell-unstable-v1-protocol.c \
863 protocol/fullscreen-shell-unstable-v1-server-protocol.h
Jason Ekstrand946a9482014-04-02 19:53:47 -0500864
865BUILT_SOURCES += $(nodist_fullscreen_shell_la_SOURCES)
866endif
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800867
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900868if ENABLE_IVI_SHELL
869
870module_LTLIBRARIES += \
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900871 $(ivi_shell) \
872 $(hmi_controller)
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900873
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900874ivi_shell = ivi-shell.la
875ivi_shell_la_LDFLAGS = -module -avoid-version
876ivi_shell_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500877ivi_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900878ivi_shell_la_SOURCES = \
Nobuhiko Tanibata28dc18c2014-12-15 13:22:31 +0900879 ivi-shell/ivi-layout-export.h \
880 ivi-shell/ivi-layout-private.h \
881 ivi-shell/ivi-layout.c \
882 ivi-shell/ivi-layout-transition.c \
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900883 ivi-shell/ivi-shell.h \
884 ivi-shell/ivi-shell.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700885 ivi-shell/input-panel-ivi.c \
886 shared/helpers.h
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900887nodist_ivi_shell_la_SOURCES = \
888 protocol/ivi-application-protocol.c \
889 protocol/ivi-application-server-protocol.h
890
891BUILT_SOURCES += $(nodist_ivi_shell_la_SOURCES)
892
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900893hmi_controller = hmi-controller.la
894hmi_controller_la_LDFLAGS = -module -avoid-version
895hmi_controller_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500896hmi_controller_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900897hmi_controller_la_SOURCES = \
898 ivi-shell/ivi-layout-export.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700899 ivi-shell/hmi-controller.c \
900 shared/helpers.h
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900901nodist_hmi_controller_la_SOURCES = \
902 protocol/ivi-hmi-controller-protocol.c \
903 protocol/ivi-hmi-controller-server-protocol.h
904
905BUILT_SOURCES += $(nodist_hmi_controller_la_SOURCES)
906
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900907endif
908
909
Jason Ekstrand47928d82014-04-02 19:54:01 -0500910if ENABLE_SCREEN_SHARING
911
912module_LTLIBRARIES += screen-share.la
913
914screen_share_la_CPPFLAGS = $(AM_CPPFLAGS) -DBINDIR='"$(bindir)"'
915screen_share_la_LDFLAGS = -module -avoid-version
916screen_share_la_LIBADD = \
917 $(COMPOSITOR_LIBS) \
918 $(SCREEN_SHARE_LIBS) \
919 libshared-cairo.la
920screen_share_la_CFLAGS = \
921 $(COMPOSITOR_CFLAGS) \
922 $(SCREEN_SHARE_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500923 $(AM_CFLAGS)
Jason Ekstrand47928d82014-04-02 19:54:01 -0500924screen_share_la_SOURCES = \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700925 src/screen-share.c \
926 shared/helpers.h
Jason Ekstrand47928d82014-04-02 19:54:01 -0500927nodist_screen_share_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800928 protocol/fullscreen-shell-unstable-v1-protocol.c \
929 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Jason Ekstrand47928d82014-04-02 19:54:01 -0500930
931endif
932
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800933if ENABLE_XWAYLAND
934
935module_LTLIBRARIES += xwayland.la
936
937xwayland_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100938 -I$(top_builddir)/protocol \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800939 -I$(top_srcdir)/shared \
940 -I$(top_srcdir)/src \
941 -I$(top_builddir)/src \
942 -I$(top_builddir)/xwayland \
943 -DDATADIR='"$(datadir)"' \
944 -DMODULEDIR='"$(moduledir)"' \
945 -DLIBEXECDIR='"$(libexecdir)"' \
946 -DXSERVER_PATH='"@XSERVER_PATH@"'
947
948xwayland_la_LDFLAGS = -module -avoid-version
949xwayland_la_LIBADD = \
950 $(XWAYLAND_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800951 $(top_builddir)/libshared-cairo.la
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800952xwayland_la_CFLAGS = \
Derek Foreman4ff38742015-06-18 11:43:11 -0500953 $(AM_CFLAGS) \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800954 $(COMPOSITOR_CFLAGS) \
955 $(PIXMAN_CFLAGS) \
956 $(CAIRO_CFLAGS)
957xwayland_la_SOURCES = \
958 xwayland/xwayland.h \
959 xwayland/window-manager.c \
960 xwayland/selection.c \
961 xwayland/dnd.c \
962 xwayland/launcher.c \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800963 xwayland/hash.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700964 xwayland/hash.h \
965 shared/helpers.h
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800966endif
967
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -0800968
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800969#
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800970# Shared utilities
971#
972
Jon A. Cruz5a75a412015-07-02 23:36:44 -0700973noinst_LTLIBRARIES += libshared.la libshared-cairo.la \
974 libzunitc.la libzunitcmain.la
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800975
Derek Foreman4ff38742015-06-18 11:43:11 -0500976libshared_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800977
978libshared_la_SOURCES = \
979 shared/config-parser.c \
980 shared/option-parser.c \
981 shared/config-parser.h \
Pekka Paalanen899b50b2015-02-12 12:52:21 +0200982 shared/file-util.c \
983 shared/file-util.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700984 shared/helpers.h \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800985 shared/os-compatibility.c \
986 shared/os-compatibility.h
987
988libshared_cairo_la_CFLAGS = \
989 -DDATADIR='"$(datadir)"' \
Derek Foreman4ff38742015-06-18 11:43:11 -0500990 $(AM_CFLAGS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800991 $(COMPOSITOR_CFLAGS) \
992 $(PIXMAN_CFLAGS) \
993 $(CAIRO_CFLAGS) \
994 $(PNG_CFLAGS) \
995 $(WEBP_CFLAGS)
996
997libshared_cairo_la_LIBADD = \
998 $(PIXMAN_LIBS) \
999 $(CAIRO_LIBS) \
1000 $(PNG_LIBS) \
1001 $(WEBP_LIBS) \
1002 $(JPEG_LIBS)
1003
1004libshared_cairo_la_SOURCES = \
1005 $(libshared_la_SOURCES) \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001006 shared/helpers.h \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001007 shared/image-loader.c \
1008 shared/image-loader.h \
1009 shared/cairo-util.c \
1010 shared/frame.c \
1011 shared/cairo-util.h
1012
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001013libzunitc_la_SOURCES = \
1014 tools/zunitc/inc/zunitc/zunitc.h \
1015 tools/zunitc/inc/zunitc/zunitc_impl.h \
1016 tools/zunitc/src/zuc_base_logger.c \
1017 tools/zunitc/src/zuc_base_logger.h \
1018 tools/zunitc/src/zuc_collector.c \
1019 tools/zunitc/src/zuc_collector.h \
1020 tools/zunitc/src/zuc_context.h \
1021 tools/zunitc/src/zuc_event.h \
1022 tools/zunitc/src/zuc_event_listener.h \
Jon A. Cruz646aef52015-07-15 19:22:41 -07001023 tools/zunitc/src/zuc_junit_reporter.c \
1024 tools/zunitc/src/zuc_junit_reporter.h \
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001025 tools/zunitc/src/zuc_types.h \
1026 tools/zunitc/src/zunitc_impl.c \
1027 shared/helpers.h
1028
1029libzunitc_la_CFLAGS = \
1030 $(AM_CFLAGS) \
1031 -I$(top_srcdir)/tools/zunitc/inc
1032
1033libzunitc_la_LIBADD = \
1034 libshared.la
1035
Jon A. Cruz646aef52015-07-15 19:22:41 -07001036if ENABLE_JUNIT_XML
1037libzunitc_la_CFLAGS += \
1038 $(LIBXML2_CFLAGS)
1039libzunitc_la_LIBADD += \
1040 $(LIBXML2_LIBS)
1041endif
1042
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001043libzunitcmain_la_SOURCES = \
1044 tools/zunitc/src/main.c
1045
1046libzunitcmain_la_CFLAGS = \
1047 $(AM_CFLAGS) \
1048 -I$(top_srcdir)/tools/zunitc/inc
1049
1050libzunitcmain_la_LIBADD = \
1051 libzunitc.la \
1052 libshared.la
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001053
1054#
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001055# tests subdirectory
1056#
1057
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001058TESTS = $(internal_tests) $(shared_tests) $(module_tests) $(weston_tests) $(ivi_tests)
1059
1060internal_tests = \
1061 internal-screenshot.weston
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001062
1063shared_tests = \
1064 config-parser.test \
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001065 vertex-clip.test \
1066 zuctest
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001067
1068module_tests = \
1069 surface-test.la \
1070 surface-global-test.la
1071
1072weston_tests = \
1073 bad_buffer.weston \
1074 keyboard.weston \
1075 event.weston \
1076 button.weston \
1077 text.weston \
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001078 presentation.weston \
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +03001079 roles.weston \
Marek Chalupa5fd81402015-03-30 09:21:29 -04001080 subsurface.weston \
1081 devices.weston
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001082
Pekka Paalanenf3a34532015-03-24 13:51:05 +02001083ivi_tests =
1084
1085$(ivi_tests) : $(builddir)/tests/weston-ivi.ini
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001086
1087AM_TESTS_ENVIRONMENT = \
Bryce Harringtoned2c6442015-04-15 15:31:11 -07001088 abs_builddir='$(abs_builddir)'; export abs_builddir; \
1089 abs_top_srcdir='$(abs_top_srcdir)'; export abs_top_srcdir;
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001090
1091TEST_EXTENSIONS = .la .weston
1092LA_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
1093WESTON_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
1094
1095clean-local:
Pekka Paalanen15f85632014-05-12 10:08:57 +03001096 -rm -rf logs
Jon A. Cruz179c1862015-07-15 19:22:43 -07001097 -rm -rf $(DOCDIRS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001098
1099# To remove when automake 1.11 support is dropped
1100export abs_builddir
1101
1102noinst_LTLIBRARIES += \
1103 weston-test.la \
1104 $(module_tests) \
1105 libtest-runner.la \
1106 libtest-client.la
1107
1108noinst_PROGRAMS += \
1109 $(setbacklight) \
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001110 $(internal_tests) \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001111 $(shared_tests) \
1112 $(weston_tests) \
Pekka Paalanenf3a34532015-03-24 13:51:05 +02001113 $(ivi_tests) \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001114 matrix-test
1115
1116test_module_ldflags = \
1117 -module -avoid-version -rpath $(libdir) $(COMPOSITOR_LIBS)
1118
1119surface_global_test_la_SOURCES = tests/surface-global-test.c
1120surface_global_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001121surface_global_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001122
1123surface_test_la_SOURCES = tests/surface-test.c
1124surface_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001125surface_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001126
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001127weston_test_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001128weston_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001129weston_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -07001130weston_test_la_SOURCES = \
1131 tests/weston-test.c \
1132 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001133nodist_weston_test_la_SOURCES = \
Derek Foremanf6a65922015-02-24 09:32:14 -06001134 protocol/weston-test-protocol.c \
1135 protocol/weston-test-server-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001136
1137if ENABLE_EGL
1138weston_test_la_CFLAGS += $(EGL_TESTS_CFLAGS)
1139weston_test_la_LDFLAGS += $(EGL_TESTS_LIBS)
1140endif
1141
1142libtest_runner_la_SOURCES = \
1143 tests/weston-test-runner.c \
1144 tests/weston-test-runner.h
Derek Foreman4ff38742015-06-18 11:43:11 -05001145libtest_runner_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001146
1147config_parser_test_SOURCES = tests/config-parser-test.c
Jon A. Cruza67c5412015-07-15 19:22:42 -07001148config_parser_test_LDADD = \
1149 libshared.la \
1150 $(COMPOSITOR_LIBS) \
1151 libzunitc.la \
1152 libzunitcmain.la
1153config_parser_test_CFLAGS = \
1154 $(AM_CFLAGS) \
1155 -I$(top_srcdir)/tools/zunitc/inc
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001156
1157vertex_clip_test_SOURCES = \
1158 tests/vertex-clip-test.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001159 shared/helpers.h \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001160 src/vertex-clipping.c \
1161 src/vertex-clipping.h
1162vertex_clip_test_LDADD = libtest-runner.la -lm -lrt
1163
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001164libtest_client_la_SOURCES = \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001165 tests/weston-test-client-helper.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001166 tests/weston-test-client-helper.h
1167nodist_libtest_client_la_SOURCES = \
Derek Foremanf6a65922015-02-24 09:32:14 -06001168 protocol/weston-test-protocol.c \
1169 protocol/weston-test-client-protocol.h
Bryce Harrington892122e2015-09-24 14:31:44 -07001170libtest_client_la_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS) $(CAIRO_CFLAGS)
1171libtest_client_la_LIBADD = $(TEST_CLIENT_LIBS) $(CAIRO_LIBS) libshared.la libtest-runner.la
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001172
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001173
1174#
1175# Internal tests - tests functionality of the testsuite itself
1176#
1177
1178internal_screenshot_weston_SOURCES = tests/internal-screenshot-test.c
Bryce Harrington892122e2015-09-24 14:31:44 -07001179internal_screenshot_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1180internal_screenshot_weston_LDADD = libtest-client.la
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001181
1182
1183#
1184# Weston Tests
1185#
1186
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001187bad_buffer_weston_SOURCES = tests/bad-buffer-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001188bad_buffer_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001189bad_buffer_weston_LDADD = libtest-client.la
1190
1191keyboard_weston_SOURCES = tests/keyboard-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001192keyboard_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001193keyboard_weston_LDADD = libtest-client.la
1194
1195event_weston_SOURCES = tests/event-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001196event_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001197event_weston_LDADD = libtest-client.la
1198
1199button_weston_SOURCES = tests/button-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001200button_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001201button_weston_LDADD = libtest-client.la
1202
Marek Chalupa5fd81402015-03-30 09:21:29 -04001203devices_weston_SOURCES = tests/devices-test.c
1204devices_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1205devices_weston_LDADD = libtest-client.la
1206
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001207text_weston_SOURCES = tests/text-test.c
1208nodist_text_weston_SOURCES = \
Jonas Ådahl3bcba342015-11-17 16:00:29 +08001209 protocol/text-input-unstable-v1-protocol.c \
1210 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001211text_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001212text_weston_LDADD = libtest-client.la
1213
1214subsurface_weston_SOURCES = tests/subsurface-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001215subsurface_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001216subsurface_weston_LDADD = libtest-client.la
1217
Jon A. Cruzb09da242015-06-16 13:15:13 -07001218presentation_weston_SOURCES = \
1219 tests/presentation-test.c \
1220 shared/helpers.h
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001221nodist_presentation_weston_SOURCES = \
1222 protocol/presentation_timing-protocol.c \
1223 protocol/presentation_timing-client-protocol.h
1224presentation_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1225presentation_weston_LDADD = libtest-client.la
1226
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +03001227roles_weston_SOURCES = tests/roles-test.c
1228roles_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1229roles_weston_LDADD = libtest-client.la
1230
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001231if ENABLE_EGL
1232weston_tests += buffer-count.weston
1233buffer_count_weston_SOURCES = tests/buffer-count-test.c
Derek Foreman4ff38742015-06-18 11:43:11 -05001234buffer_count_weston_CFLAGS = $(AM_CFLAGS) $(EGL_TESTS_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001235buffer_count_weston_LDADD = libtest-client.la $(EGL_TESTS_LIBS)
1236endif
1237
1238if ENABLE_XWAYLAND_TEST
Pekka Paalanenf9a26262014-05-07 16:26:29 +03001239weston_tests += xwayland-test.weston
1240xwayland_test_weston_SOURCES = tests/xwayland-test.c
Derek Foreman4ff38742015-06-18 11:43:11 -05001241xwayland_test_weston_CFLAGS = $(AM_CFLAGS) $(XWAYLAND_TEST_CFLAGS)
Pekka Paalanenf9a26262014-05-07 16:26:29 +03001242xwayland_test_weston_LDADD = libtest-client.la $(XWAYLAND_TEST_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001243endif
1244
1245matrix_test_SOURCES = \
1246 tests/matrix-test.c \
1247 shared/matrix.c \
1248 shared/matrix.h
1249matrix_test_CPPFLAGS = -DUNIT_TEST
1250matrix_test_LDADD = -lm -lrt
1251
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001252if ENABLE_IVI_SHELL
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001253module_tests += \
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001254 ivi-layout-internal-test.la \
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001255 ivi-layout-test.la
1256
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001257ivi_layout_internal_test_la_LIBADD = $(COMPOSITOR_LIBS)
1258ivi_layout_internal_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001259ivi_layout_internal_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001260ivi_layout_internal_test_la_SOURCES = \
1261 tests/ivi_layout-internal-test.c
1262
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001263ivi_layout_test_la_LIBADD = $(COMPOSITOR_LIBS)
1264ivi_layout_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001265ivi_layout_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001266ivi_layout_test_la_SOURCES = \
1267 tests/ivi_layout-test-plugin.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001268 tests/ivi-test.h \
1269 shared/helpers.h
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001270nodist_ivi_layout_test_la_SOURCES = \
1271 protocol/weston-test-protocol.c \
1272 protocol/weston-test-server-protocol.h
1273
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001274ivi_tests += \
1275 ivi-shell-app.weston
1276
1277ivi_shell_app_weston_SOURCES = tests/ivi-shell-app-test.c
1278nodist_ivi_shell_app_weston_SOURCES = \
1279 protocol/ivi-application-protocol.c \
1280 protocol/ivi-application-client-protocol.h
1281ivi_shell_app_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1282ivi_shell_app_weston_LDADD = libtest-client.la
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001283
1284noinst_PROGRAMS += ivi-layout.ivi
1285
1286ivi_layout_ivi_SOURCES = \
1287 tests/ivi_layout-test.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001288 tests/ivi-test.h \
1289 shared/helpers.h
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001290nodist_ivi_layout_ivi_SOURCES = \
1291 protocol/ivi-application-protocol.c \
1292 protocol/ivi-application-client-protocol.h
1293ivi_layout_ivi_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1294ivi_layout_ivi_LDADD = libtest-client.la
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001295endif
1296
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001297if BUILD_SETBACKLIGHT
1298noinst_PROGRAMS += setbacklight
1299setbacklight_SOURCES = \
1300 tests/setbacklight.c \
1301 src/libbacklight.c \
1302 src/libbacklight.h
1303setbacklight_CFLAGS = $(AM_CFLAGS) $(SETBACKLIGHT_CFLAGS)
1304setbacklight_LDADD = $(SETBACKLIGHT_LIBS)
1305endif
1306
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001307all-local: zuctest$(EXEEXT)
1308
1309noinst_PROGRAMS += zuctest$(EXEEXT)
1310
1311zuctest_LDADD = \
1312 libzunitc.la \
1313 libzunitcmain.la
1314
1315zuctest_CFLAGS = \
1316 $(AM_CFLAGS) \
1317 -I$(top_srcdir)/tools/zunitc/inc
1318
1319zuctest_SOURCES = \
1320 tools/zunitc/test/fixtures_test.c \
1321 tools/zunitc/test/zunitc_test.c
1322
Derek Foreman1ce2ef52015-05-26 10:21:03 -05001323EXTRA_DIST += \
1324 tests/weston-tests-env \
1325 tests/internal-screenshot.ini \
1326 tests/reference/internal-screenshot-bad-00.png \
1327 tests/reference/internal-screenshot-good-00.png
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001328
1329BUILT_SOURCES += \
Derek Foremanf6a65922015-02-24 09:32:14 -06001330 protocol/weston-test-protocol.c \
1331 protocol/weston-test-server-protocol.h \
1332 protocol/weston-test-client-protocol.h \
Jonas Ådahl3bcba342015-11-17 16:00:29 +08001333 protocol/text-input-unstable-v1-protocol.c \
1334 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001335
Kristian Høgsbergcd312752014-02-01 00:38:15 -08001336EXTRA_DIST += \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +08001337 protocol/weston-desktop-shell.xml \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +08001338 protocol/weston-screenshooter.xml \
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001339 protocol/text-cursor-position.xml \
Derek Foremanf6a65922015-02-24 09:32:14 -06001340 protocol/weston-test.xml \
Pekka Paalanen7e62d252014-09-23 22:08:42 -04001341 protocol/presentation_timing.xml \
Nobuhiko Tanibatabff1b4a2014-11-27 13:21:34 +09001342 protocol/scaler.xml \
Nobuhiko Tanibata68cfabb2014-11-27 13:22:53 +09001343 protocol/ivi-application.xml \
Jonas Ådahl57e48f02015-11-17 16:00:28 +08001344 protocol/ivi-hmi-controller.xml
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001345
Pekka Paalanen312fe5f2015-02-09 11:23:48 +02001346#
1347# manual test modules in tests subdirectory
1348#
1349
1350noinst_LTLIBRARIES += \
1351 surface-screenshot.la
1352
1353surface_screenshot_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
1354surface_screenshot_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001355surface_screenshot_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanen312fe5f2015-02-09 11:23:48 +02001356surface_screenshot_la_SOURCES = tests/surface-screenshot.c
1357
1358
1359#
1360# Documentation
1361#
1362
Kristian Høgsberg68c5c102014-01-27 22:33:04 -08001363man_MANS = weston.1 weston.ini.5
1364
1365if ENABLE_DRM_COMPOSITOR
1366man_MANS += weston-drm.7
1367endif
1368
1369MAN_SUBSTS = \
1370 -e 's|__weston_native_backend__|$(WESTON_NATIVE_BACKEND)|g' \
1371 -e 's|__weston_modules_dir__|$(pkglibdir)|g' \
1372 -e 's|__weston_shell_client__|$(WESTON_SHELL_CLIENT)|g' \
1373 -e 's|__version__|$(PACKAGE_VERSION)|g'
1374
1375SUFFIXES = .1 .5 .7 .man
1376
1377%.1 %.5 %.7 : man/%.man
1378 $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
1379
1380EXTRA_DIST += \
1381 man/weston.man \
1382 man/weston-drm.man \
1383 man/weston.ini.man
1384
1385CLEANFILES += $(man_MANS)
1386
Jon A. Cruz179c1862015-07-15 19:22:43 -07001387if ENABLE_DEVDOCS
1388DOXYGEN_INDICES = docs/developer/html/index.html docs/tools/html/index.html
1389
1390docs/developer/html/index.html: doc/doxygen/tooldev.doxygen | docs/developer
1391 cd doc/doxygen && $(DOXYGEN) tooldev.doxygen
1392
1393docs/tools/html/index.html: doc/doxygen/tools.doxygen | docs/tools
1394 cd doc/doxygen && $(DOXYGEN) tools.doxygen
1395endif
1396
1397DOCDIRS = \
1398 docs/developer \
1399 docs/tools
1400
1401$(DOCDIRS):
1402 $(MKDIR_P) $@
1403
1404.PHONY: doc $(DOXYGEN_INDICES)
1405
1406doc: $(DOXYGEN_INDICES)
1407
Jonas Ådahl496adb32015-11-17 16:00:27 +08001408.SECONDEXPANSION:
1409
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001410define protostability
1411$(shell echo $1 | sed 's/.*\(\<unstable\>\|\<stable\>\).*/\1/')
1412endef
1413
1414define protoname
1415$(shell echo $1 | sed 's/\([a-z\-]\+\)-[a-z]\+-v[0-9]\+/\1/')
1416endef
1417
1418protocol/%-protocol.c : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001419 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
1420
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001421protocol/%-server-protocol.h : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001422 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
1423
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001424protocol/%-client-protocol.h : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001425 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@
1426
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001427protocol/%-protocol.c : $(top_srcdir)/protocol/%.xml
1428 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001429
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001430protocol/%-server-protocol.h : $(top_srcdir)/protocol/%.xml
1431 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001432
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001433protocol/%-client-protocol.h : $(top_srcdir)/protocol/%.xml
1434 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@