blob: d1644ac5cc6b210714fd23b462f872f47809c1ac [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 Paalanenb00c79b2016-02-18 16:53:27 +0200124 protocol/presentation-time-protocol.c \
125 protocol/presentation-time-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 = \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200504 protocol/presentation-time-protocol.c \
505 protocol/presentation-time-client-protocol.h
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400506weston_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
Emmanuel Gil Peyrot5d43af32016-01-11 19:04:38 +0000541if BUILD_SIMPLE_DMABUF_V4L_CLIENT
542demo_clients += weston-simple-dmabuf-v4l
543weston_simple_dmabuf_v4l_SOURCES = clients/simple-dmabuf-v4l.c
544nodist_weston_simple_dmabuf_v4l_SOURCES = \
545 protocol/xdg-shell-unstable-v5-protocol.c \
546 protocol/xdg-shell-unstable-v5-client-protocol.h \
547 protocol/fullscreen-shell-unstable-v1-protocol.c \
548 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
549 protocol/linux-dmabuf-unstable-v1-protocol.c \
550 protocol/linux-dmabuf-unstable-v1-client-protocol.h
551weston_simple_dmabuf_v4l_CFLAGS = $(AM_CFLAGS) $(SIMPLE_DMABUF_V4L_CLIENT_CFLAGS)
552weston_simple_dmabuf_v4l_LDADD = $(SIMPLE_DMABUF_V4L_CLIENT_LIBS) libshared.la
553BUILT_SOURCES += protocol/linux-dmabuf-unstable-v1-client-protocol.h
554endif
555
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800556noinst_LTLIBRARIES += libtoytoolkit.la
557
558libtoytoolkit_la_SOURCES = \
559 clients/window.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700560 clients/window.h \
561 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800562
563nodist_libtoytoolkit_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100564 protocol/text-cursor-position-protocol.c \
565 protocol/text-cursor-position-client-protocol.h \
566 protocol/scaler-protocol.c \
567 protocol/scaler-client-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800568 protocol/xdg-shell-unstable-v5-protocol.c \
569 protocol/xdg-shell-unstable-v5-client-protocol.h \
Nobuhiko Tanibatabff1b4a2014-11-27 13:21:34 +0900570 protocol/ivi-application-protocol.c \
571 protocol/ivi-application-client-protocol.h
Jasper St. Pierre0790e392013-12-09 14:58:00 -0500572
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800573BUILT_SOURCES += $(nodist_libtoytoolkit_la_SOURCES)
574
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800575
576libtoytoolkit_la_LIBADD = \
577 $(CLIENT_LIBS) \
578 $(CAIRO_EGL_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800579 libshared-cairo.la -lrt -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800580libtoytoolkit_la_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(CAIRO_EGL_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800581
582weston_flower_SOURCES = clients/flower.c
583weston_flower_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800584weston_flower_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800585
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100586weston_screenshooter_SOURCES = \
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800587 clients/screenshot.c
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800588nodist_weston_screenshooter_SOURCES = \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800589 protocol/weston-screenshooter-protocol.c \
590 protocol/weston-screenshooter-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800591weston_screenshooter_LDADD = $(CLIENT_LIBS) libshared.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800592weston_screenshooter_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800593
Jon A. Cruzb09da242015-06-16 13:15:13 -0700594weston_terminal_SOURCES = \
595 clients/terminal.c \
596 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800597weston_terminal_LDADD = libtoytoolkit.la -lutil
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800598weston_terminal_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800599
600weston_image_SOURCES = clients/image.c
601weston_image_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800602weston_image_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800603
Pekka Paalanen461e93c2014-08-20 11:58:47 +0300604weston_cliptest_SOURCES = \
605 clients/cliptest.c \
606 src/vertex-clipping.c \
607 src/vertex-clipping.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800608weston_cliptest_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800609weston_cliptest_LDADD = libtoytoolkit.la
610
Jon A. Cruzb09da242015-06-16 13:15:13 -0700611weston_dnd_SOURCES = \
612 clients/dnd.c \
613 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800614weston_dnd_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800615weston_dnd_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800616
617weston_smoke_SOURCES = clients/smoke.c
618weston_smoke_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800619weston_smoke_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800620
621weston_resizor_SOURCES = clients/resizor.c
622weston_resizor_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800623weston_resizor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800624
625weston_scaler_SOURCES = clients/scaler.c
626weston_scaler_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800627weston_scaler_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800628
629if HAVE_CAIRO_GLESV2
630demo_clients += weston-nested weston-nested-client
631
Jon A. Cruzb09da242015-06-16 13:15:13 -0700632weston_nested_SOURCES = \
633 clients/nested.c \
634 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800635weston_nested_LDADD = libtoytoolkit.la $(SERVER_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800636weston_nested_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800637
638weston_nested_client_SOURCES = clients/nested-client.c
639weston_nested_client_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800640weston_nested_client_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800641endif
642
Jon A. Cruzb09da242015-06-16 13:15:13 -0700643weston_eventdemo_SOURCES = \
644 clients/eventdemo.c \
645 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800646weston_eventdemo_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800647weston_eventdemo_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800648
Jon A. Cruzb09da242015-06-16 13:15:13 -0700649weston_clickdot_SOURCES = \
650 clients/clickdot.c \
651 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800652weston_clickdot_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800653weston_clickdot_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800654
655weston_transformed_SOURCES = clients/transformed.c
656weston_transformed_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800657weston_transformed_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800658
659weston_fullscreen_SOURCES = clients/fullscreen.c
Jason Ekstrand2bb72fe2014-04-02 19:53:52 -0500660nodist_weston_fullscreen_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800661 protocol/fullscreen-shell-unstable-v1-protocol.c \
662 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800663weston_fullscreen_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800664weston_fullscreen_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800665
Jon A. Cruzb09da242015-06-16 13:15:13 -0700666weston_stacking_SOURCES = \
667 clients/stacking.c \
668 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800669weston_stacking_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800670weston_stacking_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800671
Jon A. Cruzb09da242015-06-16 13:15:13 -0700672weston_calibrator_SOURCES = \
673 clients/calibrator.c \
674 shared/helpers.h \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800675 shared/matrix.c \
676 shared/matrix.h
677weston_calibrator_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800678weston_calibrator_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800679
680if BUILD_SUBSURFACES_CLIENT
681demo_clients += weston-subsurfaces
Jon A. Cruzb09da242015-06-16 13:15:13 -0700682weston_subsurfaces_SOURCES = \
683 clients/subsurfaces.c \
684 shared/helpers.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800685weston_subsurfaces_CFLAGS = \
686 $(AM_CFLAGS) \
687 $(SIMPLE_EGL_CLIENT_CFLAGS) \
688 $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800689weston_subsurfaces_LDADD = libtoytoolkit.la $(SIMPLE_EGL_CLIENT_LIBS) -lm
690endif
691
692if HAVE_PANGO
693demo_clients += weston-editor
Jon A. Cruzb09da242015-06-16 13:15:13 -0700694weston_editor_SOURCES = \
695 clients/editor.c \
696 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800697nodist_weston_editor_SOURCES = \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800698 protocol/text-input-unstable-v1-protocol.c \
699 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800700weston_editor_LDADD = libtoytoolkit.la $(PANGO_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800701weston_editor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(PANGO_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800702endif
703
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800704weston_keyboard_SOURCES = clients/keyboard.c
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800705nodist_weston_keyboard_SOURCES = \
706 protocol/weston-desktop-shell-client-protocol.h \
707 protocol/weston-desktop-shell-protocol.c \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800708 protocol/input-method-unstable-v1-protocol.c \
709 protocol/input-method-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800710weston_keyboard_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800711weston_keyboard_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800712
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800713weston_simple_im_SOURCES = clients/weston-simple-im.c
714nodist_weston_simple_im_SOURCES = \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800715 protocol/input-method-unstable-v1-protocol.c \
716 protocol/input-method-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800717weston_simple_im_LDADD = $(CLIENT_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800718weston_simple_im_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800719
Jon A. Cruzb09da242015-06-16 13:15:13 -0700720weston_info_SOURCES = \
721 clients/weston-info.c \
722 shared/helpers.h
Pekka Paalanen93a6afd2014-09-23 22:08:44 -0400723nodist_weston_info_SOURCES = \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200724 protocol/presentation-time-protocol.c \
725 protocol/presentation-time-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800726weston_info_LDADD = $(WESTON_INFO_LIBS) libshared.la
Pekka Paalanen5124b532014-02-03 13:12:34 +0200727weston_info_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800728
Jon A. Cruzb09da242015-06-16 13:15:13 -0700729weston_desktop_shell_SOURCES = \
730 clients/desktop-shell.c \
731 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800732nodist_weston_desktop_shell_SOURCES = \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800733 protocol/weston-desktop-shell-client-protocol.h \
734 protocol/weston-desktop-shell-protocol.c
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800735weston_desktop_shell_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800736weston_desktop_shell_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800737
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900738if ENABLE_IVI_SHELL
Jon A. Cruzb09da242015-06-16 13:15:13 -0700739weston_ivi_shell_user_interface_SOURCES = \
740 clients/ivi-shell-user-interface.c \
741 shared/helpers.h
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900742nodist_weston_ivi_shell_user_interface_SOURCES = \
743 protocol/ivi-hmi-controller-client-protocol.h \
744 protocol/ivi-hmi-controller-protocol.c \
745 protocol/ivi-application-client-protocol.h \
746 protocol/ivi-application-protocol.c
747weston_ivi_shell_user_interface_LDADD = libtoytoolkit.la
748weston_ivi_shell_user_interface_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
749endif
750
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800751if BUILD_FULL_GL_CLIENTS
752demo_clients += weston-gears
753weston_gears_SOURCES = clients/gears.c
754weston_gears_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800755weston_gears_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800756endif
757
758endif
759
760BUILT_SOURCES += \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800761 protocol/weston-screenshooter-protocol.c \
762 protocol/weston-screenshooter-client-protocol.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100763 protocol/text-cursor-position-client-protocol.h \
764 protocol/text-cursor-position-protocol.c \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800765 protocol/text-input-unstable-v1-protocol.c \
766 protocol/text-input-unstable-v1-client-protocol.h \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800767 protocol/input-method-unstable-v1-protocol.c \
768 protocol/input-method-unstable-v1-client-protocol.h \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800769 protocol/weston-desktop-shell-client-protocol.h \
770 protocol/weston-desktop-shell-protocol.c \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100771 protocol/scaler-client-protocol.h \
772 protocol/scaler-protocol.c \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200773 protocol/presentation-time-protocol.c \
774 protocol/presentation-time-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800775 protocol/fullscreen-shell-unstable-v1-protocol.c \
776 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800777 protocol/xdg-shell-unstable-v5-protocol.c \
778 protocol/xdg-shell-unstable-v5-client-protocol.h \
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900779 protocol/ivi-hmi-controller-protocol.c \
780 protocol/ivi-hmi-controller-client-protocol.h \
781 protocol/ivi-application-protocol.c \
782 protocol/ivi-application-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800783
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -0800784westondatadir = $(datadir)/weston
785dist_westondata_DATA = \
786 data/wayland.svg \
787 data/wayland.png \
788 data/pattern.png \
789 data/terminal.png \
790 data/border.png \
791 data/icon_window.png \
792 data/sign_close.png \
793 data/sign_maximize.png \
Manuel Bachmannd2c68922015-02-16 11:00:36 +0100794 data/sign_minimize.png
795
796if ENABLE_IVI_SHELL
797dist_westondata_DATA += \
Nobuhiko Tanibata001a5432014-03-11 11:54:45 +0900798 data/background.png \
799 data/tiling.png \
800 data/fullscreen.png \
801 data/panel.png \
802 data/random.png \
803 data/sidebyside.png \
804 data/home.png \
805 data/icon_ivi_clickdot.png \
806 data/icon_ivi_flower.png \
807 data/icon_ivi_simple-egl.png \
808 data/icon_ivi_simple-shm.png \
809 data/icon_ivi_smoke.png
Manuel Bachmannd2c68922015-02-16 11:00:36 +0100810endif
Kristian Høgsberge895f142014-01-27 21:46:30 -0800811
812
813if BUILD_WCAP_TOOLS
814bin_PROGRAMS += wcap-decode
815
816wcap_decode_SOURCES = \
817 wcap/main.c \
818 wcap/wcap-decode.c \
819 wcap/wcap-decode.h
820
Derek Foreman4ff38742015-06-18 11:43:11 -0500821wcap_decode_CFLAGS = $(AM_CFLAGS) $(WCAP_CFLAGS)
Kristian Høgsberge895f142014-01-27 21:46:30 -0800822wcap_decode_LDADD = $(WCAP_LIBS)
823endif
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800824
825
826if ENABLE_DESKTOP_SHELL
827
828module_LTLIBRARIES += desktop-shell.la
829
830desktop_shell_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100831 -I$(top_builddir)/protocol \
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800832 -I$(top_srcdir)/shared \
833 -I$(top_srcdir)/src \
834 -I$(top_builddir)/src \
835 -I$(top_builddir)/desktop-shell \
836 -DDATADIR='"$(datadir)"' \
837 -DMODULEDIR='"$(moduledir)"' \
838 -DLIBEXECDIR='"$(libexecdir)"' \
839 -DIN_WESTON
840
841desktop_shell_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800842desktop_shell_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500843desktop_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800844desktop_shell_la_SOURCES = \
845 desktop-shell/shell.h \
846 desktop-shell/shell.c \
847 desktop-shell/exposay.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700848 desktop-shell/input-panel.c \
849 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800850nodist_desktop_shell_la_SOURCES = \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800851 protocol/weston-desktop-shell-protocol.c \
852 protocol/weston-desktop-shell-server-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800853 protocol/xdg-shell-unstable-v5-protocol.c \
854 protocol/xdg-shell-unstable-v5-server-protocol.h
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800855
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800856BUILT_SOURCES += $(nodist_desktop_shell_la_SOURCES)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800857endif
858
Jason Ekstrand946a9482014-04-02 19:53:47 -0500859if ENABLE_FULLSCREEN_SHELL
860
861module_LTLIBRARIES += fullscreen-shell.la
862
863fullscreen_shell_la_CPPFLAGS = \
864 -I$(top_builddir)/protocol \
865 -I$(top_srcdir)/shared \
866 -I$(top_srcdir)/src \
867 -I$(top_builddir)/src \
868 -DIN_WESTON
869
870fullscreen_shell_la_LDFLAGS = -module -avoid-version
871fullscreen_shell_la_LIBADD = $(COMPOSITOR_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500872fullscreen_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Jason Ekstrand946a9482014-04-02 19:53:47 -0500873fullscreen_shell_la_SOURCES = \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700874 fullscreen-shell/fullscreen-shell.c \
875 shared/helpers.h
Jason Ekstrand946a9482014-04-02 19:53:47 -0500876nodist_fullscreen_shell_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800877 protocol/fullscreen-shell-unstable-v1-protocol.c \
878 protocol/fullscreen-shell-unstable-v1-server-protocol.h
Jason Ekstrand946a9482014-04-02 19:53:47 -0500879
880BUILT_SOURCES += $(nodist_fullscreen_shell_la_SOURCES)
881endif
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800882
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900883if ENABLE_IVI_SHELL
884
885module_LTLIBRARIES += \
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900886 $(ivi_shell) \
887 $(hmi_controller)
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900888
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900889ivi_shell = ivi-shell.la
890ivi_shell_la_LDFLAGS = -module -avoid-version
891ivi_shell_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500892ivi_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900893ivi_shell_la_SOURCES = \
Nobuhiko Tanibata28dc18c2014-12-15 13:22:31 +0900894 ivi-shell/ivi-layout-export.h \
895 ivi-shell/ivi-layout-private.h \
Pekka Paalanen32ca7912016-03-15 17:21:00 +0200896 ivi-shell/ivi-layout-shell.h \
Nobuhiko Tanibata28dc18c2014-12-15 13:22:31 +0900897 ivi-shell/ivi-layout.c \
898 ivi-shell/ivi-layout-transition.c \
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900899 ivi-shell/ivi-shell.h \
900 ivi-shell/ivi-shell.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700901 ivi-shell/input-panel-ivi.c \
902 shared/helpers.h
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900903nodist_ivi_shell_la_SOURCES = \
904 protocol/ivi-application-protocol.c \
905 protocol/ivi-application-server-protocol.h
906
907BUILT_SOURCES += $(nodist_ivi_shell_la_SOURCES)
908
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900909hmi_controller = hmi-controller.la
910hmi_controller_la_LDFLAGS = -module -avoid-version
911hmi_controller_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500912hmi_controller_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900913hmi_controller_la_SOURCES = \
914 ivi-shell/ivi-layout-export.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700915 ivi-shell/hmi-controller.c \
916 shared/helpers.h
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900917nodist_hmi_controller_la_SOURCES = \
918 protocol/ivi-hmi-controller-protocol.c \
919 protocol/ivi-hmi-controller-server-protocol.h
920
921BUILT_SOURCES += $(nodist_hmi_controller_la_SOURCES)
922
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900923endif
924
925
Jason Ekstrand47928d82014-04-02 19:54:01 -0500926if ENABLE_SCREEN_SHARING
927
928module_LTLIBRARIES += screen-share.la
929
930screen_share_la_CPPFLAGS = $(AM_CPPFLAGS) -DBINDIR='"$(bindir)"'
931screen_share_la_LDFLAGS = -module -avoid-version
932screen_share_la_LIBADD = \
933 $(COMPOSITOR_LIBS) \
934 $(SCREEN_SHARE_LIBS) \
935 libshared-cairo.la
936screen_share_la_CFLAGS = \
937 $(COMPOSITOR_CFLAGS) \
938 $(SCREEN_SHARE_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500939 $(AM_CFLAGS)
Jason Ekstrand47928d82014-04-02 19:54:01 -0500940screen_share_la_SOURCES = \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700941 src/screen-share.c \
942 shared/helpers.h
Jason Ekstrand47928d82014-04-02 19:54:01 -0500943nodist_screen_share_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800944 protocol/fullscreen-shell-unstable-v1-protocol.c \
945 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Jason Ekstrand47928d82014-04-02 19:54:01 -0500946
947endif
948
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800949if ENABLE_XWAYLAND
950
951module_LTLIBRARIES += xwayland.la
952
953xwayland_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100954 -I$(top_builddir)/protocol \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800955 -I$(top_srcdir)/shared \
956 -I$(top_srcdir)/src \
957 -I$(top_builddir)/src \
958 -I$(top_builddir)/xwayland \
959 -DDATADIR='"$(datadir)"' \
960 -DMODULEDIR='"$(moduledir)"' \
961 -DLIBEXECDIR='"$(libexecdir)"' \
962 -DXSERVER_PATH='"@XSERVER_PATH@"'
963
964xwayland_la_LDFLAGS = -module -avoid-version
965xwayland_la_LIBADD = \
966 $(XWAYLAND_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800967 $(top_builddir)/libshared-cairo.la
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800968xwayland_la_CFLAGS = \
Derek Foreman4ff38742015-06-18 11:43:11 -0500969 $(AM_CFLAGS) \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800970 $(COMPOSITOR_CFLAGS) \
971 $(PIXMAN_CFLAGS) \
972 $(CAIRO_CFLAGS)
973xwayland_la_SOURCES = \
974 xwayland/xwayland.h \
975 xwayland/window-manager.c \
976 xwayland/selection.c \
977 xwayland/dnd.c \
978 xwayland/launcher.c \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800979 xwayland/hash.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700980 xwayland/hash.h \
981 shared/helpers.h
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800982endif
983
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -0800984
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -0800985#
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800986# Shared utilities
987#
988
Jon A. Cruz5a75a412015-07-02 23:36:44 -0700989noinst_LTLIBRARIES += libshared.la libshared-cairo.la \
990 libzunitc.la libzunitcmain.la
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800991
Derek Foreman4ff38742015-06-18 11:43:11 -0500992libshared_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800993
994libshared_la_SOURCES = \
995 shared/config-parser.c \
996 shared/option-parser.c \
997 shared/config-parser.h \
Pekka Paalanen899b50b2015-02-12 12:52:21 +0200998 shared/file-util.c \
999 shared/file-util.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001000 shared/helpers.h \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001001 shared/os-compatibility.c \
Bryce Harringtone99e4bf2016-03-16 14:15:18 -07001002 shared/os-compatibility.h \
1003 shared/xalloc.c \
1004 shared/xalloc.h
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001005
1006libshared_cairo_la_CFLAGS = \
1007 -DDATADIR='"$(datadir)"' \
Derek Foreman4ff38742015-06-18 11:43:11 -05001008 $(AM_CFLAGS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001009 $(COMPOSITOR_CFLAGS) \
1010 $(PIXMAN_CFLAGS) \
1011 $(CAIRO_CFLAGS) \
1012 $(PNG_CFLAGS) \
1013 $(WEBP_CFLAGS)
1014
1015libshared_cairo_la_LIBADD = \
1016 $(PIXMAN_LIBS) \
1017 $(CAIRO_LIBS) \
1018 $(PNG_LIBS) \
1019 $(WEBP_LIBS) \
1020 $(JPEG_LIBS)
1021
1022libshared_cairo_la_SOURCES = \
1023 $(libshared_la_SOURCES) \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001024 shared/helpers.h \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001025 shared/image-loader.c \
1026 shared/image-loader.h \
1027 shared/cairo-util.c \
1028 shared/frame.c \
1029 shared/cairo-util.h
1030
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001031libzunitc_la_SOURCES = \
1032 tools/zunitc/inc/zunitc/zunitc.h \
1033 tools/zunitc/inc/zunitc/zunitc_impl.h \
1034 tools/zunitc/src/zuc_base_logger.c \
1035 tools/zunitc/src/zuc_base_logger.h \
1036 tools/zunitc/src/zuc_collector.c \
1037 tools/zunitc/src/zuc_collector.h \
1038 tools/zunitc/src/zuc_context.h \
1039 tools/zunitc/src/zuc_event.h \
1040 tools/zunitc/src/zuc_event_listener.h \
Jon A. Cruz646aef52015-07-15 19:22:41 -07001041 tools/zunitc/src/zuc_junit_reporter.c \
1042 tools/zunitc/src/zuc_junit_reporter.h \
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001043 tools/zunitc/src/zuc_types.h \
1044 tools/zunitc/src/zunitc_impl.c \
1045 shared/helpers.h
1046
1047libzunitc_la_CFLAGS = \
1048 $(AM_CFLAGS) \
1049 -I$(top_srcdir)/tools/zunitc/inc
1050
1051libzunitc_la_LIBADD = \
1052 libshared.la
1053
Jon A. Cruz646aef52015-07-15 19:22:41 -07001054if ENABLE_JUNIT_XML
1055libzunitc_la_CFLAGS += \
1056 $(LIBXML2_CFLAGS)
1057libzunitc_la_LIBADD += \
1058 $(LIBXML2_LIBS)
1059endif
1060
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001061libzunitcmain_la_SOURCES = \
1062 tools/zunitc/src/main.c
1063
1064libzunitcmain_la_CFLAGS = \
1065 $(AM_CFLAGS) \
1066 -I$(top_srcdir)/tools/zunitc/inc
1067
1068libzunitcmain_la_LIBADD = \
1069 libzunitc.la \
1070 libshared.la
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001071
1072#
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001073# tests subdirectory
1074#
1075
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001076TESTS = $(internal_tests) $(shared_tests) $(module_tests) $(weston_tests) $(ivi_tests)
1077
1078internal_tests = \
1079 internal-screenshot.weston
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001080
1081shared_tests = \
1082 config-parser.test \
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001083 vertex-clip.test \
1084 zuctest
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001085
1086module_tests = \
1087 surface-test.la \
1088 surface-global-test.la
1089
1090weston_tests = \
1091 bad_buffer.weston \
1092 keyboard.weston \
1093 event.weston \
1094 button.weston \
1095 text.weston \
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001096 presentation.weston \
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +03001097 roles.weston \
Marek Chalupa5fd81402015-03-30 09:21:29 -04001098 subsurface.weston \
1099 devices.weston
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001100
Pekka Paalanenf3a34532015-03-24 13:51:05 +02001101ivi_tests =
1102
1103$(ivi_tests) : $(builddir)/tests/weston-ivi.ini
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001104
1105AM_TESTS_ENVIRONMENT = \
Bryce Harringtoned2c6442015-04-15 15:31:11 -07001106 abs_builddir='$(abs_builddir)'; export abs_builddir; \
1107 abs_top_srcdir='$(abs_top_srcdir)'; export abs_top_srcdir;
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001108
1109TEST_EXTENSIONS = .la .weston
1110LA_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
1111WESTON_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
1112
1113clean-local:
Pekka Paalanen15f85632014-05-12 10:08:57 +03001114 -rm -rf logs
Jon A. Cruz179c1862015-07-15 19:22:43 -07001115 -rm -rf $(DOCDIRS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001116
1117# To remove when automake 1.11 support is dropped
1118export abs_builddir
1119
1120noinst_LTLIBRARIES += \
1121 weston-test.la \
1122 $(module_tests) \
1123 libtest-runner.la \
1124 libtest-client.la
1125
1126noinst_PROGRAMS += \
1127 $(setbacklight) \
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001128 $(internal_tests) \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001129 $(shared_tests) \
1130 $(weston_tests) \
Pekka Paalanenf3a34532015-03-24 13:51:05 +02001131 $(ivi_tests) \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001132 matrix-test
1133
1134test_module_ldflags = \
1135 -module -avoid-version -rpath $(libdir) $(COMPOSITOR_LIBS)
1136
1137surface_global_test_la_SOURCES = tests/surface-global-test.c
1138surface_global_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001139surface_global_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001140
1141surface_test_la_SOURCES = tests/surface-test.c
1142surface_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001143surface_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001144
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001145weston_test_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001146weston_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001147weston_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -07001148weston_test_la_SOURCES = \
1149 tests/weston-test.c \
1150 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001151nodist_weston_test_la_SOURCES = \
Derek Foremanf6a65922015-02-24 09:32:14 -06001152 protocol/weston-test-protocol.c \
1153 protocol/weston-test-server-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001154
1155if ENABLE_EGL
1156weston_test_la_CFLAGS += $(EGL_TESTS_CFLAGS)
1157weston_test_la_LDFLAGS += $(EGL_TESTS_LIBS)
1158endif
1159
1160libtest_runner_la_SOURCES = \
1161 tests/weston-test-runner.c \
1162 tests/weston-test-runner.h
Derek Foreman4ff38742015-06-18 11:43:11 -05001163libtest_runner_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001164
1165config_parser_test_SOURCES = tests/config-parser-test.c
Jon A. Cruza67c5412015-07-15 19:22:42 -07001166config_parser_test_LDADD = \
1167 libshared.la \
1168 $(COMPOSITOR_LIBS) \
1169 libzunitc.la \
1170 libzunitcmain.la
1171config_parser_test_CFLAGS = \
1172 $(AM_CFLAGS) \
1173 -I$(top_srcdir)/tools/zunitc/inc
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001174
1175vertex_clip_test_SOURCES = \
1176 tests/vertex-clip-test.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001177 shared/helpers.h \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001178 src/vertex-clipping.c \
1179 src/vertex-clipping.h
1180vertex_clip_test_LDADD = libtest-runner.la -lm -lrt
1181
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001182libtest_client_la_SOURCES = \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001183 tests/weston-test-client-helper.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001184 tests/weston-test-client-helper.h
1185nodist_libtest_client_la_SOURCES = \
Derek Foremanf6a65922015-02-24 09:32:14 -06001186 protocol/weston-test-protocol.c \
1187 protocol/weston-test-client-protocol.h
Bryce Harrington892122e2015-09-24 14:31:44 -07001188libtest_client_la_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS) $(CAIRO_CFLAGS)
1189libtest_client_la_LIBADD = $(TEST_CLIENT_LIBS) $(CAIRO_LIBS) libshared.la libtest-runner.la
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001190
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001191
1192#
1193# Internal tests - tests functionality of the testsuite itself
1194#
1195
1196internal_screenshot_weston_SOURCES = tests/internal-screenshot-test.c
Bryce Harrington892122e2015-09-24 14:31:44 -07001197internal_screenshot_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1198internal_screenshot_weston_LDADD = libtest-client.la
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001199
1200
1201#
1202# Weston Tests
1203#
1204
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001205bad_buffer_weston_SOURCES = tests/bad-buffer-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001206bad_buffer_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001207bad_buffer_weston_LDADD = libtest-client.la
1208
1209keyboard_weston_SOURCES = tests/keyboard-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001210keyboard_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001211keyboard_weston_LDADD = libtest-client.la
1212
1213event_weston_SOURCES = tests/event-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001214event_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001215event_weston_LDADD = libtest-client.la
1216
1217button_weston_SOURCES = tests/button-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001218button_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001219button_weston_LDADD = libtest-client.la
1220
Marek Chalupa5fd81402015-03-30 09:21:29 -04001221devices_weston_SOURCES = tests/devices-test.c
1222devices_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1223devices_weston_LDADD = libtest-client.la
1224
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001225text_weston_SOURCES = tests/text-test.c
1226nodist_text_weston_SOURCES = \
Jonas Ådahl3bcba342015-11-17 16:00:29 +08001227 protocol/text-input-unstable-v1-protocol.c \
1228 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001229text_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001230text_weston_LDADD = libtest-client.la
1231
1232subsurface_weston_SOURCES = tests/subsurface-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001233subsurface_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001234subsurface_weston_LDADD = libtest-client.la
1235
Jon A. Cruzb09da242015-06-16 13:15:13 -07001236presentation_weston_SOURCES = \
1237 tests/presentation-test.c \
1238 shared/helpers.h
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001239nodist_presentation_weston_SOURCES = \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +02001240 protocol/presentation-time-protocol.c \
1241 protocol/presentation-time-client-protocol.h
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001242presentation_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1243presentation_weston_LDADD = libtest-client.la
1244
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +03001245roles_weston_SOURCES = tests/roles-test.c
1246roles_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1247roles_weston_LDADD = libtest-client.la
1248
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001249if ENABLE_EGL
1250weston_tests += buffer-count.weston
1251buffer_count_weston_SOURCES = tests/buffer-count-test.c
Derek Foreman4ff38742015-06-18 11:43:11 -05001252buffer_count_weston_CFLAGS = $(AM_CFLAGS) $(EGL_TESTS_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001253buffer_count_weston_LDADD = libtest-client.la $(EGL_TESTS_LIBS)
1254endif
1255
1256if ENABLE_XWAYLAND_TEST
Pekka Paalanenf9a26262014-05-07 16:26:29 +03001257weston_tests += xwayland-test.weston
1258xwayland_test_weston_SOURCES = tests/xwayland-test.c
Derek Foreman4ff38742015-06-18 11:43:11 -05001259xwayland_test_weston_CFLAGS = $(AM_CFLAGS) $(XWAYLAND_TEST_CFLAGS)
Pekka Paalanenf9a26262014-05-07 16:26:29 +03001260xwayland_test_weston_LDADD = libtest-client.la $(XWAYLAND_TEST_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001261endif
1262
1263matrix_test_SOURCES = \
1264 tests/matrix-test.c \
1265 shared/matrix.c \
1266 shared/matrix.h
1267matrix_test_CPPFLAGS = -DUNIT_TEST
1268matrix_test_LDADD = -lm -lrt
1269
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001270if ENABLE_IVI_SHELL
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001271module_tests += \
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001272 ivi-layout-internal-test.la \
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001273 ivi-layout-test.la
1274
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001275ivi_layout_internal_test_la_LIBADD = $(COMPOSITOR_LIBS)
1276ivi_layout_internal_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001277ivi_layout_internal_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001278ivi_layout_internal_test_la_SOURCES = \
1279 tests/ivi_layout-internal-test.c
1280
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001281ivi_layout_test_la_LIBADD = $(COMPOSITOR_LIBS)
1282ivi_layout_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001283ivi_layout_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001284ivi_layout_test_la_SOURCES = \
1285 tests/ivi_layout-test-plugin.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001286 tests/ivi-test.h \
1287 shared/helpers.h
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001288nodist_ivi_layout_test_la_SOURCES = \
1289 protocol/weston-test-protocol.c \
1290 protocol/weston-test-server-protocol.h
1291
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001292ivi_tests += \
1293 ivi-shell-app.weston
1294
1295ivi_shell_app_weston_SOURCES = tests/ivi-shell-app-test.c
1296nodist_ivi_shell_app_weston_SOURCES = \
1297 protocol/ivi-application-protocol.c \
1298 protocol/ivi-application-client-protocol.h
1299ivi_shell_app_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1300ivi_shell_app_weston_LDADD = libtest-client.la
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001301
1302noinst_PROGRAMS += ivi-layout.ivi
1303
1304ivi_layout_ivi_SOURCES = \
1305 tests/ivi_layout-test.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001306 tests/ivi-test.h \
1307 shared/helpers.h
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001308nodist_ivi_layout_ivi_SOURCES = \
1309 protocol/ivi-application-protocol.c \
1310 protocol/ivi-application-client-protocol.h
1311ivi_layout_ivi_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1312ivi_layout_ivi_LDADD = libtest-client.la
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001313endif
1314
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001315if BUILD_SETBACKLIGHT
1316noinst_PROGRAMS += setbacklight
1317setbacklight_SOURCES = \
1318 tests/setbacklight.c \
1319 src/libbacklight.c \
1320 src/libbacklight.h
1321setbacklight_CFLAGS = $(AM_CFLAGS) $(SETBACKLIGHT_CFLAGS)
1322setbacklight_LDADD = $(SETBACKLIGHT_LIBS)
1323endif
1324
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001325all-local: zuctest$(EXEEXT)
1326
1327noinst_PROGRAMS += zuctest$(EXEEXT)
1328
1329zuctest_LDADD = \
1330 libzunitc.la \
1331 libzunitcmain.la
1332
1333zuctest_CFLAGS = \
1334 $(AM_CFLAGS) \
1335 -I$(top_srcdir)/tools/zunitc/inc
1336
1337zuctest_SOURCES = \
1338 tools/zunitc/test/fixtures_test.c \
1339 tools/zunitc/test/zunitc_test.c
1340
Derek Foreman1ce2ef52015-05-26 10:21:03 -05001341EXTRA_DIST += \
1342 tests/weston-tests-env \
1343 tests/internal-screenshot.ini \
1344 tests/reference/internal-screenshot-bad-00.png \
1345 tests/reference/internal-screenshot-good-00.png
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001346
1347BUILT_SOURCES += \
Derek Foremanf6a65922015-02-24 09:32:14 -06001348 protocol/weston-test-protocol.c \
1349 protocol/weston-test-server-protocol.h \
1350 protocol/weston-test-client-protocol.h \
Jonas Ådahl3bcba342015-11-17 16:00:29 +08001351 protocol/text-input-unstable-v1-protocol.c \
1352 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001353
Kristian Høgsbergcd312752014-02-01 00:38:15 -08001354EXTRA_DIST += \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +08001355 protocol/weston-desktop-shell.xml \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +08001356 protocol/weston-screenshooter.xml \
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001357 protocol/text-cursor-position.xml \
Derek Foremanf6a65922015-02-24 09:32:14 -06001358 protocol/weston-test.xml \
Nobuhiko Tanibatabff1b4a2014-11-27 13:21:34 +09001359 protocol/scaler.xml \
Nobuhiko Tanibata68cfabb2014-11-27 13:22:53 +09001360 protocol/ivi-application.xml \
Jonas Ådahl57e48f02015-11-17 16:00:28 +08001361 protocol/ivi-hmi-controller.xml
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001362
Pekka Paalanen312fe5f2015-02-09 11:23:48 +02001363#
1364# manual test modules in tests subdirectory
1365#
1366
1367noinst_LTLIBRARIES += \
1368 surface-screenshot.la
1369
1370surface_screenshot_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
1371surface_screenshot_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001372surface_screenshot_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanen312fe5f2015-02-09 11:23:48 +02001373surface_screenshot_la_SOURCES = tests/surface-screenshot.c
1374
1375
1376#
1377# Documentation
1378#
1379
Kristian Høgsberg68c5c102014-01-27 22:33:04 -08001380man_MANS = weston.1 weston.ini.5
1381
1382if ENABLE_DRM_COMPOSITOR
1383man_MANS += weston-drm.7
1384endif
1385
1386MAN_SUBSTS = \
1387 -e 's|__weston_native_backend__|$(WESTON_NATIVE_BACKEND)|g' \
1388 -e 's|__weston_modules_dir__|$(pkglibdir)|g' \
1389 -e 's|__weston_shell_client__|$(WESTON_SHELL_CLIENT)|g' \
1390 -e 's|__version__|$(PACKAGE_VERSION)|g'
1391
1392SUFFIXES = .1 .5 .7 .man
1393
1394%.1 %.5 %.7 : man/%.man
1395 $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
1396
1397EXTRA_DIST += \
1398 man/weston.man \
1399 man/weston-drm.man \
1400 man/weston.ini.man
1401
1402CLEANFILES += $(man_MANS)
1403
Jon A. Cruz179c1862015-07-15 19:22:43 -07001404if ENABLE_DEVDOCS
1405DOXYGEN_INDICES = docs/developer/html/index.html docs/tools/html/index.html
1406
1407docs/developer/html/index.html: doc/doxygen/tooldev.doxygen | docs/developer
1408 cd doc/doxygen && $(DOXYGEN) tooldev.doxygen
1409
1410docs/tools/html/index.html: doc/doxygen/tools.doxygen | docs/tools
1411 cd doc/doxygen && $(DOXYGEN) tools.doxygen
1412endif
1413
1414DOCDIRS = \
1415 docs/developer \
1416 docs/tools
1417
1418$(DOCDIRS):
1419 $(MKDIR_P) $@
1420
1421.PHONY: doc $(DOXYGEN_INDICES)
1422
1423doc: $(DOXYGEN_INDICES)
1424
Jonas Ådahl496adb32015-11-17 16:00:27 +08001425.SECONDEXPANSION:
1426
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001427define protostability
Pekka Paalanen35552aa2016-02-18 16:56:13 +02001428$(if $(findstring unstable,$1),unstable,stable)
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001429endef
1430
1431define protoname
1432$(shell echo $1 | sed 's/\([a-z\-]\+\)-[a-z]\+-v[0-9]\+/\1/')
1433endef
1434
1435protocol/%-protocol.c : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001436 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
1437
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001438protocol/%-server-protocol.h : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001439 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
1440
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001441protocol/%-client-protocol.h : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001442 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@
1443
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001444protocol/%-protocol.c : $(top_srcdir)/protocol/%.xml
1445 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001446
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001447protocol/%-server-protocol.h : $(top_srcdir)/protocol/%.xml
1448 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001449
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001450protocol/%-client-protocol.h : $(top_srcdir)/protocol/%.xml
1451 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@