blob: 9ffe9c837d8996fbd441b5fc745738cae990e8e6 [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 =
Giulio Camuffo179fcda2016-06-02 21:48:14 +03008libweston_moduledir = $(libdir)/libweston-${LIBWESTON_ABI_VERSION}
9libweston_module_LTLIBRARIES =
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080010noinst_LTLIBRARIES =
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -080011BUILT_SOURCES =
Kristian Høgsberge895f142014-01-27 21:46:30 -080012
Derek Foreman2ef9e812015-02-09 09:57:29 -060013AM_DISTCHECK_CONFIGURE_FLAGS = --disable-setuid-install
Kristian Høgsberg24639cc2013-02-25 13:03:15 -050014
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090015EXTRA_DIST = weston.ini.in ivi-shell/weston.ini.in
Neil Robertse3de16e2013-11-22 16:46:00 +000016
17weston.ini : $(srcdir)/weston.ini.in
18 $(AM_V_GEN)$(SED) \
19 -e 's|@bindir[@]|$(bindir)|g' \
20 -e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
21 -e 's|@libexecdir[@]|$(libexecdir)|g' \
22 $< > $@
23
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090024ivi-shell/weston.ini : $(srcdir)/ivi-shell/weston.ini.in
Ross Burton2eff22b2015-07-17 12:33:45 +010025 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(SED) \
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090026 -e 's|@bindir[@]|$(bindir)|g' \
27 -e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
Pekka Paalanen8cb25872015-03-24 14:09:57 +020028 -e 's|@abs_top_srcdir[@]|$(abs_top_srcdir)|g' \
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090029 -e 's|@libexecdir[@]|$(libexecdir)|g' \
Pekka Paalanenf3a34532015-03-24 13:51:05 +020030 -e 's|@plugin_prefix[@]||g' \
31 $< > $@
32
33tests/weston-ivi.ini : $(srcdir)/ivi-shell/weston.ini.in
Ross Burton2eff22b2015-07-17 12:33:45 +010034 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(SED) \
Pekka Paalanenf3a34532015-03-24 13:51:05 +020035 -e 's|@bindir[@]|$(bindir)|g' \
36 -e 's|@abs_top_builddir[@]|$(abs_top_builddir)|g' \
Pekka Paalanen8cb25872015-03-24 14:09:57 +020037 -e 's|@abs_top_srcdir[@]|$(abs_top_srcdir)|g' \
Derek Foremanbbdd9bc2015-06-16 13:30:35 -050038 -e 's|@libexecdir[@]|$(abs_builddir)|g' \
Pekka Paalanenf3a34532015-03-24 13:51:05 +020039 -e 's|@plugin_prefix[@]|$(abs_top_builddir)/.libs/|g' \
Nobuhiko Tanibata45d4cbf2014-11-27 13:24:16 +090040 $< > $@
41
42all-local : weston.ini ivi-shell/weston.ini
Kristian Høgsberg98463742013-12-16 23:12:46 -080043
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080044AM_CFLAGS = $(GCC_CFLAGS)
45
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080046AM_CPPFLAGS = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +030047 -I$(top_builddir)/libweston \
Emil Velikov4ad45ca2016-07-04 14:57:11 +010048 -I$(top_srcdir)/libweston \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -080049 -I$(top_builddir)/clients \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -080050 -I$(top_builddir)/tests \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080051 -I$(top_srcdir)/shared \
Quentin Glidic088ba5e2014-02-01 21:39:12 +010052 -I$(top_builddir)/protocol \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080053 -DDATADIR='"$(datadir)"' \
Giulio Camuffo179fcda2016-06-02 21:48:14 +030054 -DLIBWESTON_MODULEDIR='"$(libweston_moduledir)"' \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -080055 -DLIBEXECDIR='"$(libexecdir)"' \
56 -DBINDIR='"$(bindir)"'
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080057
Pekka Paalanenf3a34532015-03-24 13:51:05 +020058CLEANFILES = weston.ini \
59 ivi-shell/weston.ini \
60 tests/weston-ivi.ini \
Derek Foreman1ce2ef52015-05-26 10:21:03 -050061 internal-screenshot-00.png \
Pekka Paalanenf3a34532015-03-24 13:51:05 +020062 $(BUILT_SOURCES)
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -080063
Giulio Camuffo9e445982016-06-02 21:48:15 +030064lib_LTLIBRARIES = libweston.la
65libweston_la_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON
66libweston_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(LIBUNWIND_CFLAGS)
67libweston_la_LIBADD = $(COMPOSITOR_LIBS) $(LIBUNWIND_LIBS) \
Giulio Camuffo8aedf7b2016-06-02 21:48:12 +030068 $(DLOPEN_LIBS) -lm $(CLOCK_GETTIME_LIBS) \
69 $(LIBINPUT_BACKEND_LIBS) libshared.la
Giulio Camuffo9e445982016-06-02 21:48:15 +030070libweston_la_LDFLAGS = -release ${LIBWESTON_ABI_VERSION}
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080071
Giulio Camuffo9e445982016-06-02 21:48:15 +030072libweston_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +030073 libweston/git-version.h \
74 libweston/log.c \
75 libweston/compositor.c \
76 libweston/compositor.h \
77 libweston/compositor-drm.h \
78 libweston/compositor-fbdev.h \
79 libweston/compositor-headless.h \
80 libweston/compositor-rdp.h \
81 libweston/compositor-wayland.h \
82 libweston/compositor-x11.h \
83 libweston/input.c \
84 libweston/data-device.c \
85 libweston/screenshooter.c \
86 libweston/clipboard.c \
87 libweston/zoom.c \
88 libweston/bindings.c \
89 libweston/animation.c \
90 libweston/noop-renderer.c \
91 libweston/pixman-renderer.c \
92 libweston/pixman-renderer.h \
Pekka Paalanen827b5d22016-06-29 11:54:26 +020093 libweston/plugin-registry.c \
94 libweston/plugin-registry.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +030095 libweston/timeline.c \
96 libweston/timeline.h \
97 libweston/timeline-object.h \
98 libweston/linux-dmabuf.c \
99 libweston/linux-dmabuf.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700100 shared/helpers.h \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800101 shared/matrix.c \
102 shared/matrix.h \
Pekka Paalanenaa21f622015-07-03 15:44:50 +0300103 shared/timespec-util.h \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800104 shared/zalloc.h \
Jonny Lamb51a7ae52015-03-20 15:26:51 +0100105 shared/platform.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300106 libweston/weston-egl-ext.h
Egor Starkov7ce2e972015-09-25 18:00:27 +0300107
108if SYSTEMD_NOTIFY_SUPPORT
109module_LTLIBRARIES += systemd-notify.la
110systemd_notify_la_LDFLAGS = -module -avoid-version
111systemd_notify_la_LIBADD = $(SYSTEMD_DAEMON_LIBS)
112systemd_notify_la_CFLAGS = \
Pekka Paalanenaff703e2016-04-05 14:08:11 +0300113 $(COMPOSITOR_CFLAGS) \
114 $(SYSTEMD_DAEMON_CFLAGS) \
Egor Starkov7ce2e972015-09-25 18:00:27 +0300115 $(PIXMAN_CFLAGS) \
116 $(AM_CFLAGS)
117systemd_notify_la_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300118 compositor/systemd-notify.c \
Egor Starkov7ce2e972015-09-25 18:00:27 +0300119 shared/helpers.h \
120 shared/zalloc.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300121 libweston/compositor.h
Egor Starkov7ce2e972015-09-25 18:00:27 +0300122endif
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800123
Giulio Camuffo9e445982016-06-02 21:48:15 +0300124nodist_libweston_la_SOURCES = \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800125 protocol/weston-screenshooter-protocol.c \
126 protocol/weston-screenshooter-server-protocol.h \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800127 protocol/text-cursor-position-protocol.c \
128 protocol/text-cursor-position-server-protocol.h \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800129 protocol/text-input-unstable-v1-protocol.c \
130 protocol/text-input-unstable-v1-server-protocol.h \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800131 protocol/input-method-unstable-v1-protocol.c \
132 protocol/input-method-unstable-v1-server-protocol.h \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200133 protocol/presentation-time-protocol.c \
134 protocol/presentation-time-server-protocol.h \
Pekka Paalanene95ad5c2016-04-15 14:47:08 +0300135 protocol/viewporter-protocol.c \
136 protocol/viewporter-server-protocol.h \
Jonas Ådahl57e48f02015-11-17 16:00:28 +0800137 protocol/linux-dmabuf-unstable-v1-protocol.c \
Jonas Ådahl30d61d82014-10-22 21:21:17 +0200138 protocol/linux-dmabuf-unstable-v1-server-protocol.h \
139 protocol/relative-pointer-unstable-v1-protocol.c \
140 protocol/relative-pointer-unstable-v1-server-protocol.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800141
Giulio Camuffo9e445982016-06-02 21:48:15 +0300142BUILT_SOURCES += $(nodist_libweston_la_SOURCES)
143
144bin_PROGRAMS += weston
145
146weston_LDFLAGS = -export-dynamic
147weston_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON \
Giulio Camuffo9c764df2016-06-29 11:54:27 +0200148 -DMODULEDIR='"$(moduledir)"' \
149 -DXSERVER_PATH='"@XSERVER_PATH@"'
Giulio Camuffo9e445982016-06-02 21:48:15 +0300150weston_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(LIBUNWIND_CFLAGS)
151weston_LDADD = $(COMPOSITOR_LIBS) $(LIBUNWIND_LIBS) \
152 $(DLOPEN_LIBS) $(LIBINPUT_BACKEND_LIBS) \
153 -lm libshared.la libweston.la
154
155weston_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300156 compositor/main.c \
157 compositor/weston-screenshooter.c \
Giulio Camuffo9c764df2016-06-29 11:54:27 +0200158 compositor/text-backend.c \
159 compositor/xwayland.c
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800160
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800161# Track this dependency explicitly instead of using BUILT_SOURCES. We
162# add BUILT_SOURCES to CLEANFILES, but we want to keep git-version.h
163# in case we're building from tarballs.
164
Emil Velikova8840242016-07-04 14:57:12 +0100165compositor/main.c : $(top_builddir)/libweston/git-version.h
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300166libweston/compositor.c : $(top_builddir)/libweston/git-version.h
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800167
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800168noinst_LTLIBRARIES += \
169 libsession-helper.la
170
171libsession_helper_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300172 libweston/launcher-util.c \
173 libweston/launcher-util.h \
174 libweston/launcher-impl.h \
175 libweston/weston-launch.h \
176 libweston/launcher-weston-launch.c \
177 libweston/launcher-direct.c
Derek Foreman4ff38742015-06-18 11:43:11 -0500178libsession_helper_la_CFLAGS = $(AM_CFLAGS) $(LIBDRM_CFLAGS) $(PIXMAN_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800179libsession_helper_la_LIBADD = $(LIBDRM_LIBS)
180
181if ENABLE_DBUS
182if HAVE_SYSTEMD_LOGIN
183libsession_helper_la_SOURCES += \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300184 libweston/dbus.h \
185 libweston/dbus.c \
186 libweston/launcher-logind.c
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800187libsession_helper_la_CFLAGS += $(SYSTEMD_LOGIN_CFLAGS) $(DBUS_CFLAGS)
188libsession_helper_la_LIBADD += $(SYSTEMD_LOGIN_LIBS) $(DBUS_LIBS)
189endif
190endif
191
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800192if HAVE_GIT_REPO
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300193libweston/git-version.h : $(top_srcdir)/.git/logs/HEAD
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800194 $(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 -0800195else
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300196libweston/git-version.h :
Kristian Høgsberg1d2dd072014-02-03 10:55:51 -0800197 $(AM_V_GEN)echo "#define BUILD_ID \"unknown (not built from git or tarball)\"" > $@
198
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800199endif
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800200
201.FORCE :
202
203if BUILD_WESTON_LAUNCH
204bin_PROGRAMS += weston-launch
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300205weston_launch_SOURCES = libweston/weston-launch.c libweston/weston-launch.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800206weston_launch_CPPFLAGS = -DBINDIR='"$(bindir)"'
207weston_launch_CFLAGS= \
Derek Foreman4ff38742015-06-18 11:43:11 -0500208 $(AM_CFLAGS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800209 $(PAM_CFLAGS) \
210 $(SYSTEMD_LOGIN_CFLAGS) \
211 $(LIBDRM_CFLAGS)
212weston_launch_LDADD = $(PAM_LIBS) $(SYSTEMD_LOGIN_LIBS) $(LIBDRM_LIBS)
213
214if ENABLE_SETUID_INSTALL
215install-exec-hook:
Jon A. Cruz90f23ca2015-04-09 17:52:56 -0700216 can_suid_files=no; \
217 chown root $(DESTDIR)$(bindir)/weston-launch \
218 && chmod u+s $(DESTDIR)$(bindir)/weston-launch \
219 && can_suid_files=yes;\
Derek Foreman6d116792015-04-10 11:55:27 -0500220 if test $$can_suid_files = no; then \
Jon A. Cruz90f23ca2015-04-09 17:52:56 -0700221 echo 'Error: unable to unable to change ownership/setuid on weston-launch.'; \
222 echo 'To skip this step, re-run ./configure using --disable-setuid-install'; \
223 false; \
224 fi
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800225endif
226
227endif # BUILD_WESTON_LAUNCH
228
229pkgconfigdir = $(libdir)/pkgconfig
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300230pkgconfig_DATA = compositor/weston.pc libweston/libweston-${LIBWESTON_ABI_VERSION}.pc
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800231
Lubomir Rintel4f4b47a2014-12-28 14:20:49 +0100232wayland_sessiondir = $(datadir)/wayland-sessions
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300233dist_wayland_session_DATA = compositor/weston.desktop
Lubomir Rintel4f4b47a2014-12-28 14:20:49 +0100234
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300235libwestonincludedir = $(includedir)/libweston-${LIBWESTON_ABI_VERSION}
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300236libwestoninclude_HEADERS = \
237 libweston/version.h \
238 libweston/compositor.h \
239 libweston/compositor-drm.h \
240 libweston/compositor-fbdev.h \
241 libweston/compositor-headless.h \
242 libweston/compositor-rdp.h \
243 libweston/compositor-wayland.h \
244 libweston/compositor-x11.h \
Pekka Paalanen827b5d22016-06-29 11:54:26 +0200245 libweston/plugin-registry.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300246 libweston/timeline-object.h \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800247 shared/matrix.h \
248 shared/config-parser.h \
Emil Velikovcbcf5452016-07-04 15:34:17 +0100249 shared/zalloc.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800250
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300251westonincludedir = $(includedir)/weston
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300252westoninclude_HEADERS = compositor/weston.h
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300253
Ucan, Emre \(ADITG/SW1\)ae2541d2015-10-15 14:51:43 +0000254if ENABLE_IVI_SHELL
255westoninclude_HEADERS += \
256 ivi-shell/ivi-layout-export.h
257endif
258
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800259if ENABLE_EGL
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300260libweston_module_LTLIBRARIES += gl-renderer.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800261gl_renderer_la_LDFLAGS = -module -avoid-version
262gl_renderer_la_LIBADD = $(COMPOSITOR_LIBS) $(EGL_LIBS)
263gl_renderer_la_CFLAGS = \
264 $(COMPOSITOR_CFLAGS) \
265 $(EGL_CFLAGS) \
Pekka Paalanena3525802014-06-12 16:49:29 +0300266 $(GL_RENDERER_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500267 $(AM_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800268gl_renderer_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300269 libweston/gl-renderer.h \
270 libweston/gl-renderer.c \
271 libweston/vertex-clipping.c \
272 libweston/vertex-clipping.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700273 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800274endif
275
276if ENABLE_X11_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300277libweston_module_LTLIBRARIES += x11-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800278x11_backend_la_LDFLAGS = -module -avoid-version
279x11_backend_la_LIBADD = $(COMPOSITOR_LIBS) $(X11_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800280 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800281x11_backend_la_CFLAGS = \
282 $(COMPOSITOR_CFLAGS) \
283 $(EGL_CFLAGS) \
284 $(PIXMAN_CFLAGS) \
285 $(CAIRO_CFLAGS) \
286 $(X11_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500287 $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700288x11_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300289 libweston/compositor-x11.c \
290 libweston/compositor-x11.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700291 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800292endif
293
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100294INPUT_BACKEND_LIBS = $(LIBINPUT_BACKEND_LIBS)
Peter Hutterer823ad332014-11-26 07:06:31 +1000295INPUT_BACKEND_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300296 libweston/libinput-seat.c \
297 libweston/libinput-seat.h \
298 libweston/libinput-device.c \
299 libweston/libinput-device.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700300 shared/helpers.h
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100301
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800302if ENABLE_DRM_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300303libweston_module_LTLIBRARIES += drm-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800304drm_backend_la_LDFLAGS = -module -avoid-version
305drm_backend_la_LIBADD = \
306 $(COMPOSITOR_LIBS) \
307 $(DRM_COMPOSITOR_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100308 $(INPUT_BACKEND_LIBS) \
Gustavo Zacarias34d59852016-04-21 11:18:48 -0300309 libshared.la \
310 $(CLOCK_GETTIME_LIBS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800311 libsession-helper.la
312drm_backend_la_CFLAGS = \
313 $(COMPOSITOR_CFLAGS) \
314 $(EGL_CFLAGS) \
315 $(DRM_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500316 $(AM_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800317drm_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300318 libweston/compositor-drm.c \
319 libweston/compositor-drm.h \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100320 $(INPUT_BACKEND_SOURCES) \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700321 shared/helpers.h \
Mario Kleinerf507ec32015-06-21 21:25:14 +0200322 shared/timespec-util.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300323 libweston/libbacklight.c \
324 libweston/libbacklight.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800325
326if ENABLE_VAAPI_RECORDER
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300327drm_backend_la_SOURCES += libweston/vaapi-recorder.c libweston/vaapi-recorder.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800328drm_backend_la_LIBADD += $(LIBVA_LIBS)
329drm_backend_la_CFLAGS += $(LIBVA_CFLAGS)
330endif
331endif
332
333if ENABLE_WAYLAND_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300334libweston_module_LTLIBRARIES += wayland-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800335wayland_backend_la_LDFLAGS = -module -avoid-version
336wayland_backend_la_LIBADD = \
337 $(COMPOSITOR_LIBS) \
338 $(WAYLAND_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800339 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800340wayland_backend_la_CFLAGS = \
341 $(COMPOSITOR_CFLAGS) \
342 $(EGL_CFLAGS) \
343 $(PIXMAN_CFLAGS) \
344 $(CAIRO_CFLAGS) \
345 $(WAYLAND_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500346 $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700347wayland_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300348 libweston/compositor-wayland.c \
349 libweston/compositor-wayland.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700350 shared/helpers.h
Jason Ekstrand53ee0dc2014-04-02 19:53:54 -0500351nodist_wayland_backend_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800352 protocol/fullscreen-shell-unstable-v1-protocol.c \
353 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800354endif
355
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800356if ENABLE_HEADLESS_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300357libweston_module_LTLIBRARIES += headless-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800358headless_backend_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800359headless_backend_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500360headless_backend_la_CFLAGS = $(COMPOSITOR_CFLAGS) $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700361headless_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300362 libweston/compositor-headless.c \
363 libweston/compositor-headless.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700364 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800365endif
366
367if ENABLE_FBDEV_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300368libweston_module_LTLIBRARIES += fbdev-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800369fbdev_backend_la_LDFLAGS = -module -avoid-version
370fbdev_backend_la_LIBADD = \
371 $(COMPOSITOR_LIBS) \
372 $(FBDEV_COMPOSITOR_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100373 $(INPUT_BACKEND_LIBS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800374 libsession-helper.la \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800375 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800376fbdev_backend_la_CFLAGS = \
377 $(COMPOSITOR_CFLAGS) \
378 $(EGL_CFLAGS) \
379 $(FBDEV_COMPOSITOR_CFLAGS) \
380 $(PIXMAN_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500381 $(AM_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800382fbdev_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300383 libweston/compositor-fbdev.c \
384 libweston/compositor-fbdev.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700385 shared/helpers.h \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100386 $(INPUT_BACKEND_SOURCES)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800387endif
388
389if ENABLE_RDP_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300390libweston_module_LTLIBRARIES += rdp-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800391rdp_backend_la_LDFLAGS = -module -avoid-version
392rdp_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
393 $(RDP_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800394 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800395rdp_backend_la_CFLAGS = \
396 $(COMPOSITOR_CFLAGS) \
397 $(RDP_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500398 $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700399rdp_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300400 libweston/compositor-rdp.c \
401 libweston/compositor-rdp.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700402 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800403endif
404
405if HAVE_LCMS
406module_LTLIBRARIES += cms-static.la
407cms_static_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800408cms_static_la_LIBADD = $(COMPOSITOR_LIBS) $(LCMS_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500409cms_static_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(LCMS_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800410cms_static_la_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300411 compositor/cms-static.c \
412 compositor/cms-helper.c \
413 compositor/cms-helper.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700414 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800415if ENABLE_COLORD
416module_LTLIBRARIES += cms-colord.la
417cms_colord_la_LDFLAGS = -module -avoid-version
418cms_colord_la_LIBADD = $(COMPOSITOR_LIBS) $(COLORD_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500419cms_colord_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(COLORD_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800420cms_colord_la_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300421 compositor/cms-colord.c \
422 compositor/cms-helper.c \
423 compositor/cms-helper.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700424 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800425endif
426endif
427
428noinst_PROGRAMS += spring-tool
Derek Foreman4ff38742015-06-18 11:43:11 -0500429spring_tool_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800430spring_tool_LDADD = $(COMPOSITOR_LIBS) -lm
431spring_tool_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300432 libweston/spring-tool.c \
433 libweston/animation.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800434 shared/matrix.c \
435 shared/matrix.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300436 libweston/compositor.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800437
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800438if BUILD_CLIENTS
439
440bin_PROGRAMS += weston-terminal weston-info
441
442libexec_PROGRAMS += \
443 weston-desktop-shell \
444 weston-screenshooter \
445 weston-keyboard \
446 weston-simple-im
447
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900448if ENABLE_IVI_SHELL
449libexec_PROGRAMS += \
450 weston-ivi-shell-user-interface
451endif
452
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800453demo_clients = \
454 weston-flower \
455 weston-image \
456 weston-cliptest \
457 weston-dnd \
458 weston-smoke \
459 weston-resizor \
460 weston-eventdemo \
461 weston-clickdot \
462 weston-transformed \
463 weston-fullscreen \
464 weston-stacking \
465 weston-calibrator \
466 weston-scaler
467
468if INSTALL_DEMO_CLIENTS
469bin_PROGRAMS += $(demo_clients)
470else
471noinst_PROGRAMS += $(demo_clients)
472endif
473
474
475if BUILD_SIMPLE_CLIENTS
476demo_clients += \
477 weston-simple-shm \
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500478 weston-simple-damage \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800479 weston-simple-touch \
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400480 weston-presentation-shm \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800481 weston-multi-resource
482
Kristian Høgsbergfe84a972014-02-11 14:23:19 -0800483weston_simple_shm_SOURCES = clients/simple-shm.c
484nodist_weston_simple_shm_SOURCES = \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800485 protocol/xdg-shell-unstable-v5-protocol.c \
486 protocol/xdg-shell-unstable-v5-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800487 protocol/fullscreen-shell-unstable-v1-protocol.c \
488 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Nobuhiko Tanibatafba4ea32014-11-27 13:24:29 +0900489 protocol/ivi-application-protocol.c \
490 protocol/ivi-application-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800491weston_simple_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800492weston_simple_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800493
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500494weston_simple_damage_SOURCES = clients/simple-damage.c
495nodist_weston_simple_damage_SOURCES = \
Pekka Paalanen7b69d6c2016-04-15 17:00:21 +0300496 protocol/viewporter-protocol.c \
497 protocol/viewporter-client-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800498 protocol/xdg-shell-unstable-v5-protocol.c \
499 protocol/xdg-shell-unstable-v5-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800500 protocol/fullscreen-shell-unstable-v1-protocol.c \
501 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500502weston_simple_damage_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
503weston_simple_damage_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
504
Jon A. Cruzb09da242015-06-16 13:15:13 -0700505weston_simple_touch_SOURCES = \
506 clients/simple-touch.c \
507 shared/helpers.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800508weston_simple_touch_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800509weston_simple_touch_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800510
Jon A. Cruzb09da242015-06-16 13:15:13 -0700511weston_presentation_shm_SOURCES = \
512 clients/presentation-shm.c \
513 shared/helpers.h
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400514nodist_weston_presentation_shm_SOURCES = \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200515 protocol/presentation-time-protocol.c \
516 protocol/presentation-time-client-protocol.h
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400517weston_presentation_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Gustavo Zacarias34d59852016-04-21 11:18:48 -0300518weston_presentation_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la -lm $(CLOCK_GETTIME_LIBS)
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400519
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800520weston_multi_resource_SOURCES = clients/multi-resource.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800521weston_multi_resource_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Gustavo Zacarias34d59852016-04-21 11:18:48 -0300522weston_multi_resource_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la $(CLOCK_GETTIME_LIBS) -lm
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800523endif
524
525if BUILD_SIMPLE_EGL_CLIENTS
526demo_clients += weston-simple-egl
Kristian Høgsbergfe84a972014-02-11 14:23:19 -0800527weston_simple_egl_SOURCES = clients/simple-egl.c
528nodist_weston_simple_egl_SOURCES = \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800529 protocol/xdg-shell-unstable-v5-protocol.c \
530 protocol/xdg-shell-unstable-v5-client-protocol.h \
Nobuhiko Tanibata4f01a0b2014-11-27 13:24:42 +0900531 protocol/ivi-application-protocol.c \
532 protocol/ivi-application-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800533weston_simple_egl_CFLAGS = $(AM_CFLAGS) $(SIMPLE_EGL_CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800534weston_simple_egl_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
535endif
536
Emmanuel Gil Peyrot3b65b0b2016-01-11 19:04:36 +0000537if BUILD_SIMPLE_DMABUF_INTEL_CLIENT
538demo_clients += weston-simple-dmabuf-intel
539weston_simple_dmabuf_intel_SOURCES = clients/simple-dmabuf-intel.c
540nodist_weston_simple_dmabuf_intel_SOURCES = \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800541 protocol/xdg-shell-unstable-v5-protocol.c \
542 protocol/xdg-shell-unstable-v5-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800543 protocol/fullscreen-shell-unstable-v1-protocol.c \
544 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Jonas Ådahl57e48f02015-11-17 16:00:28 +0800545 protocol/linux-dmabuf-unstable-v1-protocol.c \
546 protocol/linux-dmabuf-unstable-v1-client-protocol.h
Emmanuel Gil Peyrot3b65b0b2016-01-11 19:04:36 +0000547weston_simple_dmabuf_intel_CFLAGS = $(AM_CFLAGS) $(SIMPLE_DMABUF_INTEL_CLIENT_CFLAGS)
548weston_simple_dmabuf_intel_LDADD = $(SIMPLE_DMABUF_INTEL_CLIENT_LIBS) libshared.la
Jonas Ådahl57e48f02015-11-17 16:00:28 +0800549BUILT_SOURCES += protocol/linux-dmabuf-unstable-v1-client-protocol.h
George Kiagiadakis53868982014-06-12 16:26:49 +0200550endif
551
Emmanuel Gil Peyrot5d43af32016-01-11 19:04:38 +0000552if BUILD_SIMPLE_DMABUF_V4L_CLIENT
553demo_clients += weston-simple-dmabuf-v4l
554weston_simple_dmabuf_v4l_SOURCES = clients/simple-dmabuf-v4l.c
555nodist_weston_simple_dmabuf_v4l_SOURCES = \
556 protocol/xdg-shell-unstable-v5-protocol.c \
557 protocol/xdg-shell-unstable-v5-client-protocol.h \
558 protocol/fullscreen-shell-unstable-v1-protocol.c \
559 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
560 protocol/linux-dmabuf-unstable-v1-protocol.c \
561 protocol/linux-dmabuf-unstable-v1-client-protocol.h
562weston_simple_dmabuf_v4l_CFLAGS = $(AM_CFLAGS) $(SIMPLE_DMABUF_V4L_CLIENT_CFLAGS)
563weston_simple_dmabuf_v4l_LDADD = $(SIMPLE_DMABUF_V4L_CLIENT_LIBS) libshared.la
564BUILT_SOURCES += protocol/linux-dmabuf-unstable-v1-client-protocol.h
565endif
566
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800567noinst_LTLIBRARIES += libtoytoolkit.la
568
569libtoytoolkit_la_SOURCES = \
570 clients/window.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700571 clients/window.h \
572 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800573
574nodist_libtoytoolkit_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100575 protocol/text-cursor-position-protocol.c \
576 protocol/text-cursor-position-client-protocol.h \
Pekka Paalanen73511002016-04-15 16:53:41 +0300577 protocol/viewporter-protocol.c \
578 protocol/viewporter-client-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800579 protocol/xdg-shell-unstable-v5-protocol.c \
580 protocol/xdg-shell-unstable-v5-client-protocol.h \
Nobuhiko Tanibatabff1b4a2014-11-27 13:21:34 +0900581 protocol/ivi-application-protocol.c \
582 protocol/ivi-application-client-protocol.h
Jasper St. Pierre0790e392013-12-09 14:58:00 -0500583
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800584BUILT_SOURCES += $(nodist_libtoytoolkit_la_SOURCES)
585
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800586
587libtoytoolkit_la_LIBADD = \
588 $(CLIENT_LIBS) \
589 $(CAIRO_EGL_LIBS) \
Gustavo Zacarias34d59852016-04-21 11:18:48 -0300590 libshared-cairo.la $(CLOCK_GETTIME_LIBS) -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800591libtoytoolkit_la_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(CAIRO_EGL_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800592
593weston_flower_SOURCES = clients/flower.c
594weston_flower_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800595weston_flower_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800596
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100597weston_screenshooter_SOURCES = \
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800598 clients/screenshot.c
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800599nodist_weston_screenshooter_SOURCES = \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800600 protocol/weston-screenshooter-protocol.c \
601 protocol/weston-screenshooter-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800602weston_screenshooter_LDADD = $(CLIENT_LIBS) libshared.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800603weston_screenshooter_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800604
Jon A. Cruzb09da242015-06-16 13:15:13 -0700605weston_terminal_SOURCES = \
606 clients/terminal.c \
607 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800608weston_terminal_LDADD = libtoytoolkit.la -lutil
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800609weston_terminal_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800610
611weston_image_SOURCES = clients/image.c
612weston_image_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800613weston_image_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800614
Pekka Paalanen461e93c2014-08-20 11:58:47 +0300615weston_cliptest_SOURCES = \
616 clients/cliptest.c \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300617 libweston/vertex-clipping.c \
618 libweston/vertex-clipping.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800619weston_cliptest_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800620weston_cliptest_LDADD = libtoytoolkit.la
621
Jon A. Cruzb09da242015-06-16 13:15:13 -0700622weston_dnd_SOURCES = \
623 clients/dnd.c \
624 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800625weston_dnd_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800626weston_dnd_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800627
628weston_smoke_SOURCES = clients/smoke.c
629weston_smoke_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800630weston_smoke_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800631
632weston_resizor_SOURCES = clients/resizor.c
633weston_resizor_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800634weston_resizor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800635
636weston_scaler_SOURCES = clients/scaler.c
637weston_scaler_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800638weston_scaler_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800639
640if HAVE_CAIRO_GLESV2
641demo_clients += weston-nested weston-nested-client
642
Jon A. Cruzb09da242015-06-16 13:15:13 -0700643weston_nested_SOURCES = \
644 clients/nested.c \
645 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800646weston_nested_LDADD = libtoytoolkit.la $(SERVER_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800647weston_nested_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800648
649weston_nested_client_SOURCES = clients/nested-client.c
650weston_nested_client_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800651weston_nested_client_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800652endif
653
Jon A. Cruzb09da242015-06-16 13:15:13 -0700654weston_eventdemo_SOURCES = \
655 clients/eventdemo.c \
656 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800657weston_eventdemo_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800658weston_eventdemo_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800659
Jon A. Cruzb09da242015-06-16 13:15:13 -0700660weston_clickdot_SOURCES = \
661 clients/clickdot.c \
662 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800663weston_clickdot_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800664weston_clickdot_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800665
666weston_transformed_SOURCES = clients/transformed.c
667weston_transformed_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800668weston_transformed_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800669
670weston_fullscreen_SOURCES = clients/fullscreen.c
Jason Ekstrand2bb72fe2014-04-02 19:53:52 -0500671nodist_weston_fullscreen_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800672 protocol/fullscreen-shell-unstable-v1-protocol.c \
673 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800674weston_fullscreen_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800675weston_fullscreen_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800676
Jon A. Cruzb09da242015-06-16 13:15:13 -0700677weston_stacking_SOURCES = \
678 clients/stacking.c \
679 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800680weston_stacking_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800681weston_stacking_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800682
Jon A. Cruzb09da242015-06-16 13:15:13 -0700683weston_calibrator_SOURCES = \
684 clients/calibrator.c \
685 shared/helpers.h \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800686 shared/matrix.c \
687 shared/matrix.h
688weston_calibrator_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800689weston_calibrator_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800690
691if BUILD_SUBSURFACES_CLIENT
692demo_clients += weston-subsurfaces
Jon A. Cruzb09da242015-06-16 13:15:13 -0700693weston_subsurfaces_SOURCES = \
694 clients/subsurfaces.c \
695 shared/helpers.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800696weston_subsurfaces_CFLAGS = \
697 $(AM_CFLAGS) \
698 $(SIMPLE_EGL_CLIENT_CFLAGS) \
699 $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800700weston_subsurfaces_LDADD = libtoytoolkit.la $(SIMPLE_EGL_CLIENT_LIBS) -lm
701endif
702
703if HAVE_PANGO
704demo_clients += weston-editor
Jon A. Cruzb09da242015-06-16 13:15:13 -0700705weston_editor_SOURCES = \
706 clients/editor.c \
707 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800708nodist_weston_editor_SOURCES = \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800709 protocol/text-input-unstable-v1-protocol.c \
710 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800711weston_editor_LDADD = libtoytoolkit.la $(PANGO_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800712weston_editor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(PANGO_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800713endif
714
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800715weston_keyboard_SOURCES = clients/keyboard.c
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800716nodist_weston_keyboard_SOURCES = \
717 protocol/weston-desktop-shell-client-protocol.h \
718 protocol/weston-desktop-shell-protocol.c \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800719 protocol/input-method-unstable-v1-protocol.c \
720 protocol/input-method-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800721weston_keyboard_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800722weston_keyboard_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800723
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800724weston_simple_im_SOURCES = clients/weston-simple-im.c
725nodist_weston_simple_im_SOURCES = \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800726 protocol/input-method-unstable-v1-protocol.c \
727 protocol/input-method-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800728weston_simple_im_LDADD = $(CLIENT_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800729weston_simple_im_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800730
Jon A. Cruzb09da242015-06-16 13:15:13 -0700731weston_info_SOURCES = \
732 clients/weston-info.c \
733 shared/helpers.h
Pekka Paalanen93a6afd2014-09-23 22:08:44 -0400734nodist_weston_info_SOURCES = \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200735 protocol/presentation-time-protocol.c \
736 protocol/presentation-time-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800737weston_info_LDADD = $(WESTON_INFO_LIBS) libshared.la
Pekka Paalanen5124b532014-02-03 13:12:34 +0200738weston_info_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800739
Jon A. Cruzb09da242015-06-16 13:15:13 -0700740weston_desktop_shell_SOURCES = \
741 clients/desktop-shell.c \
742 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800743nodist_weston_desktop_shell_SOURCES = \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800744 protocol/weston-desktop-shell-client-protocol.h \
745 protocol/weston-desktop-shell-protocol.c
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800746weston_desktop_shell_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800747weston_desktop_shell_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800748
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900749if ENABLE_IVI_SHELL
Jon A. Cruzb09da242015-06-16 13:15:13 -0700750weston_ivi_shell_user_interface_SOURCES = \
751 clients/ivi-shell-user-interface.c \
752 shared/helpers.h
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900753nodist_weston_ivi_shell_user_interface_SOURCES = \
754 protocol/ivi-hmi-controller-client-protocol.h \
755 protocol/ivi-hmi-controller-protocol.c \
756 protocol/ivi-application-client-protocol.h \
757 protocol/ivi-application-protocol.c
758weston_ivi_shell_user_interface_LDADD = libtoytoolkit.la
759weston_ivi_shell_user_interface_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
760endif
761
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800762if BUILD_FULL_GL_CLIENTS
763demo_clients += weston-gears
764weston_gears_SOURCES = clients/gears.c
765weston_gears_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800766weston_gears_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800767endif
768
769endif
770
771BUILT_SOURCES += \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800772 protocol/weston-screenshooter-protocol.c \
773 protocol/weston-screenshooter-client-protocol.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100774 protocol/text-cursor-position-client-protocol.h \
775 protocol/text-cursor-position-protocol.c \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800776 protocol/text-input-unstable-v1-protocol.c \
777 protocol/text-input-unstable-v1-client-protocol.h \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800778 protocol/input-method-unstable-v1-protocol.c \
779 protocol/input-method-unstable-v1-client-protocol.h \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800780 protocol/weston-desktop-shell-client-protocol.h \
781 protocol/weston-desktop-shell-protocol.c \
Pekka Paalanen73511002016-04-15 16:53:41 +0300782 protocol/viewporter-client-protocol.h \
783 protocol/viewporter-protocol.c \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200784 protocol/presentation-time-protocol.c \
785 protocol/presentation-time-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800786 protocol/fullscreen-shell-unstable-v1-protocol.c \
787 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800788 protocol/xdg-shell-unstable-v5-protocol.c \
789 protocol/xdg-shell-unstable-v5-client-protocol.h \
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900790 protocol/ivi-hmi-controller-protocol.c \
791 protocol/ivi-hmi-controller-client-protocol.h \
792 protocol/ivi-application-protocol.c \
793 protocol/ivi-application-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800794
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -0800795westondatadir = $(datadir)/weston
796dist_westondata_DATA = \
797 data/wayland.svg \
798 data/wayland.png \
799 data/pattern.png \
800 data/terminal.png \
801 data/border.png \
Bryce Harrington6bc52542016-03-24 17:57:39 -0700802 data/icon_editor.png \
803 data/icon_flower.png \
804 data/icon_terminal.png \
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -0800805 data/icon_window.png \
806 data/sign_close.png \
807 data/sign_maximize.png \
Manuel Bachmannd2c68922015-02-16 11:00:36 +0100808 data/sign_minimize.png
809
810if ENABLE_IVI_SHELL
811dist_westondata_DATA += \
Nobuhiko Tanibata001a5432014-03-11 11:54:45 +0900812 data/background.png \
813 data/tiling.png \
814 data/fullscreen.png \
815 data/panel.png \
816 data/random.png \
817 data/sidebyside.png \
818 data/home.png \
819 data/icon_ivi_clickdot.png \
820 data/icon_ivi_flower.png \
821 data/icon_ivi_simple-egl.png \
822 data/icon_ivi_simple-shm.png \
823 data/icon_ivi_smoke.png
Manuel Bachmannd2c68922015-02-16 11:00:36 +0100824endif
Kristian Høgsberge895f142014-01-27 21:46:30 -0800825
826
827if BUILD_WCAP_TOOLS
828bin_PROGRAMS += wcap-decode
829
830wcap_decode_SOURCES = \
831 wcap/main.c \
832 wcap/wcap-decode.c \
833 wcap/wcap-decode.h
834
Derek Foreman4ff38742015-06-18 11:43:11 -0500835wcap_decode_CFLAGS = $(AM_CFLAGS) $(WCAP_CFLAGS)
Kristian Høgsberge895f142014-01-27 21:46:30 -0800836wcap_decode_LDADD = $(WCAP_LIBS)
837endif
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800838
839
840if ENABLE_DESKTOP_SHELL
841
842module_LTLIBRARIES += desktop-shell.la
843
844desktop_shell_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100845 -I$(top_builddir)/protocol \
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800846 -I$(top_srcdir)/shared \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300847 -I$(top_builddir)/libweston \
Emil Velikov4ad45ca2016-07-04 14:57:11 +0100848 -I$(top_srcdir)/libweston \
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800849 -I$(top_builddir)/desktop-shell \
850 -DDATADIR='"$(datadir)"' \
851 -DMODULEDIR='"$(moduledir)"' \
852 -DLIBEXECDIR='"$(libexecdir)"' \
853 -DIN_WESTON
854
855desktop_shell_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800856desktop_shell_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500857desktop_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800858desktop_shell_la_SOURCES = \
859 desktop-shell/shell.h \
860 desktop-shell/shell.c \
861 desktop-shell/exposay.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700862 desktop-shell/input-panel.c \
863 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800864nodist_desktop_shell_la_SOURCES = \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800865 protocol/weston-desktop-shell-protocol.c \
866 protocol/weston-desktop-shell-server-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800867 protocol/xdg-shell-unstable-v5-protocol.c \
868 protocol/xdg-shell-unstable-v5-server-protocol.h
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800869
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800870BUILT_SOURCES += $(nodist_desktop_shell_la_SOURCES)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800871endif
872
Jason Ekstrand946a9482014-04-02 19:53:47 -0500873if ENABLE_FULLSCREEN_SHELL
874
875module_LTLIBRARIES += fullscreen-shell.la
876
877fullscreen_shell_la_CPPFLAGS = \
878 -I$(top_builddir)/protocol \
879 -I$(top_srcdir)/shared \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300880 -I$(top_builddir)/libweston \
Emil Velikov4ad45ca2016-07-04 14:57:11 +0100881 -I$(top_srcdir)/libweston \
Jason Ekstrand946a9482014-04-02 19:53:47 -0500882 -DIN_WESTON
883
884fullscreen_shell_la_LDFLAGS = -module -avoid-version
885fullscreen_shell_la_LIBADD = $(COMPOSITOR_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500886fullscreen_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Jason Ekstrand946a9482014-04-02 19:53:47 -0500887fullscreen_shell_la_SOURCES = \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700888 fullscreen-shell/fullscreen-shell.c \
889 shared/helpers.h
Jason Ekstrand946a9482014-04-02 19:53:47 -0500890nodist_fullscreen_shell_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800891 protocol/fullscreen-shell-unstable-v1-protocol.c \
892 protocol/fullscreen-shell-unstable-v1-server-protocol.h
Jason Ekstrand946a9482014-04-02 19:53:47 -0500893
894BUILT_SOURCES += $(nodist_fullscreen_shell_la_SOURCES)
895endif
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800896
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900897if ENABLE_IVI_SHELL
898
899module_LTLIBRARIES += \
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900900 $(ivi_shell) \
901 $(hmi_controller)
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900902
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900903ivi_shell = ivi-shell.la
904ivi_shell_la_LDFLAGS = -module -avoid-version
905ivi_shell_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500906ivi_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900907ivi_shell_la_SOURCES = \
Nobuhiko Tanibata28dc18c2014-12-15 13:22:31 +0900908 ivi-shell/ivi-layout-export.h \
909 ivi-shell/ivi-layout-private.h \
Pekka Paalanen32ca7912016-03-15 17:21:00 +0200910 ivi-shell/ivi-layout-shell.h \
Nobuhiko Tanibata28dc18c2014-12-15 13:22:31 +0900911 ivi-shell/ivi-layout.c \
912 ivi-shell/ivi-layout-transition.c \
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900913 ivi-shell/ivi-shell.h \
914 ivi-shell/ivi-shell.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700915 ivi-shell/input-panel-ivi.c \
916 shared/helpers.h
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900917nodist_ivi_shell_la_SOURCES = \
918 protocol/ivi-application-protocol.c \
919 protocol/ivi-application-server-protocol.h
920
921BUILT_SOURCES += $(nodist_ivi_shell_la_SOURCES)
922
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900923hmi_controller = hmi-controller.la
924hmi_controller_la_LDFLAGS = -module -avoid-version
925hmi_controller_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500926hmi_controller_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900927hmi_controller_la_SOURCES = \
928 ivi-shell/ivi-layout-export.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700929 ivi-shell/hmi-controller.c \
930 shared/helpers.h
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900931nodist_hmi_controller_la_SOURCES = \
932 protocol/ivi-hmi-controller-protocol.c \
933 protocol/ivi-hmi-controller-server-protocol.h
934
935BUILT_SOURCES += $(nodist_hmi_controller_la_SOURCES)
936
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900937endif
938
939
Jason Ekstrand47928d82014-04-02 19:54:01 -0500940if ENABLE_SCREEN_SHARING
941
942module_LTLIBRARIES += screen-share.la
943
944screen_share_la_CPPFLAGS = $(AM_CPPFLAGS) -DBINDIR='"$(bindir)"'
945screen_share_la_LDFLAGS = -module -avoid-version
946screen_share_la_LIBADD = \
947 $(COMPOSITOR_LIBS) \
948 $(SCREEN_SHARE_LIBS) \
949 libshared-cairo.la
950screen_share_la_CFLAGS = \
951 $(COMPOSITOR_CFLAGS) \
952 $(SCREEN_SHARE_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500953 $(AM_CFLAGS)
Jason Ekstrand47928d82014-04-02 19:54:01 -0500954screen_share_la_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300955 compositor/screen-share.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700956 shared/helpers.h
Jason Ekstrand47928d82014-04-02 19:54:01 -0500957nodist_screen_share_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800958 protocol/fullscreen-shell-unstable-v1-protocol.c \
959 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Jason Ekstrand47928d82014-04-02 19:54:01 -0500960
961endif
962
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800963if ENABLE_XWAYLAND
964
Giulio Camuffo9c764df2016-06-29 11:54:27 +0200965libweston_module_LTLIBRARIES += xwayland.la
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800966
967xwayland_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100968 -I$(top_builddir)/protocol \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800969 -I$(top_srcdir)/shared \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300970 -I$(top_builddir)/libweston \
Emil Velikov4ad45ca2016-07-04 14:57:11 +0100971 -I$(top_srcdir)/libweston \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800972 -I$(top_builddir)/xwayland \
973 -DDATADIR='"$(datadir)"' \
974 -DMODULEDIR='"$(moduledir)"' \
Giulio Camuffo9c764df2016-06-29 11:54:27 +0200975 -DLIBEXECDIR='"$(libexecdir)"'
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800976
977xwayland_la_LDFLAGS = -module -avoid-version
978xwayland_la_LIBADD = \
979 $(XWAYLAND_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800980 $(top_builddir)/libshared-cairo.la
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800981xwayland_la_CFLAGS = \
Derek Foreman4ff38742015-06-18 11:43:11 -0500982 $(AM_CFLAGS) \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800983 $(COMPOSITOR_CFLAGS) \
984 $(PIXMAN_CFLAGS) \
985 $(CAIRO_CFLAGS)
986xwayland_la_SOURCES = \
987 xwayland/xwayland.h \
988 xwayland/window-manager.c \
989 xwayland/selection.c \
990 xwayland/dnd.c \
991 xwayland/launcher.c \
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800992 xwayland/hash.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700993 xwayland/hash.h \
994 shared/helpers.h
Giulio Camuffo9c764df2016-06-29 11:54:27 +0200995
996libwestoninclude_HEADERS += xwayland/xwayland-api.h
997
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800998endif
999
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001000
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001001#
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001002# Shared utilities
1003#
1004
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001005noinst_LTLIBRARIES += libshared.la libshared-cairo.la \
1006 libzunitc.la libzunitcmain.la
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001007
Derek Foreman4ff38742015-06-18 11:43:11 -05001008libshared_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001009
1010libshared_la_SOURCES = \
1011 shared/config-parser.c \
1012 shared/option-parser.c \
1013 shared/config-parser.h \
Pekka Paalanen899b50b2015-02-12 12:52:21 +02001014 shared/file-util.c \
1015 shared/file-util.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001016 shared/helpers.h \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001017 shared/os-compatibility.c \
Bryce Harringtone99e4bf2016-03-16 14:15:18 -07001018 shared/os-compatibility.h \
1019 shared/xalloc.c \
1020 shared/xalloc.h
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001021
1022libshared_cairo_la_CFLAGS = \
1023 -DDATADIR='"$(datadir)"' \
Derek Foreman4ff38742015-06-18 11:43:11 -05001024 $(AM_CFLAGS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001025 $(COMPOSITOR_CFLAGS) \
1026 $(PIXMAN_CFLAGS) \
1027 $(CAIRO_CFLAGS) \
1028 $(PNG_CFLAGS) \
1029 $(WEBP_CFLAGS)
1030
1031libshared_cairo_la_LIBADD = \
1032 $(PIXMAN_LIBS) \
1033 $(CAIRO_LIBS) \
1034 $(PNG_LIBS) \
1035 $(WEBP_LIBS) \
1036 $(JPEG_LIBS)
1037
1038libshared_cairo_la_SOURCES = \
1039 $(libshared_la_SOURCES) \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001040 shared/helpers.h \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001041 shared/image-loader.c \
1042 shared/image-loader.h \
1043 shared/cairo-util.c \
1044 shared/frame.c \
1045 shared/cairo-util.h
1046
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001047libzunitc_la_SOURCES = \
1048 tools/zunitc/inc/zunitc/zunitc.h \
1049 tools/zunitc/inc/zunitc/zunitc_impl.h \
1050 tools/zunitc/src/zuc_base_logger.c \
1051 tools/zunitc/src/zuc_base_logger.h \
1052 tools/zunitc/src/zuc_collector.c \
1053 tools/zunitc/src/zuc_collector.h \
1054 tools/zunitc/src/zuc_context.h \
1055 tools/zunitc/src/zuc_event.h \
1056 tools/zunitc/src/zuc_event_listener.h \
Jon A. Cruz646aef52015-07-15 19:22:41 -07001057 tools/zunitc/src/zuc_junit_reporter.c \
1058 tools/zunitc/src/zuc_junit_reporter.h \
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001059 tools/zunitc/src/zuc_types.h \
1060 tools/zunitc/src/zunitc_impl.c \
1061 shared/helpers.h
1062
1063libzunitc_la_CFLAGS = \
1064 $(AM_CFLAGS) \
1065 -I$(top_srcdir)/tools/zunitc/inc
1066
1067libzunitc_la_LIBADD = \
Gustavo Zacarias57c83f62016-04-22 10:54:35 -03001068 libshared.la \
1069 $(CLOCK_GETTIME_LIBS)
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001070
Jon A. Cruz646aef52015-07-15 19:22:41 -07001071if ENABLE_JUNIT_XML
1072libzunitc_la_CFLAGS += \
1073 $(LIBXML2_CFLAGS)
1074libzunitc_la_LIBADD += \
1075 $(LIBXML2_LIBS)
1076endif
1077
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001078libzunitcmain_la_SOURCES = \
1079 tools/zunitc/src/main.c
1080
1081libzunitcmain_la_CFLAGS = \
1082 $(AM_CFLAGS) \
1083 -I$(top_srcdir)/tools/zunitc/inc
1084
1085libzunitcmain_la_LIBADD = \
1086 libzunitc.la \
1087 libshared.la
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001088
1089#
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001090# tests subdirectory
1091#
1092
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001093TESTS = $(internal_tests) $(shared_tests) $(module_tests) $(weston_tests) $(ivi_tests)
1094
1095internal_tests = \
1096 internal-screenshot.weston
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001097
1098shared_tests = \
1099 config-parser.test \
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001100 vertex-clip.test \
1101 zuctest
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001102
1103module_tests = \
Pekka Paalanen827b5d22016-06-29 11:54:26 +02001104 plugin-registry-test.la \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001105 surface-test.la \
1106 surface-global-test.la
1107
1108weston_tests = \
1109 bad_buffer.weston \
1110 keyboard.weston \
1111 event.weston \
1112 button.weston \
1113 text.weston \
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001114 presentation.weston \
Pekka Paalanen82d95a62016-04-19 17:20:42 +03001115 viewporter.weston \
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +03001116 roles.weston \
Marek Chalupa5fd81402015-03-30 09:21:29 -04001117 subsurface.weston \
1118 devices.weston
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001119
Pekka Paalanenf3a34532015-03-24 13:51:05 +02001120ivi_tests =
1121
1122$(ivi_tests) : $(builddir)/tests/weston-ivi.ini
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001123
1124AM_TESTS_ENVIRONMENT = \
Bryce Harringtoned2c6442015-04-15 15:31:11 -07001125 abs_builddir='$(abs_builddir)'; export abs_builddir; \
1126 abs_top_srcdir='$(abs_top_srcdir)'; export abs_top_srcdir;
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001127
1128TEST_EXTENSIONS = .la .weston
1129LA_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
1130WESTON_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
1131
1132clean-local:
Pekka Paalanen15f85632014-05-12 10:08:57 +03001133 -rm -rf logs
Jon A. Cruz179c1862015-07-15 19:22:43 -07001134 -rm -rf $(DOCDIRS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001135
1136# To remove when automake 1.11 support is dropped
1137export abs_builddir
1138
1139noinst_LTLIBRARIES += \
1140 weston-test.la \
1141 $(module_tests) \
1142 libtest-runner.la \
1143 libtest-client.la
1144
1145noinst_PROGRAMS += \
1146 $(setbacklight) \
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001147 $(internal_tests) \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001148 $(shared_tests) \
1149 $(weston_tests) \
Pekka Paalanenf3a34532015-03-24 13:51:05 +02001150 $(ivi_tests) \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001151 matrix-test
1152
1153test_module_ldflags = \
1154 -module -avoid-version -rpath $(libdir) $(COMPOSITOR_LIBS)
1155
Pekka Paalanen827b5d22016-06-29 11:54:26 +02001156plugin_registry_test_la_SOURCES = tests/plugin-registry-test.c
1157plugin_registry_test_la_LDFLAGS = $(test_module_ldflags)
1158plugin_registry_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
1159
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001160surface_global_test_la_SOURCES = tests/surface-global-test.c
1161surface_global_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001162surface_global_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001163
1164surface_test_la_SOURCES = tests/surface-test.c
1165surface_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001166surface_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001167
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001168weston_test_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001169weston_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001170weston_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -07001171weston_test_la_SOURCES = \
1172 tests/weston-test.c \
1173 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001174nodist_weston_test_la_SOURCES = \
Derek Foremanf6a65922015-02-24 09:32:14 -06001175 protocol/weston-test-protocol.c \
1176 protocol/weston-test-server-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001177
1178if ENABLE_EGL
1179weston_test_la_CFLAGS += $(EGL_TESTS_CFLAGS)
1180weston_test_la_LDFLAGS += $(EGL_TESTS_LIBS)
1181endif
1182
1183libtest_runner_la_SOURCES = \
1184 tests/weston-test-runner.c \
1185 tests/weston-test-runner.h
Derek Foreman4ff38742015-06-18 11:43:11 -05001186libtest_runner_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001187
1188config_parser_test_SOURCES = tests/config-parser-test.c
Jon A. Cruza67c5412015-07-15 19:22:42 -07001189config_parser_test_LDADD = \
1190 libshared.la \
1191 $(COMPOSITOR_LIBS) \
1192 libzunitc.la \
1193 libzunitcmain.la
1194config_parser_test_CFLAGS = \
1195 $(AM_CFLAGS) \
1196 -I$(top_srcdir)/tools/zunitc/inc
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001197
1198vertex_clip_test_SOURCES = \
1199 tests/vertex-clip-test.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001200 shared/helpers.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +03001201 libweston/vertex-clipping.c \
1202 libweston/vertex-clipping.h
Gustavo Zacarias34d59852016-04-21 11:18:48 -03001203vertex_clip_test_LDADD = libtest-runner.la -lm $(CLOCK_GETTIME_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001204
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001205libtest_client_la_SOURCES = \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001206 tests/weston-test-client-helper.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001207 tests/weston-test-client-helper.h
1208nodist_libtest_client_la_SOURCES = \
Derek Foremanf6a65922015-02-24 09:32:14 -06001209 protocol/weston-test-protocol.c \
1210 protocol/weston-test-client-protocol.h
Bryce Harrington892122e2015-09-24 14:31:44 -07001211libtest_client_la_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS) $(CAIRO_CFLAGS)
1212libtest_client_la_LIBADD = $(TEST_CLIENT_LIBS) $(CAIRO_LIBS) libshared.la libtest-runner.la
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001213
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001214
1215#
1216# Internal tests - tests functionality of the testsuite itself
1217#
1218
1219internal_screenshot_weston_SOURCES = tests/internal-screenshot-test.c
Bryce Harrington892122e2015-09-24 14:31:44 -07001220internal_screenshot_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1221internal_screenshot_weston_LDADD = libtest-client.la
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001222
1223
1224#
1225# Weston Tests
1226#
1227
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001228bad_buffer_weston_SOURCES = tests/bad-buffer-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001229bad_buffer_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001230bad_buffer_weston_LDADD = libtest-client.la
1231
1232keyboard_weston_SOURCES = tests/keyboard-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001233keyboard_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001234keyboard_weston_LDADD = libtest-client.la
1235
1236event_weston_SOURCES = tests/event-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001237event_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001238event_weston_LDADD = libtest-client.la
1239
1240button_weston_SOURCES = tests/button-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001241button_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001242button_weston_LDADD = libtest-client.la
1243
Marek Chalupa5fd81402015-03-30 09:21:29 -04001244devices_weston_SOURCES = tests/devices-test.c
1245devices_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1246devices_weston_LDADD = libtest-client.la
1247
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001248text_weston_SOURCES = tests/text-test.c
1249nodist_text_weston_SOURCES = \
Jonas Ådahl3bcba342015-11-17 16:00:29 +08001250 protocol/text-input-unstable-v1-protocol.c \
1251 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001252text_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001253text_weston_LDADD = libtest-client.la
1254
1255subsurface_weston_SOURCES = tests/subsurface-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001256subsurface_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001257subsurface_weston_LDADD = libtest-client.la
1258
Jon A. Cruzb09da242015-06-16 13:15:13 -07001259presentation_weston_SOURCES = \
1260 tests/presentation-test.c \
1261 shared/helpers.h
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001262nodist_presentation_weston_SOURCES = \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +02001263 protocol/presentation-time-protocol.c \
1264 protocol/presentation-time-client-protocol.h
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001265presentation_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1266presentation_weston_LDADD = libtest-client.la
1267
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +03001268roles_weston_SOURCES = tests/roles-test.c
1269roles_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1270roles_weston_LDADD = libtest-client.la
1271
Pekka Paalanen82d95a62016-04-19 17:20:42 +03001272viewporter_weston_SOURCES = \
1273 tests/viewporter-test.c \
1274 shared/helpers.h
1275nodist_viewporter_weston_SOURCES = \
1276 protocol/viewporter-protocol.c \
1277 protocol/viewporter-client-protocol.h
1278viewporter_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1279viewporter_weston_LDADD = libtest-client.la
1280
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001281if ENABLE_EGL
1282weston_tests += buffer-count.weston
1283buffer_count_weston_SOURCES = tests/buffer-count-test.c
Pekka Paalanen924cd942016-05-20 17:25:38 +03001284buffer_count_weston_CFLAGS = $(AM_CFLAGS) $(EGL_TESTS_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001285buffer_count_weston_LDADD = libtest-client.la $(EGL_TESTS_LIBS)
1286endif
1287
1288if ENABLE_XWAYLAND_TEST
Pekka Paalanenf9a26262014-05-07 16:26:29 +03001289weston_tests += xwayland-test.weston
1290xwayland_test_weston_SOURCES = tests/xwayland-test.c
Derek Foreman4ff38742015-06-18 11:43:11 -05001291xwayland_test_weston_CFLAGS = $(AM_CFLAGS) $(XWAYLAND_TEST_CFLAGS)
Pekka Paalanenf9a26262014-05-07 16:26:29 +03001292xwayland_test_weston_LDADD = libtest-client.la $(XWAYLAND_TEST_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001293endif
1294
1295matrix_test_SOURCES = \
1296 tests/matrix-test.c \
1297 shared/matrix.c \
1298 shared/matrix.h
1299matrix_test_CPPFLAGS = -DUNIT_TEST
Gustavo Zacarias34d59852016-04-21 11:18:48 -03001300matrix_test_LDADD = -lm $(CLOCK_GETTIME_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001301
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001302if ENABLE_IVI_SHELL
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001303module_tests += \
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001304 ivi-layout-internal-test.la \
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001305 ivi-layout-test.la
1306
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001307ivi_layout_internal_test_la_LIBADD = $(COMPOSITOR_LIBS)
1308ivi_layout_internal_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001309ivi_layout_internal_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001310ivi_layout_internal_test_la_SOURCES = \
1311 tests/ivi_layout-internal-test.c
1312
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001313ivi_layout_test_la_LIBADD = $(COMPOSITOR_LIBS)
1314ivi_layout_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001315ivi_layout_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001316ivi_layout_test_la_SOURCES = \
1317 tests/ivi_layout-test-plugin.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001318 tests/ivi-test.h \
1319 shared/helpers.h
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001320nodist_ivi_layout_test_la_SOURCES = \
1321 protocol/weston-test-protocol.c \
1322 protocol/weston-test-server-protocol.h
1323
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001324ivi_tests += \
1325 ivi-shell-app.weston
1326
1327ivi_shell_app_weston_SOURCES = tests/ivi-shell-app-test.c
1328nodist_ivi_shell_app_weston_SOURCES = \
1329 protocol/ivi-application-protocol.c \
1330 protocol/ivi-application-client-protocol.h
1331ivi_shell_app_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1332ivi_shell_app_weston_LDADD = libtest-client.la
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001333
1334noinst_PROGRAMS += ivi-layout.ivi
1335
1336ivi_layout_ivi_SOURCES = \
1337 tests/ivi_layout-test.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001338 tests/ivi-test.h \
1339 shared/helpers.h
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001340nodist_ivi_layout_ivi_SOURCES = \
1341 protocol/ivi-application-protocol.c \
1342 protocol/ivi-application-client-protocol.h
1343ivi_layout_ivi_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1344ivi_layout_ivi_LDADD = libtest-client.la
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001345endif
1346
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001347if BUILD_SETBACKLIGHT
1348noinst_PROGRAMS += setbacklight
1349setbacklight_SOURCES = \
1350 tests/setbacklight.c \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +03001351 libweston/libbacklight.c \
1352 libweston/libbacklight.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001353setbacklight_CFLAGS = $(AM_CFLAGS) $(SETBACKLIGHT_CFLAGS)
1354setbacklight_LDADD = $(SETBACKLIGHT_LIBS)
1355endif
1356
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001357all-local: zuctest$(EXEEXT)
1358
1359noinst_PROGRAMS += zuctest$(EXEEXT)
1360
1361zuctest_LDADD = \
1362 libzunitc.la \
1363 libzunitcmain.la
1364
1365zuctest_CFLAGS = \
1366 $(AM_CFLAGS) \
1367 -I$(top_srcdir)/tools/zunitc/inc
1368
1369zuctest_SOURCES = \
1370 tools/zunitc/test/fixtures_test.c \
1371 tools/zunitc/test/zunitc_test.c
1372
Derek Foreman1ce2ef52015-05-26 10:21:03 -05001373EXTRA_DIST += \
1374 tests/weston-tests-env \
1375 tests/internal-screenshot.ini \
1376 tests/reference/internal-screenshot-bad-00.png \
1377 tests/reference/internal-screenshot-good-00.png
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001378
1379BUILT_SOURCES += \
Derek Foremanf6a65922015-02-24 09:32:14 -06001380 protocol/weston-test-protocol.c \
1381 protocol/weston-test-server-protocol.h \
1382 protocol/weston-test-client-protocol.h \
Jonas Ådahl3bcba342015-11-17 16:00:29 +08001383 protocol/text-input-unstable-v1-protocol.c \
1384 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001385
Kristian Høgsbergcd312752014-02-01 00:38:15 -08001386EXTRA_DIST += \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +08001387 protocol/weston-desktop-shell.xml \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +08001388 protocol/weston-screenshooter.xml \
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001389 protocol/text-cursor-position.xml \
Derek Foremanf6a65922015-02-24 09:32:14 -06001390 protocol/weston-test.xml \
Nobuhiko Tanibata68cfabb2014-11-27 13:22:53 +09001391 protocol/ivi-application.xml \
Jonas Ådahl57e48f02015-11-17 16:00:28 +08001392 protocol/ivi-hmi-controller.xml
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001393
Pekka Paalanen312fe5f2015-02-09 11:23:48 +02001394#
1395# manual test modules in tests subdirectory
1396#
1397
1398noinst_LTLIBRARIES += \
1399 surface-screenshot.la
1400
1401surface_screenshot_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
1402surface_screenshot_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001403surface_screenshot_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanen312fe5f2015-02-09 11:23:48 +02001404surface_screenshot_la_SOURCES = tests/surface-screenshot.c
1405
1406
1407#
1408# Documentation
1409#
1410
Kristian Høgsberg68c5c102014-01-27 22:33:04 -08001411man_MANS = weston.1 weston.ini.5
1412
1413if ENABLE_DRM_COMPOSITOR
1414man_MANS += weston-drm.7
1415endif
1416
1417MAN_SUBSTS = \
1418 -e 's|__weston_native_backend__|$(WESTON_NATIVE_BACKEND)|g' \
1419 -e 's|__weston_modules_dir__|$(pkglibdir)|g' \
1420 -e 's|__weston_shell_client__|$(WESTON_SHELL_CLIENT)|g' \
1421 -e 's|__version__|$(PACKAGE_VERSION)|g'
1422
1423SUFFIXES = .1 .5 .7 .man
1424
1425%.1 %.5 %.7 : man/%.man
1426 $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
1427
1428EXTRA_DIST += \
1429 man/weston.man \
1430 man/weston-drm.man \
1431 man/weston.ini.man
1432
1433CLEANFILES += $(man_MANS)
1434
Jon A. Cruz179c1862015-07-15 19:22:43 -07001435if ENABLE_DEVDOCS
1436DOXYGEN_INDICES = docs/developer/html/index.html docs/tools/html/index.html
1437
1438docs/developer/html/index.html: doc/doxygen/tooldev.doxygen | docs/developer
1439 cd doc/doxygen && $(DOXYGEN) tooldev.doxygen
1440
1441docs/tools/html/index.html: doc/doxygen/tools.doxygen | docs/tools
1442 cd doc/doxygen && $(DOXYGEN) tools.doxygen
1443endif
1444
1445DOCDIRS = \
1446 docs/developer \
1447 docs/tools
1448
1449$(DOCDIRS):
1450 $(MKDIR_P) $@
1451
1452.PHONY: doc $(DOXYGEN_INDICES)
1453
1454doc: $(DOXYGEN_INDICES)
1455
Jonas Ådahl496adb32015-11-17 16:00:27 +08001456.SECONDEXPANSION:
1457
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001458define protostability
Pekka Paalanen35552aa2016-02-18 16:56:13 +02001459$(if $(findstring unstable,$1),unstable,stable)
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001460endef
1461
1462define protoname
1463$(shell echo $1 | sed 's/\([a-z\-]\+\)-[a-z]\+-v[0-9]\+/\1/')
1464endef
1465
1466protocol/%-protocol.c : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001467 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
1468
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001469protocol/%-server-protocol.h : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001470 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
1471
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001472protocol/%-client-protocol.h : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001473 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@
1474
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001475protocol/%-protocol.c : $(top_srcdir)/protocol/%.xml
1476 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001477
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001478protocol/%-server-protocol.h : $(top_srcdir)/protocol/%.xml
1479 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001480
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001481protocol/%-client-protocol.h : $(top_srcdir)/protocol/%.xml
1482 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@