blob: 6241fa04644394d0941d70b0dc579c1e57097dda [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 =
Emil Velikov7fe47f32016-07-22 14:51:51 +01008libweston_moduledir = $(libdir)/libweston-$(LIBWESTON_MAJOR)
Giulio Camuffo179fcda2016-06-02 21:48:14 +03009libweston_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
Quentin Glidic154c5d22016-08-15 17:29:09 +020064# Libtool race fix
65# libweston-desktop depends on libweston, and desktop-shell depends on both.
66# This leads to a libtool race at installation, because libtool re-links
67# everything.
68# If you add more fixes, you may need a workaround to keep automake generated
69# targets. See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=7328
70install-libweston_moduleLTLIBRARIES install-moduleLTLIBRARIES: install-libLTLIBRARIES
71
Emil Velikov7fe47f32016-07-22 14:51:51 +010072lib_LTLIBRARIES = libweston-@LIBWESTON_MAJOR@.la
73libweston_@LIBWESTON_MAJOR@_la_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON
74libweston_@LIBWESTON_MAJOR@_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(LIBUNWIND_CFLAGS)
75libweston_@LIBWESTON_MAJOR@_la_LIBADD = $(COMPOSITOR_LIBS) $(LIBUNWIND_LIBS) \
Giulio Camuffo8aedf7b2016-06-02 21:48:12 +030076 $(DLOPEN_LIBS) -lm $(CLOCK_GETTIME_LIBS) \
77 $(LIBINPUT_BACKEND_LIBS) libshared.la
Emil Velikov7fe47f32016-07-22 14:51:51 +010078libweston_@LIBWESTON_MAJOR@_la_LDFLAGS = -version-info $(LT_VERSION_INFO)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080079
Emil Velikov7fe47f32016-07-22 14:51:51 +010080libweston_@LIBWESTON_MAJOR@_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +030081 libweston/git-version.h \
82 libweston/log.c \
83 libweston/compositor.c \
84 libweston/compositor.h \
85 libweston/compositor-drm.h \
86 libweston/compositor-fbdev.h \
87 libweston/compositor-headless.h \
88 libweston/compositor-rdp.h \
89 libweston/compositor-wayland.h \
90 libweston/compositor-x11.h \
91 libweston/input.c \
92 libweston/data-device.c \
93 libweston/screenshooter.c \
94 libweston/clipboard.c \
95 libweston/zoom.c \
96 libweston/bindings.c \
97 libweston/animation.c \
98 libweston/noop-renderer.c \
99 libweston/pixman-renderer.c \
100 libweston/pixman-renderer.h \
Pekka Paalanen827b5d22016-06-29 11:54:26 +0200101 libweston/plugin-registry.c \
102 libweston/plugin-registry.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300103 libweston/timeline.c \
104 libweston/timeline.h \
105 libweston/timeline-object.h \
106 libweston/linux-dmabuf.c \
107 libweston/linux-dmabuf.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700108 shared/helpers.h \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800109 shared/matrix.c \
110 shared/matrix.h \
Pekka Paalanenaa21f622015-07-03 15:44:50 +0300111 shared/timespec-util.h \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800112 shared/zalloc.h \
Jonny Lamb51a7ae52015-03-20 15:26:51 +0100113 shared/platform.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300114 libweston/weston-egl-ext.h
Egor Starkov7ce2e972015-09-25 18:00:27 +0300115
Quentin Glidic248dd102016-08-12 10:41:34 +0200116lib_LTLIBRARIES += libweston-desktop-@LIBWESTON_MAJOR@.la
117libweston_desktop_@LIBWESTON_MAJOR@_la_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON
118libweston_desktop_@LIBWESTON_MAJOR@_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
119libweston_desktop_@LIBWESTON_MAJOR@_la_LIBADD = libweston-@LIBWESTON_MAJOR@.la $(COMPOSITOR_LIBS)
120libweston_desktop_@LIBWESTON_MAJOR@_la_LDFLAGS = -version-info $(LT_VERSION_INFO)
121
122libweston_desktop_@LIBWESTON_MAJOR@_la_SOURCES = \
123 libweston-desktop/client.c \
124 libweston-desktop/internal.h \
125 libweston-desktop/libweston-desktop.c \
126 libweston-desktop/libweston-desktop.h \
127 libweston-desktop/seat.c \
128 libweston-desktop/surface.c \
129 libweston-desktop/wl-shell.c \
Quentin Glidic9c5dd7e2016-08-12 10:41:37 +0200130 libweston-desktop/xdg-shell-v6.c \
Quentin Glidic248dd102016-08-12 10:41:34 +0200131 libweston-desktop/xdg-shell-v5.c \
132 libweston-desktop/xwayland.c
133
134nodist_libweston_desktop_@LIBWESTON_MAJOR@_la_SOURCES = \
Quentin Glidic9c5dd7e2016-08-12 10:41:37 +0200135 protocol/xdg-shell-unstable-v6-protocol.c \
136 protocol/xdg-shell-unstable-v6-server-protocol.h \
Quentin Glidic248dd102016-08-12 10:41:34 +0200137 protocol/xdg-shell-unstable-v5-protocol.c \
138 protocol/xdg-shell-unstable-v5-server-protocol.h
139
Jonas Ådahl5ac91a12016-08-15 17:31:02 +0800140BUILT_SOURCES += $(nodist_libweston_desktop_@LIBWESTON_MAJOR@_la_SOURCES)
141
Quentin Glidic9c5dd7e2016-08-12 10:41:37 +0200142libweston-desktop-@LIBWESTON_MAJOR@.la libweston-desktop/libweston_desktop_@LIBWESTON_MAJOR@_la-xdg-shell-v6.lo: protocol/xdg-shell-unstable-v6-server-protocol.h
Quentin Glidic248dd102016-08-12 10:41:34 +0200143libweston-desktop-@LIBWESTON_MAJOR@.la libweston-desktop/libweston_desktop_@LIBWESTON_MAJOR@_la-xdg-shell-v5.lo: protocol/xdg-shell-unstable-v5-server-protocol.h
144
Egor Starkov7ce2e972015-09-25 18:00:27 +0300145if SYSTEMD_NOTIFY_SUPPORT
146module_LTLIBRARIES += systemd-notify.la
147systemd_notify_la_LDFLAGS = -module -avoid-version
148systemd_notify_la_LIBADD = $(SYSTEMD_DAEMON_LIBS)
149systemd_notify_la_CFLAGS = \
Pekka Paalanenaff703e2016-04-05 14:08:11 +0300150 $(COMPOSITOR_CFLAGS) \
151 $(SYSTEMD_DAEMON_CFLAGS) \
Egor Starkov7ce2e972015-09-25 18:00:27 +0300152 $(PIXMAN_CFLAGS) \
153 $(AM_CFLAGS)
154systemd_notify_la_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300155 compositor/systemd-notify.c \
Egor Starkov7ce2e972015-09-25 18:00:27 +0300156 shared/helpers.h \
157 shared/zalloc.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300158 libweston/compositor.h
Egor Starkov7ce2e972015-09-25 18:00:27 +0300159endif
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800160
Emil Velikov7fe47f32016-07-22 14:51:51 +0100161nodist_libweston_@LIBWESTON_MAJOR@_la_SOURCES = \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800162 protocol/weston-screenshooter-protocol.c \
163 protocol/weston-screenshooter-server-protocol.h \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800164 protocol/text-cursor-position-protocol.c \
165 protocol/text-cursor-position-server-protocol.h \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800166 protocol/text-input-unstable-v1-protocol.c \
167 protocol/text-input-unstable-v1-server-protocol.h \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800168 protocol/input-method-unstable-v1-protocol.c \
169 protocol/input-method-unstable-v1-server-protocol.h \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200170 protocol/presentation-time-protocol.c \
171 protocol/presentation-time-server-protocol.h \
Pekka Paalanene95ad5c2016-04-15 14:47:08 +0300172 protocol/viewporter-protocol.c \
173 protocol/viewporter-server-protocol.h \
Jonas Ådahl57e48f02015-11-17 16:00:28 +0800174 protocol/linux-dmabuf-unstable-v1-protocol.c \
Jonas Ådahl30d61d82014-10-22 21:21:17 +0200175 protocol/linux-dmabuf-unstable-v1-server-protocol.h \
176 protocol/relative-pointer-unstable-v1-protocol.c \
Jonas Ådahld3414f22016-07-22 17:56:31 +0800177 protocol/relative-pointer-unstable-v1-server-protocol.h \
178 protocol/pointer-constraints-unstable-v1-protocol.c \
Bryce Harrington689fece2016-08-10 17:25:23 -0700179 protocol/pointer-constraints-unstable-v1-server-protocol.h \
180 protocol/idle-inhibit-unstable-v1-protocol.c \
181 protocol/idle-inhibit-unstable-v1-server-protocol.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800182
Emil Velikov7fe47f32016-07-22 14:51:51 +0100183BUILT_SOURCES += $(nodist_libweston_@LIBWESTON_MAJOR@_la_SOURCES)
Giulio Camuffo9e445982016-06-02 21:48:15 +0300184
185bin_PROGRAMS += weston
186
187weston_LDFLAGS = -export-dynamic
188weston_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON \
Giulio Camuffo9c764df2016-06-29 11:54:27 +0200189 -DMODULEDIR='"$(moduledir)"' \
190 -DXSERVER_PATH='"@XSERVER_PATH@"'
Giulio Camuffo9e445982016-06-02 21:48:15 +0300191weston_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(LIBUNWIND_CFLAGS)
Emil Velikov67351452016-07-22 14:52:42 +0100192weston_LDADD = libshared.la libweston-@LIBWESTON_MAJOR@.la \
193 $(COMPOSITOR_LIBS) $(LIBUNWIND_LIBS) \
Giulio Camuffo9e445982016-06-02 21:48:15 +0300194 $(DLOPEN_LIBS) $(LIBINPUT_BACKEND_LIBS) \
Emil Velikov67351452016-07-22 14:52:42 +0100195 -lm
Giulio Camuffo9e445982016-06-02 21:48:15 +0300196
197weston_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300198 compositor/main.c \
199 compositor/weston-screenshooter.c \
Giulio Camuffo9c764df2016-06-29 11:54:27 +0200200 compositor/text-backend.c \
201 compositor/xwayland.c
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800202
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800203# Track this dependency explicitly instead of using BUILT_SOURCES. We
204# add BUILT_SOURCES to CLEANFILES, but we want to keep git-version.h
205# in case we're building from tarballs.
206
Emil Velikova8840242016-07-04 14:57:12 +0100207compositor/main.c : $(top_builddir)/libweston/git-version.h
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300208libweston/compositor.c : $(top_builddir)/libweston/git-version.h
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800209
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800210noinst_LTLIBRARIES += \
211 libsession-helper.la
212
213libsession_helper_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300214 libweston/launcher-util.c \
215 libweston/launcher-util.h \
216 libweston/launcher-impl.h \
217 libweston/weston-launch.h \
218 libweston/launcher-weston-launch.c \
219 libweston/launcher-direct.c
Derek Foreman4ff38742015-06-18 11:43:11 -0500220libsession_helper_la_CFLAGS = $(AM_CFLAGS) $(LIBDRM_CFLAGS) $(PIXMAN_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800221libsession_helper_la_LIBADD = $(LIBDRM_LIBS)
222
223if ENABLE_DBUS
224if HAVE_SYSTEMD_LOGIN
225libsession_helper_la_SOURCES += \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300226 libweston/dbus.h \
227 libweston/dbus.c \
228 libweston/launcher-logind.c
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800229libsession_helper_la_CFLAGS += $(SYSTEMD_LOGIN_CFLAGS) $(DBUS_CFLAGS)
230libsession_helper_la_LIBADD += $(SYSTEMD_LOGIN_LIBS) $(DBUS_LIBS)
231endif
232endif
233
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800234if HAVE_GIT_REPO
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300235libweston/git-version.h : $(top_srcdir)/.git/logs/HEAD
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800236 $(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 -0800237else
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300238libweston/git-version.h :
Kristian Høgsberg1d2dd072014-02-03 10:55:51 -0800239 $(AM_V_GEN)echo "#define BUILD_ID \"unknown (not built from git or tarball)\"" > $@
240
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800241endif
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800242
243.FORCE :
244
245if BUILD_WESTON_LAUNCH
246bin_PROGRAMS += weston-launch
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300247weston_launch_SOURCES = libweston/weston-launch.c libweston/weston-launch.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800248weston_launch_CPPFLAGS = -DBINDIR='"$(bindir)"'
249weston_launch_CFLAGS= \
Derek Foreman4ff38742015-06-18 11:43:11 -0500250 $(AM_CFLAGS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800251 $(PAM_CFLAGS) \
252 $(SYSTEMD_LOGIN_CFLAGS) \
253 $(LIBDRM_CFLAGS)
254weston_launch_LDADD = $(PAM_LIBS) $(SYSTEMD_LOGIN_LIBS) $(LIBDRM_LIBS)
255
256if ENABLE_SETUID_INSTALL
257install-exec-hook:
Jon A. Cruz90f23ca2015-04-09 17:52:56 -0700258 can_suid_files=no; \
259 chown root $(DESTDIR)$(bindir)/weston-launch \
260 && chmod u+s $(DESTDIR)$(bindir)/weston-launch \
261 && can_suid_files=yes;\
Derek Foreman6d116792015-04-10 11:55:27 -0500262 if test $$can_suid_files = no; then \
Jon A. Cruz90f23ca2015-04-09 17:52:56 -0700263 echo 'Error: unable to unable to change ownership/setuid on weston-launch.'; \
264 echo 'To skip this step, re-run ./configure using --disable-setuid-install'; \
265 false; \
266 fi
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800267endif
268
269endif # BUILD_WESTON_LAUNCH
270
271pkgconfigdir = $(libdir)/pkgconfig
Quentin Glidic248dd102016-08-12 10:41:34 +0200272pkgconfig_DATA = \
273 libweston/libweston-${LIBWESTON_MAJOR}.pc \
274 libweston-desktop/libweston-desktop-${LIBWESTON_MAJOR}.pc \
275 compositor/weston.pc
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800276
Lubomir Rintel4f4b47a2014-12-28 14:20:49 +0100277wayland_sessiondir = $(datadir)/wayland-sessions
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300278dist_wayland_session_DATA = compositor/weston.desktop
Lubomir Rintel4f4b47a2014-12-28 14:20:49 +0100279
Emil Velikov7fe47f32016-07-22 14:51:51 +0100280libwestonincludedir = $(includedir)/libweston-${LIBWESTON_MAJOR}
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300281libwestoninclude_HEADERS = \
282 libweston/version.h \
283 libweston/compositor.h \
284 libweston/compositor-drm.h \
285 libweston/compositor-fbdev.h \
286 libweston/compositor-headless.h \
287 libweston/compositor-rdp.h \
288 libweston/compositor-wayland.h \
289 libweston/compositor-x11.h \
Pekka Paalanen827b5d22016-06-29 11:54:26 +0200290 libweston/plugin-registry.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300291 libweston/timeline-object.h \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800292 shared/matrix.h \
293 shared/config-parser.h \
Emil Velikovcbcf5452016-07-04 15:34:17 +0100294 shared/zalloc.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800295
Quentin Glidic248dd102016-08-12 10:41:34 +0200296libwestoninclude_HEADERS += \
297 libweston-desktop/libweston-desktop.h
298
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300299westonincludedir = $(includedir)/weston
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300300westoninclude_HEADERS = compositor/weston.h
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300301
Ucan, Emre \(ADITG/SW1\)ae2541d2015-10-15 14:51:43 +0000302if ENABLE_IVI_SHELL
303westoninclude_HEADERS += \
304 ivi-shell/ivi-layout-export.h
305endif
306
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800307if ENABLE_EGL
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300308libweston_module_LTLIBRARIES += gl-renderer.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800309gl_renderer_la_LDFLAGS = -module -avoid-version
310gl_renderer_la_LIBADD = $(COMPOSITOR_LIBS) $(EGL_LIBS)
311gl_renderer_la_CFLAGS = \
312 $(COMPOSITOR_CFLAGS) \
313 $(EGL_CFLAGS) \
Pekka Paalanena3525802014-06-12 16:49:29 +0300314 $(GL_RENDERER_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500315 $(AM_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800316gl_renderer_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300317 libweston/gl-renderer.h \
318 libweston/gl-renderer.c \
319 libweston/vertex-clipping.c \
320 libweston/vertex-clipping.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700321 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800322endif
323
324if ENABLE_X11_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300325libweston_module_LTLIBRARIES += x11-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800326x11_backend_la_LDFLAGS = -module -avoid-version
327x11_backend_la_LIBADD = $(COMPOSITOR_LIBS) $(X11_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800328 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800329x11_backend_la_CFLAGS = \
330 $(COMPOSITOR_CFLAGS) \
331 $(EGL_CFLAGS) \
332 $(PIXMAN_CFLAGS) \
333 $(CAIRO_CFLAGS) \
334 $(X11_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500335 $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700336x11_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300337 libweston/compositor-x11.c \
338 libweston/compositor-x11.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700339 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800340endif
341
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100342INPUT_BACKEND_LIBS = $(LIBINPUT_BACKEND_LIBS)
Peter Hutterer823ad332014-11-26 07:06:31 +1000343INPUT_BACKEND_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300344 libweston/libinput-seat.c \
345 libweston/libinput-seat.h \
346 libweston/libinput-device.c \
347 libweston/libinput-device.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700348 shared/helpers.h
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100349
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800350if ENABLE_DRM_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300351libweston_module_LTLIBRARIES += drm-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800352drm_backend_la_LDFLAGS = -module -avoid-version
353drm_backend_la_LIBADD = \
354 $(COMPOSITOR_LIBS) \
355 $(DRM_COMPOSITOR_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100356 $(INPUT_BACKEND_LIBS) \
Gustavo Zacarias34d59852016-04-21 11:18:48 -0300357 libshared.la \
358 $(CLOCK_GETTIME_LIBS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800359 libsession-helper.la
360drm_backend_la_CFLAGS = \
361 $(COMPOSITOR_CFLAGS) \
362 $(EGL_CFLAGS) \
363 $(DRM_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500364 $(AM_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800365drm_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300366 libweston/compositor-drm.c \
367 libweston/compositor-drm.h \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100368 $(INPUT_BACKEND_SOURCES) \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700369 shared/helpers.h \
Mario Kleinerf507ec32015-06-21 21:25:14 +0200370 shared/timespec-util.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300371 libweston/libbacklight.c \
372 libweston/libbacklight.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800373
374if ENABLE_VAAPI_RECORDER
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300375drm_backend_la_SOURCES += libweston/vaapi-recorder.c libweston/vaapi-recorder.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800376drm_backend_la_LIBADD += $(LIBVA_LIBS)
377drm_backend_la_CFLAGS += $(LIBVA_CFLAGS)
378endif
379endif
380
381if ENABLE_WAYLAND_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300382libweston_module_LTLIBRARIES += wayland-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800383wayland_backend_la_LDFLAGS = -module -avoid-version
384wayland_backend_la_LIBADD = \
385 $(COMPOSITOR_LIBS) \
386 $(WAYLAND_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800387 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800388wayland_backend_la_CFLAGS = \
389 $(COMPOSITOR_CFLAGS) \
390 $(EGL_CFLAGS) \
391 $(PIXMAN_CFLAGS) \
392 $(CAIRO_CFLAGS) \
393 $(WAYLAND_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500394 $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700395wayland_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300396 libweston/compositor-wayland.c \
397 libweston/compositor-wayland.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700398 shared/helpers.h
Jason Ekstrand53ee0dc2014-04-02 19:53:54 -0500399nodist_wayland_backend_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800400 protocol/fullscreen-shell-unstable-v1-protocol.c \
401 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800402endif
403
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800404if ENABLE_HEADLESS_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300405libweston_module_LTLIBRARIES += headless-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800406headless_backend_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800407headless_backend_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500408headless_backend_la_CFLAGS = $(COMPOSITOR_CFLAGS) $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700409headless_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300410 libweston/compositor-headless.c \
411 libweston/compositor-headless.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700412 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800413endif
414
415if ENABLE_FBDEV_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300416libweston_module_LTLIBRARIES += fbdev-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800417fbdev_backend_la_LDFLAGS = -module -avoid-version
418fbdev_backend_la_LIBADD = \
419 $(COMPOSITOR_LIBS) \
420 $(FBDEV_COMPOSITOR_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100421 $(INPUT_BACKEND_LIBS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800422 libsession-helper.la \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800423 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800424fbdev_backend_la_CFLAGS = \
425 $(COMPOSITOR_CFLAGS) \
426 $(EGL_CFLAGS) \
427 $(FBDEV_COMPOSITOR_CFLAGS) \
428 $(PIXMAN_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500429 $(AM_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800430fbdev_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300431 libweston/compositor-fbdev.c \
432 libweston/compositor-fbdev.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700433 shared/helpers.h \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100434 $(INPUT_BACKEND_SOURCES)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800435endif
436
437if ENABLE_RDP_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300438libweston_module_LTLIBRARIES += rdp-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800439rdp_backend_la_LDFLAGS = -module -avoid-version
440rdp_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
441 $(RDP_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800442 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800443rdp_backend_la_CFLAGS = \
444 $(COMPOSITOR_CFLAGS) \
445 $(RDP_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500446 $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700447rdp_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300448 libweston/compositor-rdp.c \
449 libweston/compositor-rdp.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700450 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800451endif
452
453if HAVE_LCMS
454module_LTLIBRARIES += cms-static.la
455cms_static_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800456cms_static_la_LIBADD = $(COMPOSITOR_LIBS) $(LCMS_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500457cms_static_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(LCMS_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800458cms_static_la_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300459 compositor/cms-static.c \
460 compositor/cms-helper.c \
461 compositor/cms-helper.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700462 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800463if ENABLE_COLORD
464module_LTLIBRARIES += cms-colord.la
465cms_colord_la_LDFLAGS = -module -avoid-version
466cms_colord_la_LIBADD = $(COMPOSITOR_LIBS) $(COLORD_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500467cms_colord_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(COLORD_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800468cms_colord_la_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300469 compositor/cms-colord.c \
470 compositor/cms-helper.c \
471 compositor/cms-helper.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700472 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800473endif
474endif
475
476noinst_PROGRAMS += spring-tool
Derek Foreman4ff38742015-06-18 11:43:11 -0500477spring_tool_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800478spring_tool_LDADD = $(COMPOSITOR_LIBS) -lm
479spring_tool_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300480 libweston/spring-tool.c \
481 libweston/animation.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800482 shared/matrix.c \
483 shared/matrix.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300484 libweston/compositor.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800485
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800486if BUILD_CLIENTS
487
488bin_PROGRAMS += weston-terminal weston-info
489
490libexec_PROGRAMS += \
491 weston-desktop-shell \
492 weston-screenshooter \
493 weston-keyboard \
494 weston-simple-im
495
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900496if ENABLE_IVI_SHELL
497libexec_PROGRAMS += \
498 weston-ivi-shell-user-interface
499endif
500
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800501demo_clients = \
502 weston-flower \
503 weston-image \
504 weston-cliptest \
505 weston-dnd \
506 weston-smoke \
507 weston-resizor \
508 weston-eventdemo \
509 weston-clickdot \
Jonas Ådahl61831f42016-03-15 18:14:00 +0800510 weston-confine \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800511 weston-transformed \
512 weston-fullscreen \
513 weston-stacking \
514 weston-calibrator \
515 weston-scaler
516
517if INSTALL_DEMO_CLIENTS
518bin_PROGRAMS += $(demo_clients)
519else
520noinst_PROGRAMS += $(demo_clients)
521endif
522
523
524if BUILD_SIMPLE_CLIENTS
525demo_clients += \
526 weston-simple-shm \
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500527 weston-simple-damage \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800528 weston-simple-touch \
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400529 weston-presentation-shm \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800530 weston-multi-resource
531
Kristian Høgsbergfe84a972014-02-11 14:23:19 -0800532weston_simple_shm_SOURCES = clients/simple-shm.c
533nodist_weston_simple_shm_SOURCES = \
Jonas Ådahle023cbc2016-08-11 23:29:38 +0800534 protocol/xdg-shell-unstable-v6-protocol.c \
535 protocol/xdg-shell-unstable-v6-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800536 protocol/fullscreen-shell-unstable-v1-protocol.c \
537 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Nobuhiko Tanibatafba4ea32014-11-27 13:24:29 +0900538 protocol/ivi-application-protocol.c \
539 protocol/ivi-application-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800540weston_simple_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800541weston_simple_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800542
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500543weston_simple_damage_SOURCES = clients/simple-damage.c
544nodist_weston_simple_damage_SOURCES = \
Pekka Paalanen7b69d6c2016-04-15 17:00:21 +0300545 protocol/viewporter-protocol.c \
546 protocol/viewporter-client-protocol.h \
Jonas Ådahla74eff92016-08-11 23:39:31 +0800547 protocol/xdg-shell-unstable-v6-protocol.c \
548 protocol/xdg-shell-unstable-v6-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800549 protocol/fullscreen-shell-unstable-v1-protocol.c \
550 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500551weston_simple_damage_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
552weston_simple_damage_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
553
Jon A. Cruzb09da242015-06-16 13:15:13 -0700554weston_simple_touch_SOURCES = \
555 clients/simple-touch.c \
556 shared/helpers.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800557weston_simple_touch_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800558weston_simple_touch_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800559
Jon A. Cruzb09da242015-06-16 13:15:13 -0700560weston_presentation_shm_SOURCES = \
561 clients/presentation-shm.c \
562 shared/helpers.h
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400563nodist_weston_presentation_shm_SOURCES = \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200564 protocol/presentation-time-protocol.c \
565 protocol/presentation-time-client-protocol.h
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400566weston_presentation_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Gustavo Zacarias34d59852016-04-21 11:18:48 -0300567weston_presentation_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la -lm $(CLOCK_GETTIME_LIBS)
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400568
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800569weston_multi_resource_SOURCES = clients/multi-resource.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800570weston_multi_resource_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Gustavo Zacarias34d59852016-04-21 11:18:48 -0300571weston_multi_resource_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la $(CLOCK_GETTIME_LIBS) -lm
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800572endif
573
574if BUILD_SIMPLE_EGL_CLIENTS
575demo_clients += weston-simple-egl
Kristian Høgsbergfe84a972014-02-11 14:23:19 -0800576weston_simple_egl_SOURCES = clients/simple-egl.c
577nodist_weston_simple_egl_SOURCES = \
Jonas Ådahl83630022016-08-11 23:13:20 +0800578 protocol/xdg-shell-unstable-v6-protocol.c \
579 protocol/xdg-shell-unstable-v6-client-protocol.h \
Nobuhiko Tanibata4f01a0b2014-11-27 13:24:42 +0900580 protocol/ivi-application-protocol.c \
581 protocol/ivi-application-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800582weston_simple_egl_CFLAGS = $(AM_CFLAGS) $(SIMPLE_EGL_CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800583weston_simple_egl_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
584endif
585
Emmanuel Gil Peyrot3b65b0b2016-01-11 19:04:36 +0000586if BUILD_SIMPLE_DMABUF_INTEL_CLIENT
587demo_clients += weston-simple-dmabuf-intel
588weston_simple_dmabuf_intel_SOURCES = clients/simple-dmabuf-intel.c
589nodist_weston_simple_dmabuf_intel_SOURCES = \
Jonas Ådahl42682622016-08-11 23:44:41 +0800590 protocol/xdg-shell-unstable-v6-protocol.c \
591 protocol/xdg-shell-unstable-v6-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800592 protocol/fullscreen-shell-unstable-v1-protocol.c \
593 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Jonas Ådahl57e48f02015-11-17 16:00:28 +0800594 protocol/linux-dmabuf-unstable-v1-protocol.c \
595 protocol/linux-dmabuf-unstable-v1-client-protocol.h
Emmanuel Gil Peyrot3b65b0b2016-01-11 19:04:36 +0000596weston_simple_dmabuf_intel_CFLAGS = $(AM_CFLAGS) $(SIMPLE_DMABUF_INTEL_CLIENT_CFLAGS)
597weston_simple_dmabuf_intel_LDADD = $(SIMPLE_DMABUF_INTEL_CLIENT_LIBS) libshared.la
Jonas Ådahl57e48f02015-11-17 16:00:28 +0800598BUILT_SOURCES += protocol/linux-dmabuf-unstable-v1-client-protocol.h
George Kiagiadakis53868982014-06-12 16:26:49 +0200599endif
600
Emmanuel Gil Peyrot5d43af32016-01-11 19:04:38 +0000601if BUILD_SIMPLE_DMABUF_V4L_CLIENT
602demo_clients += weston-simple-dmabuf-v4l
603weston_simple_dmabuf_v4l_SOURCES = clients/simple-dmabuf-v4l.c
604nodist_weston_simple_dmabuf_v4l_SOURCES = \
Jonas Ådahl6ccd2862016-08-12 10:01:29 +0800605 protocol/xdg-shell-unstable-v6-protocol.c \
606 protocol/xdg-shell-unstable-v6-client-protocol.h \
Emmanuel Gil Peyrot5d43af32016-01-11 19:04:38 +0000607 protocol/fullscreen-shell-unstable-v1-protocol.c \
608 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
609 protocol/linux-dmabuf-unstable-v1-protocol.c \
610 protocol/linux-dmabuf-unstable-v1-client-protocol.h
611weston_simple_dmabuf_v4l_CFLAGS = $(AM_CFLAGS) $(SIMPLE_DMABUF_V4L_CLIENT_CFLAGS)
612weston_simple_dmabuf_v4l_LDADD = $(SIMPLE_DMABUF_V4L_CLIENT_LIBS) libshared.la
613BUILT_SOURCES += protocol/linux-dmabuf-unstable-v1-client-protocol.h
614endif
615
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800616noinst_LTLIBRARIES += libtoytoolkit.la
617
618libtoytoolkit_la_SOURCES = \
619 clients/window.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700620 clients/window.h \
621 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800622
623nodist_libtoytoolkit_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100624 protocol/text-cursor-position-protocol.c \
625 protocol/text-cursor-position-client-protocol.h \
Pekka Paalanen73511002016-04-15 16:53:41 +0300626 protocol/viewporter-protocol.c \
627 protocol/viewporter-client-protocol.h \
Jonas Ådahlaf7f98b2016-08-09 18:15:43 +0800628 protocol/xdg-shell-unstable-v6-protocol.c \
629 protocol/xdg-shell-unstable-v6-client-protocol.h \
Nobuhiko Tanibatabff1b4a2014-11-27 13:21:34 +0900630 protocol/ivi-application-protocol.c \
Jonas Ådahle5a1bb42014-11-25 10:25:27 +0800631 protocol/ivi-application-client-protocol.h \
632 protocol/pointer-constraints-unstable-v1-protocol.c \
633 protocol/pointer-constraints-unstable-v1-client-protocol.h \
634 protocol/relative-pointer-unstable-v1-protocol.c \
635 protocol/relative-pointer-unstable-v1-client-protocol.h
Jasper St. Pierre0790e392013-12-09 14:58:00 -0500636
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800637BUILT_SOURCES += $(nodist_libtoytoolkit_la_SOURCES)
638
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800639
640libtoytoolkit_la_LIBADD = \
641 $(CLIENT_LIBS) \
642 $(CAIRO_EGL_LIBS) \
Gustavo Zacarias34d59852016-04-21 11:18:48 -0300643 libshared-cairo.la $(CLOCK_GETTIME_LIBS) -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800644libtoytoolkit_la_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(CAIRO_EGL_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800645
646weston_flower_SOURCES = clients/flower.c
647weston_flower_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800648weston_flower_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800649
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100650weston_screenshooter_SOURCES = \
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800651 clients/screenshot.c
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800652nodist_weston_screenshooter_SOURCES = \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800653 protocol/weston-screenshooter-protocol.c \
654 protocol/weston-screenshooter-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800655weston_screenshooter_LDADD = $(CLIENT_LIBS) libshared.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800656weston_screenshooter_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800657
Jon A. Cruzb09da242015-06-16 13:15:13 -0700658weston_terminal_SOURCES = \
659 clients/terminal.c \
660 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800661weston_terminal_LDADD = libtoytoolkit.la -lutil
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800662weston_terminal_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800663
664weston_image_SOURCES = clients/image.c
665weston_image_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800666weston_image_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800667
Pekka Paalanen461e93c2014-08-20 11:58:47 +0300668weston_cliptest_SOURCES = \
669 clients/cliptest.c \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300670 libweston/vertex-clipping.c \
671 libweston/vertex-clipping.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800672weston_cliptest_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800673weston_cliptest_LDADD = libtoytoolkit.la
674
Jon A. Cruzb09da242015-06-16 13:15:13 -0700675weston_dnd_SOURCES = \
676 clients/dnd.c \
677 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800678weston_dnd_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800679weston_dnd_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800680
681weston_smoke_SOURCES = clients/smoke.c
682weston_smoke_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800683weston_smoke_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800684
685weston_resizor_SOURCES = clients/resizor.c
686weston_resizor_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800687weston_resizor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800688
689weston_scaler_SOURCES = clients/scaler.c
690weston_scaler_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800691weston_scaler_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800692
693if HAVE_CAIRO_GLESV2
694demo_clients += weston-nested weston-nested-client
695
Jon A. Cruzb09da242015-06-16 13:15:13 -0700696weston_nested_SOURCES = \
697 clients/nested.c \
698 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800699weston_nested_LDADD = libtoytoolkit.la $(SERVER_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800700weston_nested_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800701
702weston_nested_client_SOURCES = clients/nested-client.c
703weston_nested_client_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800704weston_nested_client_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800705endif
706
Jon A. Cruzb09da242015-06-16 13:15:13 -0700707weston_eventdemo_SOURCES = \
708 clients/eventdemo.c \
709 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800710weston_eventdemo_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800711weston_eventdemo_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800712
Jon A. Cruzb09da242015-06-16 13:15:13 -0700713weston_clickdot_SOURCES = \
714 clients/clickdot.c \
715 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800716weston_clickdot_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800717weston_clickdot_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800718
Jonas Ådahl61831f42016-03-15 18:14:00 +0800719weston_confine_SOURCES = \
720 clients/confine.c \
721 shared/helpers.h
722weston_confine_LDADD = libtoytoolkit.la
723weston_confine_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
724
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800725weston_transformed_SOURCES = clients/transformed.c
726weston_transformed_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800727weston_transformed_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800728
729weston_fullscreen_SOURCES = clients/fullscreen.c
Jason Ekstrand2bb72fe2014-04-02 19:53:52 -0500730nodist_weston_fullscreen_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800731 protocol/fullscreen-shell-unstable-v1-protocol.c \
732 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800733weston_fullscreen_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800734weston_fullscreen_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800735
Jon A. Cruzb09da242015-06-16 13:15:13 -0700736weston_stacking_SOURCES = \
737 clients/stacking.c \
738 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800739weston_stacking_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800740weston_stacking_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800741
Jon A. Cruzb09da242015-06-16 13:15:13 -0700742weston_calibrator_SOURCES = \
743 clients/calibrator.c \
744 shared/helpers.h \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800745 shared/matrix.c \
746 shared/matrix.h
747weston_calibrator_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800748weston_calibrator_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800749
750if BUILD_SUBSURFACES_CLIENT
751demo_clients += weston-subsurfaces
Jon A. Cruzb09da242015-06-16 13:15:13 -0700752weston_subsurfaces_SOURCES = \
753 clients/subsurfaces.c \
754 shared/helpers.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800755weston_subsurfaces_CFLAGS = \
756 $(AM_CFLAGS) \
757 $(SIMPLE_EGL_CLIENT_CFLAGS) \
758 $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800759weston_subsurfaces_LDADD = libtoytoolkit.la $(SIMPLE_EGL_CLIENT_LIBS) -lm
760endif
761
762if HAVE_PANGO
763demo_clients += weston-editor
Jon A. Cruzb09da242015-06-16 13:15:13 -0700764weston_editor_SOURCES = \
765 clients/editor.c \
766 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800767nodist_weston_editor_SOURCES = \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800768 protocol/text-input-unstable-v1-protocol.c \
769 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800770weston_editor_LDADD = libtoytoolkit.la $(PANGO_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800771weston_editor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(PANGO_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800772endif
773
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800774weston_keyboard_SOURCES = clients/keyboard.c
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800775nodist_weston_keyboard_SOURCES = \
776 protocol/weston-desktop-shell-client-protocol.h \
777 protocol/weston-desktop-shell-protocol.c \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800778 protocol/input-method-unstable-v1-protocol.c \
779 protocol/input-method-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800780weston_keyboard_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800781weston_keyboard_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800782
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800783weston_simple_im_SOURCES = clients/weston-simple-im.c
784nodist_weston_simple_im_SOURCES = \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800785 protocol/input-method-unstable-v1-protocol.c \
786 protocol/input-method-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800787weston_simple_im_LDADD = $(CLIENT_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800788weston_simple_im_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800789
Jon A. Cruzb09da242015-06-16 13:15:13 -0700790weston_info_SOURCES = \
791 clients/weston-info.c \
792 shared/helpers.h
Pekka Paalanen93a6afd2014-09-23 22:08:44 -0400793nodist_weston_info_SOURCES = \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200794 protocol/presentation-time-protocol.c \
795 protocol/presentation-time-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800796weston_info_LDADD = $(WESTON_INFO_LIBS) libshared.la
Pekka Paalanen5124b532014-02-03 13:12:34 +0200797weston_info_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800798
Jon A. Cruzb09da242015-06-16 13:15:13 -0700799weston_desktop_shell_SOURCES = \
800 clients/desktop-shell.c \
801 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800802nodist_weston_desktop_shell_SOURCES = \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800803 protocol/weston-desktop-shell-client-protocol.h \
804 protocol/weston-desktop-shell-protocol.c
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800805weston_desktop_shell_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800806weston_desktop_shell_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800807
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900808if ENABLE_IVI_SHELL
Jon A. Cruzb09da242015-06-16 13:15:13 -0700809weston_ivi_shell_user_interface_SOURCES = \
810 clients/ivi-shell-user-interface.c \
811 shared/helpers.h
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900812nodist_weston_ivi_shell_user_interface_SOURCES = \
813 protocol/ivi-hmi-controller-client-protocol.h \
814 protocol/ivi-hmi-controller-protocol.c \
815 protocol/ivi-application-client-protocol.h \
816 protocol/ivi-application-protocol.c
817weston_ivi_shell_user_interface_LDADD = libtoytoolkit.la
818weston_ivi_shell_user_interface_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
819endif
820
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800821if BUILD_FULL_GL_CLIENTS
822demo_clients += weston-gears
823weston_gears_SOURCES = clients/gears.c
824weston_gears_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800825weston_gears_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800826endif
827
828endif
829
830BUILT_SOURCES += \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800831 protocol/weston-screenshooter-protocol.c \
832 protocol/weston-screenshooter-client-protocol.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100833 protocol/text-cursor-position-client-protocol.h \
834 protocol/text-cursor-position-protocol.c \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800835 protocol/text-input-unstable-v1-protocol.c \
836 protocol/text-input-unstable-v1-client-protocol.h \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800837 protocol/input-method-unstable-v1-protocol.c \
838 protocol/input-method-unstable-v1-client-protocol.h \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800839 protocol/weston-desktop-shell-client-protocol.h \
840 protocol/weston-desktop-shell-protocol.c \
Pekka Paalanen73511002016-04-15 16:53:41 +0300841 protocol/viewporter-client-protocol.h \
842 protocol/viewporter-protocol.c \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200843 protocol/presentation-time-protocol.c \
844 protocol/presentation-time-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800845 protocol/fullscreen-shell-unstable-v1-protocol.c \
846 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Jonas Ådahlaf7f98b2016-08-09 18:15:43 +0800847 protocol/xdg-shell-unstable-v6-protocol.c \
848 protocol/xdg-shell-unstable-v6-client-protocol.h \
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900849 protocol/ivi-hmi-controller-protocol.c \
850 protocol/ivi-hmi-controller-client-protocol.h \
851 protocol/ivi-application-protocol.c \
852 protocol/ivi-application-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800853
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -0800854westondatadir = $(datadir)/weston
855dist_westondata_DATA = \
856 data/wayland.svg \
857 data/wayland.png \
858 data/pattern.png \
859 data/terminal.png \
860 data/border.png \
Bryce Harrington6bc52542016-03-24 17:57:39 -0700861 data/icon_editor.png \
862 data/icon_flower.png \
863 data/icon_terminal.png \
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -0800864 data/icon_window.png \
865 data/sign_close.png \
866 data/sign_maximize.png \
Manuel Bachmannd2c68922015-02-16 11:00:36 +0100867 data/sign_minimize.png
868
869if ENABLE_IVI_SHELL
870dist_westondata_DATA += \
Nobuhiko Tanibata001a5432014-03-11 11:54:45 +0900871 data/background.png \
872 data/tiling.png \
873 data/fullscreen.png \
874 data/panel.png \
875 data/random.png \
876 data/sidebyside.png \
877 data/home.png \
878 data/icon_ivi_clickdot.png \
879 data/icon_ivi_flower.png \
880 data/icon_ivi_simple-egl.png \
881 data/icon_ivi_simple-shm.png \
882 data/icon_ivi_smoke.png
Manuel Bachmannd2c68922015-02-16 11:00:36 +0100883endif
Kristian Høgsberge895f142014-01-27 21:46:30 -0800884
885
886if BUILD_WCAP_TOOLS
887bin_PROGRAMS += wcap-decode
888
889wcap_decode_SOURCES = \
890 wcap/main.c \
891 wcap/wcap-decode.c \
892 wcap/wcap-decode.h
893
Derek Foreman4ff38742015-06-18 11:43:11 -0500894wcap_decode_CFLAGS = $(AM_CFLAGS) $(WCAP_CFLAGS)
Kristian Høgsberge895f142014-01-27 21:46:30 -0800895wcap_decode_LDADD = $(WCAP_LIBS)
896endif
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800897
898
899if ENABLE_DESKTOP_SHELL
900
901module_LTLIBRARIES += desktop-shell.la
902
903desktop_shell_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100904 -I$(top_builddir)/protocol \
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800905 -I$(top_srcdir)/shared \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300906 -I$(top_builddir)/libweston \
Emil Velikov4ad45ca2016-07-04 14:57:11 +0100907 -I$(top_srcdir)/libweston \
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800908 -I$(top_builddir)/desktop-shell \
909 -DDATADIR='"$(datadir)"' \
910 -DMODULEDIR='"$(moduledir)"' \
911 -DLIBEXECDIR='"$(libexecdir)"' \
912 -DIN_WESTON
913
914desktop_shell_la_LDFLAGS = -module -avoid-version
Quentin Glidic8f9d90a2016-08-12 10:41:36 +0200915desktop_shell_la_LIBADD = libshared.la libweston-desktop-@LIBWESTON_MAJOR@.la $(COMPOSITOR_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500916desktop_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800917desktop_shell_la_SOURCES = \
918 desktop-shell/shell.h \
919 desktop-shell/shell.c \
920 desktop-shell/exposay.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700921 desktop-shell/input-panel.c \
922 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800923nodist_desktop_shell_la_SOURCES = \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800924 protocol/weston-desktop-shell-protocol.c \
Jonas Ådahl5ac91a12016-08-15 17:31:02 +0800925 protocol/weston-desktop-shell-server-protocol.h
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800926
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800927BUILT_SOURCES += $(nodist_desktop_shell_la_SOURCES)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800928endif
929
Jason Ekstrand946a9482014-04-02 19:53:47 -0500930if ENABLE_FULLSCREEN_SHELL
931
932module_LTLIBRARIES += fullscreen-shell.la
933
934fullscreen_shell_la_CPPFLAGS = \
935 -I$(top_builddir)/protocol \
936 -I$(top_srcdir)/shared \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300937 -I$(top_builddir)/libweston \
Emil Velikov4ad45ca2016-07-04 14:57:11 +0100938 -I$(top_srcdir)/libweston \
Jason Ekstrand946a9482014-04-02 19:53:47 -0500939 -DIN_WESTON
940
941fullscreen_shell_la_LDFLAGS = -module -avoid-version
942fullscreen_shell_la_LIBADD = $(COMPOSITOR_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500943fullscreen_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Jason Ekstrand946a9482014-04-02 19:53:47 -0500944fullscreen_shell_la_SOURCES = \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700945 fullscreen-shell/fullscreen-shell.c \
946 shared/helpers.h
Jason Ekstrand946a9482014-04-02 19:53:47 -0500947nodist_fullscreen_shell_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800948 protocol/fullscreen-shell-unstable-v1-protocol.c \
949 protocol/fullscreen-shell-unstable-v1-server-protocol.h
Jason Ekstrand946a9482014-04-02 19:53:47 -0500950
951BUILT_SOURCES += $(nodist_fullscreen_shell_la_SOURCES)
952endif
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800953
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900954if ENABLE_IVI_SHELL
955
956module_LTLIBRARIES += \
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900957 $(ivi_shell) \
958 $(hmi_controller)
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900959
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900960ivi_shell = ivi-shell.la
961ivi_shell_la_LDFLAGS = -module -avoid-version
Emil Velikov67351452016-07-22 14:52:42 +0100962ivi_shell_la_LIBADD = libshared.la $(COMPOSITOR_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500963ivi_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900964ivi_shell_la_SOURCES = \
Nobuhiko Tanibata28dc18c2014-12-15 13:22:31 +0900965 ivi-shell/ivi-layout-export.h \
966 ivi-shell/ivi-layout-private.h \
Pekka Paalanen32ca7912016-03-15 17:21:00 +0200967 ivi-shell/ivi-layout-shell.h \
Nobuhiko Tanibata28dc18c2014-12-15 13:22:31 +0900968 ivi-shell/ivi-layout.c \
969 ivi-shell/ivi-layout-transition.c \
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900970 ivi-shell/ivi-shell.h \
971 ivi-shell/ivi-shell.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700972 ivi-shell/input-panel-ivi.c \
973 shared/helpers.h
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900974nodist_ivi_shell_la_SOURCES = \
975 protocol/ivi-application-protocol.c \
976 protocol/ivi-application-server-protocol.h
977
978BUILT_SOURCES += $(nodist_ivi_shell_la_SOURCES)
979
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900980hmi_controller = hmi-controller.la
981hmi_controller_la_LDFLAGS = -module -avoid-version
Emil Velikov67351452016-07-22 14:52:42 +0100982hmi_controller_la_LIBADD = libshared.la $(COMPOSITOR_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500983hmi_controller_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900984hmi_controller_la_SOURCES = \
985 ivi-shell/ivi-layout-export.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700986 ivi-shell/hmi-controller.c \
987 shared/helpers.h
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900988nodist_hmi_controller_la_SOURCES = \
989 protocol/ivi-hmi-controller-protocol.c \
990 protocol/ivi-hmi-controller-server-protocol.h
991
992BUILT_SOURCES += $(nodist_hmi_controller_la_SOURCES)
993
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900994endif
995
996
Jason Ekstrand47928d82014-04-02 19:54:01 -0500997if ENABLE_SCREEN_SHARING
998
999module_LTLIBRARIES += screen-share.la
1000
1001screen_share_la_CPPFLAGS = $(AM_CPPFLAGS) -DBINDIR='"$(bindir)"'
1002screen_share_la_LDFLAGS = -module -avoid-version
1003screen_share_la_LIBADD = \
Emil Velikov67351452016-07-22 14:52:42 +01001004 libshared-cairo.la \
Jason Ekstrand47928d82014-04-02 19:54:01 -05001005 $(COMPOSITOR_LIBS) \
Emil Velikov67351452016-07-22 14:52:42 +01001006 $(SCREEN_SHARE_LIBS)
Jason Ekstrand47928d82014-04-02 19:54:01 -05001007screen_share_la_CFLAGS = \
1008 $(COMPOSITOR_CFLAGS) \
1009 $(SCREEN_SHARE_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -05001010 $(AM_CFLAGS)
Jason Ekstrand47928d82014-04-02 19:54:01 -05001011screen_share_la_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +03001012 compositor/screen-share.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001013 shared/helpers.h
Jason Ekstrand47928d82014-04-02 19:54:01 -05001014nodist_screen_share_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +08001015 protocol/fullscreen-shell-unstable-v1-protocol.c \
1016 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Jason Ekstrand47928d82014-04-02 19:54:01 -05001017
1018endif
1019
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001020if ENABLE_XWAYLAND
1021
Giulio Camuffo9c764df2016-06-29 11:54:27 +02001022libweston_module_LTLIBRARIES += xwayland.la
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001023
1024xwayland_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001025 -I$(top_builddir)/protocol \
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001026 -I$(top_srcdir)/shared \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +03001027 -I$(top_builddir)/libweston \
Emil Velikov4ad45ca2016-07-04 14:57:11 +01001028 -I$(top_srcdir)/libweston \
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001029 -I$(top_builddir)/xwayland \
1030 -DDATADIR='"$(datadir)"' \
1031 -DMODULEDIR='"$(moduledir)"' \
Giulio Camuffo9c764df2016-06-29 11:54:27 +02001032 -DLIBEXECDIR='"$(libexecdir)"'
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001033
1034xwayland_la_LDFLAGS = -module -avoid-version
1035xwayland_la_LIBADD = \
Emil Velikov67351452016-07-22 14:52:42 +01001036 libshared-cairo.la \
1037 $(XWAYLAND_LIBS)
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001038xwayland_la_CFLAGS = \
Derek Foreman4ff38742015-06-18 11:43:11 -05001039 $(AM_CFLAGS) \
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001040 $(COMPOSITOR_CFLAGS) \
1041 $(PIXMAN_CFLAGS) \
1042 $(CAIRO_CFLAGS)
1043xwayland_la_SOURCES = \
1044 xwayland/xwayland.h \
Quentin Glidic955cec02016-08-12 10:41:35 +02001045 xwayland/xwayland-internal-interface.h \
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001046 xwayland/window-manager.c \
1047 xwayland/selection.c \
1048 xwayland/dnd.c \
1049 xwayland/launcher.c \
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001050 xwayland/hash.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001051 xwayland/hash.h \
1052 shared/helpers.h
Giulio Camuffo9c764df2016-06-29 11:54:27 +02001053
1054libwestoninclude_HEADERS += xwayland/xwayland-api.h
1055
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001056endif
1057
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001058
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001059#
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001060# Shared utilities
1061#
1062
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001063noinst_LTLIBRARIES += libshared.la libshared-cairo.la \
1064 libzunitc.la libzunitcmain.la
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001065
Derek Foreman4ff38742015-06-18 11:43:11 -05001066libshared_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001067
1068libshared_la_SOURCES = \
1069 shared/config-parser.c \
1070 shared/option-parser.c \
1071 shared/config-parser.h \
Pekka Paalanen899b50b2015-02-12 12:52:21 +02001072 shared/file-util.c \
1073 shared/file-util.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001074 shared/helpers.h \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001075 shared/os-compatibility.c \
Bryce Harringtone99e4bf2016-03-16 14:15:18 -07001076 shared/os-compatibility.h \
1077 shared/xalloc.c \
1078 shared/xalloc.h
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001079
1080libshared_cairo_la_CFLAGS = \
1081 -DDATADIR='"$(datadir)"' \
Derek Foreman4ff38742015-06-18 11:43:11 -05001082 $(AM_CFLAGS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001083 $(COMPOSITOR_CFLAGS) \
1084 $(PIXMAN_CFLAGS) \
1085 $(CAIRO_CFLAGS) \
1086 $(PNG_CFLAGS) \
1087 $(WEBP_CFLAGS)
1088
1089libshared_cairo_la_LIBADD = \
1090 $(PIXMAN_LIBS) \
1091 $(CAIRO_LIBS) \
1092 $(PNG_LIBS) \
1093 $(WEBP_LIBS) \
1094 $(JPEG_LIBS)
1095
1096libshared_cairo_la_SOURCES = \
1097 $(libshared_la_SOURCES) \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001098 shared/helpers.h \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001099 shared/image-loader.c \
1100 shared/image-loader.h \
1101 shared/cairo-util.c \
1102 shared/frame.c \
1103 shared/cairo-util.h
1104
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001105libzunitc_la_SOURCES = \
1106 tools/zunitc/inc/zunitc/zunitc.h \
1107 tools/zunitc/inc/zunitc/zunitc_impl.h \
1108 tools/zunitc/src/zuc_base_logger.c \
1109 tools/zunitc/src/zuc_base_logger.h \
1110 tools/zunitc/src/zuc_collector.c \
1111 tools/zunitc/src/zuc_collector.h \
1112 tools/zunitc/src/zuc_context.h \
1113 tools/zunitc/src/zuc_event.h \
1114 tools/zunitc/src/zuc_event_listener.h \
Jon A. Cruz646aef52015-07-15 19:22:41 -07001115 tools/zunitc/src/zuc_junit_reporter.c \
1116 tools/zunitc/src/zuc_junit_reporter.h \
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001117 tools/zunitc/src/zuc_types.h \
1118 tools/zunitc/src/zunitc_impl.c \
1119 shared/helpers.h
1120
1121libzunitc_la_CFLAGS = \
1122 $(AM_CFLAGS) \
1123 -I$(top_srcdir)/tools/zunitc/inc
1124
1125libzunitc_la_LIBADD = \
Gustavo Zacarias57c83f62016-04-22 10:54:35 -03001126 libshared.la \
1127 $(CLOCK_GETTIME_LIBS)
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001128
Jon A. Cruz646aef52015-07-15 19:22:41 -07001129if ENABLE_JUNIT_XML
1130libzunitc_la_CFLAGS += \
1131 $(LIBXML2_CFLAGS)
1132libzunitc_la_LIBADD += \
1133 $(LIBXML2_LIBS)
1134endif
1135
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001136libzunitcmain_la_SOURCES = \
1137 tools/zunitc/src/main.c
1138
1139libzunitcmain_la_CFLAGS = \
1140 $(AM_CFLAGS) \
1141 -I$(top_srcdir)/tools/zunitc/inc
1142
1143libzunitcmain_la_LIBADD = \
1144 libzunitc.la \
1145 libshared.la
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001146
1147#
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001148# tests subdirectory
1149#
1150
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001151TESTS = $(internal_tests) $(shared_tests) $(module_tests) $(weston_tests) $(ivi_tests)
1152
1153internal_tests = \
1154 internal-screenshot.weston
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001155
1156shared_tests = \
1157 config-parser.test \
Bryce Harrington82b9f2b2016-08-03 17:40:51 -07001158 string.test \
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001159 vertex-clip.test \
1160 zuctest
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001161
1162module_tests = \
Pekka Paalanen827b5d22016-06-29 11:54:26 +02001163 plugin-registry-test.la \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001164 surface-test.la \
1165 surface-global-test.la
1166
1167weston_tests = \
1168 bad_buffer.weston \
1169 keyboard.weston \
1170 event.weston \
1171 button.weston \
1172 text.weston \
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001173 presentation.weston \
Pekka Paalanen82d95a62016-04-19 17:20:42 +03001174 viewporter.weston \
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +03001175 roles.weston \
Marek Chalupa5fd81402015-03-30 09:21:29 -04001176 subsurface.weston \
1177 devices.weston
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001178
Pekka Paalanenf3a34532015-03-24 13:51:05 +02001179ivi_tests =
1180
1181$(ivi_tests) : $(builddir)/tests/weston-ivi.ini
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001182
1183AM_TESTS_ENVIRONMENT = \
Bryce Harringtoned2c6442015-04-15 15:31:11 -07001184 abs_builddir='$(abs_builddir)'; export abs_builddir; \
1185 abs_top_srcdir='$(abs_top_srcdir)'; export abs_top_srcdir;
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001186
1187TEST_EXTENSIONS = .la .weston
1188LA_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
1189WESTON_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
1190
1191clean-local:
Pekka Paalanen15f85632014-05-12 10:08:57 +03001192 -rm -rf logs
Jon A. Cruz179c1862015-07-15 19:22:43 -07001193 -rm -rf $(DOCDIRS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001194
1195# To remove when automake 1.11 support is dropped
1196export abs_builddir
1197
1198noinst_LTLIBRARIES += \
1199 weston-test.la \
1200 $(module_tests) \
1201 libtest-runner.la \
1202 libtest-client.la
1203
1204noinst_PROGRAMS += \
1205 $(setbacklight) \
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001206 $(internal_tests) \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001207 $(shared_tests) \
1208 $(weston_tests) \
Pekka Paalanenf3a34532015-03-24 13:51:05 +02001209 $(ivi_tests) \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001210 matrix-test
1211
1212test_module_ldflags = \
1213 -module -avoid-version -rpath $(libdir) $(COMPOSITOR_LIBS)
1214
Pekka Paalanen827b5d22016-06-29 11:54:26 +02001215plugin_registry_test_la_SOURCES = tests/plugin-registry-test.c
1216plugin_registry_test_la_LDFLAGS = $(test_module_ldflags)
1217plugin_registry_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
1218
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001219surface_global_test_la_SOURCES = tests/surface-global-test.c
1220surface_global_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001221surface_global_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001222
1223surface_test_la_SOURCES = tests/surface-test.c
1224surface_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001225surface_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001226
Emil Velikov67351452016-07-22 14:52:42 +01001227weston_test_la_LIBADD = libshared.la $(COMPOSITOR_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001228weston_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001229weston_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -07001230weston_test_la_SOURCES = \
1231 tests/weston-test.c \
1232 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001233nodist_weston_test_la_SOURCES = \
Derek Foremanf6a65922015-02-24 09:32:14 -06001234 protocol/weston-test-protocol.c \
1235 protocol/weston-test-server-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001236
1237if ENABLE_EGL
1238weston_test_la_CFLAGS += $(EGL_TESTS_CFLAGS)
1239weston_test_la_LDFLAGS += $(EGL_TESTS_LIBS)
1240endif
1241
1242libtest_runner_la_SOURCES = \
1243 tests/weston-test-runner.c \
1244 tests/weston-test-runner.h
Derek Foreman4ff38742015-06-18 11:43:11 -05001245libtest_runner_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001246
1247config_parser_test_SOURCES = tests/config-parser-test.c
Jon A. Cruza67c5412015-07-15 19:22:42 -07001248config_parser_test_LDADD = \
1249 libshared.la \
1250 $(COMPOSITOR_LIBS) \
1251 libzunitc.la \
1252 libzunitcmain.la
1253config_parser_test_CFLAGS = \
1254 $(AM_CFLAGS) \
1255 -I$(top_srcdir)/tools/zunitc/inc
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001256
Bryce Harrington82b9f2b2016-08-03 17:40:51 -07001257string_test_SOURCES = \
1258 tests/string-test.c \
1259 shared/string-helpers.h
1260string_test_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1261string_test_LDADD = libtest-client.la
1262
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001263vertex_clip_test_SOURCES = \
1264 tests/vertex-clip-test.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001265 shared/helpers.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +03001266 libweston/vertex-clipping.c \
1267 libweston/vertex-clipping.h
Gustavo Zacarias34d59852016-04-21 11:18:48 -03001268vertex_clip_test_LDADD = libtest-runner.la -lm $(CLOCK_GETTIME_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001269
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001270libtest_client_la_SOURCES = \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001271 tests/weston-test-client-helper.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001272 tests/weston-test-client-helper.h
1273nodist_libtest_client_la_SOURCES = \
Derek Foremanf6a65922015-02-24 09:32:14 -06001274 protocol/weston-test-protocol.c \
1275 protocol/weston-test-client-protocol.h
Bryce Harrington892122e2015-09-24 14:31:44 -07001276libtest_client_la_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS) $(CAIRO_CFLAGS)
Emil Velikov67351452016-07-22 14:52:42 +01001277libtest_client_la_LIBADD = libshared.la libtest-runner.la $(TEST_CLIENT_LIBS) $(CAIRO_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001278
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001279
1280#
1281# Internal tests - tests functionality of the testsuite itself
1282#
1283
1284internal_screenshot_weston_SOURCES = tests/internal-screenshot-test.c
Bryce Harrington892122e2015-09-24 14:31:44 -07001285internal_screenshot_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1286internal_screenshot_weston_LDADD = libtest-client.la
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001287
1288
1289#
1290# Weston Tests
1291#
1292
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001293bad_buffer_weston_SOURCES = tests/bad-buffer-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001294bad_buffer_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001295bad_buffer_weston_LDADD = libtest-client.la
1296
1297keyboard_weston_SOURCES = tests/keyboard-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001298keyboard_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001299keyboard_weston_LDADD = libtest-client.la
1300
1301event_weston_SOURCES = tests/event-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001302event_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001303event_weston_LDADD = libtest-client.la
1304
1305button_weston_SOURCES = tests/button-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001306button_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001307button_weston_LDADD = libtest-client.la
1308
Marek Chalupa5fd81402015-03-30 09:21:29 -04001309devices_weston_SOURCES = tests/devices-test.c
1310devices_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1311devices_weston_LDADD = libtest-client.la
1312
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001313text_weston_SOURCES = tests/text-test.c
1314nodist_text_weston_SOURCES = \
Jonas Ådahl3bcba342015-11-17 16:00:29 +08001315 protocol/text-input-unstable-v1-protocol.c \
1316 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001317text_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001318text_weston_LDADD = libtest-client.la
1319
1320subsurface_weston_SOURCES = tests/subsurface-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001321subsurface_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001322subsurface_weston_LDADD = libtest-client.la
1323
Jon A. Cruzb09da242015-06-16 13:15:13 -07001324presentation_weston_SOURCES = \
1325 tests/presentation-test.c \
1326 shared/helpers.h
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001327nodist_presentation_weston_SOURCES = \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +02001328 protocol/presentation-time-protocol.c \
1329 protocol/presentation-time-client-protocol.h
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001330presentation_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1331presentation_weston_LDADD = libtest-client.la
1332
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +03001333roles_weston_SOURCES = tests/roles-test.c
1334roles_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1335roles_weston_LDADD = libtest-client.la
1336
Pekka Paalanen82d95a62016-04-19 17:20:42 +03001337viewporter_weston_SOURCES = \
1338 tests/viewporter-test.c \
1339 shared/helpers.h
1340nodist_viewporter_weston_SOURCES = \
1341 protocol/viewporter-protocol.c \
1342 protocol/viewporter-client-protocol.h
1343viewporter_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1344viewporter_weston_LDADD = libtest-client.la
1345
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001346if ENABLE_EGL
1347weston_tests += buffer-count.weston
1348buffer_count_weston_SOURCES = tests/buffer-count-test.c
Pekka Paalanen924cd942016-05-20 17:25:38 +03001349buffer_count_weston_CFLAGS = $(AM_CFLAGS) $(EGL_TESTS_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001350buffer_count_weston_LDADD = libtest-client.la $(EGL_TESTS_LIBS)
1351endif
1352
1353if ENABLE_XWAYLAND_TEST
Pekka Paalanenf9a26262014-05-07 16:26:29 +03001354weston_tests += xwayland-test.weston
1355xwayland_test_weston_SOURCES = tests/xwayland-test.c
Derek Foreman4ff38742015-06-18 11:43:11 -05001356xwayland_test_weston_CFLAGS = $(AM_CFLAGS) $(XWAYLAND_TEST_CFLAGS)
Pekka Paalanenf9a26262014-05-07 16:26:29 +03001357xwayland_test_weston_LDADD = libtest-client.la $(XWAYLAND_TEST_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001358endif
1359
1360matrix_test_SOURCES = \
1361 tests/matrix-test.c \
1362 shared/matrix.c \
1363 shared/matrix.h
1364matrix_test_CPPFLAGS = -DUNIT_TEST
Gustavo Zacarias34d59852016-04-21 11:18:48 -03001365matrix_test_LDADD = -lm $(CLOCK_GETTIME_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001366
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001367if ENABLE_IVI_SHELL
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001368module_tests += \
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001369 ivi-layout-internal-test.la \
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001370 ivi-layout-test.la
1371
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001372ivi_layout_internal_test_la_LIBADD = $(COMPOSITOR_LIBS)
1373ivi_layout_internal_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001374ivi_layout_internal_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001375ivi_layout_internal_test_la_SOURCES = \
1376 tests/ivi_layout-internal-test.c
1377
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001378ivi_layout_test_la_LIBADD = $(COMPOSITOR_LIBS)
1379ivi_layout_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001380ivi_layout_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001381ivi_layout_test_la_SOURCES = \
1382 tests/ivi_layout-test-plugin.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001383 tests/ivi-test.h \
1384 shared/helpers.h
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001385nodist_ivi_layout_test_la_SOURCES = \
1386 protocol/weston-test-protocol.c \
1387 protocol/weston-test-server-protocol.h
1388
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001389ivi_tests += \
1390 ivi-shell-app.weston
1391
1392ivi_shell_app_weston_SOURCES = tests/ivi-shell-app-test.c
1393nodist_ivi_shell_app_weston_SOURCES = \
1394 protocol/ivi-application-protocol.c \
1395 protocol/ivi-application-client-protocol.h
1396ivi_shell_app_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1397ivi_shell_app_weston_LDADD = libtest-client.la
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001398
1399noinst_PROGRAMS += ivi-layout.ivi
1400
1401ivi_layout_ivi_SOURCES = \
1402 tests/ivi_layout-test.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001403 tests/ivi-test.h \
1404 shared/helpers.h
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001405nodist_ivi_layout_ivi_SOURCES = \
1406 protocol/ivi-application-protocol.c \
1407 protocol/ivi-application-client-protocol.h
1408ivi_layout_ivi_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1409ivi_layout_ivi_LDADD = libtest-client.la
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001410endif
1411
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001412if BUILD_SETBACKLIGHT
1413noinst_PROGRAMS += setbacklight
1414setbacklight_SOURCES = \
1415 tests/setbacklight.c \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +03001416 libweston/libbacklight.c \
1417 libweston/libbacklight.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001418setbacklight_CFLAGS = $(AM_CFLAGS) $(SETBACKLIGHT_CFLAGS)
1419setbacklight_LDADD = $(SETBACKLIGHT_LIBS)
1420endif
1421
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001422all-local: zuctest$(EXEEXT)
1423
1424noinst_PROGRAMS += zuctest$(EXEEXT)
1425
1426zuctest_LDADD = \
1427 libzunitc.la \
1428 libzunitcmain.la
1429
1430zuctest_CFLAGS = \
1431 $(AM_CFLAGS) \
1432 -I$(top_srcdir)/tools/zunitc/inc
1433
1434zuctest_SOURCES = \
1435 tools/zunitc/test/fixtures_test.c \
1436 tools/zunitc/test/zunitc_test.c
1437
Derek Foreman1ce2ef52015-05-26 10:21:03 -05001438EXTRA_DIST += \
1439 tests/weston-tests-env \
1440 tests/internal-screenshot.ini \
1441 tests/reference/internal-screenshot-bad-00.png \
1442 tests/reference/internal-screenshot-good-00.png
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001443
1444BUILT_SOURCES += \
Derek Foremanf6a65922015-02-24 09:32:14 -06001445 protocol/weston-test-protocol.c \
1446 protocol/weston-test-server-protocol.h \
1447 protocol/weston-test-client-protocol.h \
Jonas Ådahl3bcba342015-11-17 16:00:29 +08001448 protocol/text-input-unstable-v1-protocol.c \
1449 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001450
Kristian Høgsbergcd312752014-02-01 00:38:15 -08001451EXTRA_DIST += \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +08001452 protocol/weston-desktop-shell.xml \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +08001453 protocol/weston-screenshooter.xml \
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001454 protocol/text-cursor-position.xml \
Derek Foremanf6a65922015-02-24 09:32:14 -06001455 protocol/weston-test.xml \
Nobuhiko Tanibata68cfabb2014-11-27 13:22:53 +09001456 protocol/ivi-application.xml \
Jonas Ådahl57e48f02015-11-17 16:00:28 +08001457 protocol/ivi-hmi-controller.xml
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001458
Pekka Paalanen312fe5f2015-02-09 11:23:48 +02001459#
1460# manual test modules in tests subdirectory
1461#
1462
1463noinst_LTLIBRARIES += \
1464 surface-screenshot.la
1465
Emil Velikov67351452016-07-22 14:52:42 +01001466surface_screenshot_la_LIBADD = libshared.la $(COMPOSITOR_LIBS)
Pekka Paalanen312fe5f2015-02-09 11:23:48 +02001467surface_screenshot_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001468surface_screenshot_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanen312fe5f2015-02-09 11:23:48 +02001469surface_screenshot_la_SOURCES = tests/surface-screenshot.c
1470
1471
1472#
1473# Documentation
1474#
1475
Kristian Høgsberg68c5c102014-01-27 22:33:04 -08001476man_MANS = weston.1 weston.ini.5
1477
1478if ENABLE_DRM_COMPOSITOR
1479man_MANS += weston-drm.7
1480endif
1481
1482MAN_SUBSTS = \
1483 -e 's|__weston_native_backend__|$(WESTON_NATIVE_BACKEND)|g' \
1484 -e 's|__weston_modules_dir__|$(pkglibdir)|g' \
1485 -e 's|__weston_shell_client__|$(WESTON_SHELL_CLIENT)|g' \
1486 -e 's|__version__|$(PACKAGE_VERSION)|g'
1487
1488SUFFIXES = .1 .5 .7 .man
1489
1490%.1 %.5 %.7 : man/%.man
1491 $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
1492
1493EXTRA_DIST += \
1494 man/weston.man \
1495 man/weston-drm.man \
1496 man/weston.ini.man
1497
1498CLEANFILES += $(man_MANS)
1499
Jon A. Cruz179c1862015-07-15 19:22:43 -07001500if ENABLE_DEVDOCS
1501DOXYGEN_INDICES = docs/developer/html/index.html docs/tools/html/index.html
1502
1503docs/developer/html/index.html: doc/doxygen/tooldev.doxygen | docs/developer
1504 cd doc/doxygen && $(DOXYGEN) tooldev.doxygen
1505
1506docs/tools/html/index.html: doc/doxygen/tools.doxygen | docs/tools
1507 cd doc/doxygen && $(DOXYGEN) tools.doxygen
1508endif
1509
1510DOCDIRS = \
1511 docs/developer \
1512 docs/tools
1513
1514$(DOCDIRS):
1515 $(MKDIR_P) $@
1516
1517.PHONY: doc $(DOXYGEN_INDICES)
1518
1519doc: $(DOXYGEN_INDICES)
1520
Jonas Ådahl496adb32015-11-17 16:00:27 +08001521.SECONDEXPANSION:
1522
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001523define protostability
Pekka Paalanen35552aa2016-02-18 16:56:13 +02001524$(if $(findstring unstable,$1),unstable,stable)
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001525endef
1526
1527define protoname
1528$(shell echo $1 | sed 's/\([a-z\-]\+\)-[a-z]\+-v[0-9]\+/\1/')
1529endef
1530
1531protocol/%-protocol.c : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001532 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
1533
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001534protocol/%-server-protocol.h : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001535 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
1536
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001537protocol/%-client-protocol.h : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001538 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@
1539
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001540protocol/%-protocol.c : $(top_srcdir)/protocol/%.xml
1541 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001542
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001543protocol/%-server-protocol.h : $(top_srcdir)/protocol/%.xml
1544 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001545
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001546protocol/%-client-protocol.h : $(top_srcdir)/protocol/%.xml
1547 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@