blob: 95b6d77635d396b82c700c3a966a04833194cb3f [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
Emil Velikov7fe47f32016-07-22 14:51:51 +010064lib_LTLIBRARIES = libweston-@LIBWESTON_MAJOR@.la
65libweston_@LIBWESTON_MAJOR@_la_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON
66libweston_@LIBWESTON_MAJOR@_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(LIBUNWIND_CFLAGS)
67libweston_@LIBWESTON_MAJOR@_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
Emil Velikov7fe47f32016-07-22 14:51:51 +010070libweston_@LIBWESTON_MAJOR@_la_LDFLAGS = -version-info $(LT_VERSION_INFO)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -080071
Emil Velikov7fe47f32016-07-22 14:51:51 +010072libweston_@LIBWESTON_MAJOR@_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
Quentin Glidic248dd102016-08-12 10:41:34 +0200108lib_LTLIBRARIES += libweston-desktop-@LIBWESTON_MAJOR@.la
109libweston_desktop_@LIBWESTON_MAJOR@_la_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON
110libweston_desktop_@LIBWESTON_MAJOR@_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
111libweston_desktop_@LIBWESTON_MAJOR@_la_LIBADD = libweston-@LIBWESTON_MAJOR@.la $(COMPOSITOR_LIBS)
112libweston_desktop_@LIBWESTON_MAJOR@_la_LDFLAGS = -version-info $(LT_VERSION_INFO)
113
114libweston_desktop_@LIBWESTON_MAJOR@_la_SOURCES = \
115 libweston-desktop/client.c \
116 libweston-desktop/internal.h \
117 libweston-desktop/libweston-desktop.c \
118 libweston-desktop/libweston-desktop.h \
119 libweston-desktop/seat.c \
120 libweston-desktop/surface.c \
121 libweston-desktop/wl-shell.c \
122 libweston-desktop/xdg-shell-v5.c \
123 libweston-desktop/xwayland.c
124
125nodist_libweston_desktop_@LIBWESTON_MAJOR@_la_SOURCES = \
126 protocol/xdg-shell-unstable-v5-protocol.c \
127 protocol/xdg-shell-unstable-v5-server-protocol.h
128
Jonas Ådahl5ac91a12016-08-15 17:31:02 +0800129BUILT_SOURCES += $(nodist_libweston_desktop_@LIBWESTON_MAJOR@_la_SOURCES)
130
Quentin Glidic248dd102016-08-12 10:41:34 +0200131libweston-desktop-@LIBWESTON_MAJOR@.la libweston-desktop/libweston_desktop_@LIBWESTON_MAJOR@_la-xdg-shell-v5.lo: protocol/xdg-shell-unstable-v5-server-protocol.h
132
Egor Starkov7ce2e972015-09-25 18:00:27 +0300133if SYSTEMD_NOTIFY_SUPPORT
134module_LTLIBRARIES += systemd-notify.la
135systemd_notify_la_LDFLAGS = -module -avoid-version
136systemd_notify_la_LIBADD = $(SYSTEMD_DAEMON_LIBS)
137systemd_notify_la_CFLAGS = \
Pekka Paalanenaff703e2016-04-05 14:08:11 +0300138 $(COMPOSITOR_CFLAGS) \
139 $(SYSTEMD_DAEMON_CFLAGS) \
Egor Starkov7ce2e972015-09-25 18:00:27 +0300140 $(PIXMAN_CFLAGS) \
141 $(AM_CFLAGS)
142systemd_notify_la_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300143 compositor/systemd-notify.c \
Egor Starkov7ce2e972015-09-25 18:00:27 +0300144 shared/helpers.h \
145 shared/zalloc.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300146 libweston/compositor.h
Egor Starkov7ce2e972015-09-25 18:00:27 +0300147endif
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800148
Emil Velikov7fe47f32016-07-22 14:51:51 +0100149nodist_libweston_@LIBWESTON_MAJOR@_la_SOURCES = \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800150 protocol/weston-screenshooter-protocol.c \
151 protocol/weston-screenshooter-server-protocol.h \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800152 protocol/text-cursor-position-protocol.c \
153 protocol/text-cursor-position-server-protocol.h \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800154 protocol/text-input-unstable-v1-protocol.c \
155 protocol/text-input-unstable-v1-server-protocol.h \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800156 protocol/input-method-unstable-v1-protocol.c \
157 protocol/input-method-unstable-v1-server-protocol.h \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200158 protocol/presentation-time-protocol.c \
159 protocol/presentation-time-server-protocol.h \
Pekka Paalanene95ad5c2016-04-15 14:47:08 +0300160 protocol/viewporter-protocol.c \
161 protocol/viewporter-server-protocol.h \
Jonas Ådahl57e48f02015-11-17 16:00:28 +0800162 protocol/linux-dmabuf-unstable-v1-protocol.c \
Jonas Ådahl30d61d82014-10-22 21:21:17 +0200163 protocol/linux-dmabuf-unstable-v1-server-protocol.h \
164 protocol/relative-pointer-unstable-v1-protocol.c \
Jonas Ådahld3414f22016-07-22 17:56:31 +0800165 protocol/relative-pointer-unstable-v1-server-protocol.h \
166 protocol/pointer-constraints-unstable-v1-protocol.c \
167 protocol/pointer-constraints-unstable-v1-server-protocol.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800168
Emil Velikov7fe47f32016-07-22 14:51:51 +0100169BUILT_SOURCES += $(nodist_libweston_@LIBWESTON_MAJOR@_la_SOURCES)
Giulio Camuffo9e445982016-06-02 21:48:15 +0300170
171bin_PROGRAMS += weston
172
173weston_LDFLAGS = -export-dynamic
174weston_CPPFLAGS = $(AM_CPPFLAGS) -DIN_WESTON \
Giulio Camuffo9c764df2016-06-29 11:54:27 +0200175 -DMODULEDIR='"$(moduledir)"' \
176 -DXSERVER_PATH='"@XSERVER_PATH@"'
Giulio Camuffo9e445982016-06-02 21:48:15 +0300177weston_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(LIBUNWIND_CFLAGS)
Emil Velikov67351452016-07-22 14:52:42 +0100178weston_LDADD = libshared.la libweston-@LIBWESTON_MAJOR@.la \
179 $(COMPOSITOR_LIBS) $(LIBUNWIND_LIBS) \
Giulio Camuffo9e445982016-06-02 21:48:15 +0300180 $(DLOPEN_LIBS) $(LIBINPUT_BACKEND_LIBS) \
Emil Velikov67351452016-07-22 14:52:42 +0100181 -lm
Giulio Camuffo9e445982016-06-02 21:48:15 +0300182
183weston_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300184 compositor/main.c \
185 compositor/weston-screenshooter.c \
Giulio Camuffo9c764df2016-06-29 11:54:27 +0200186 compositor/text-backend.c \
187 compositor/xwayland.c
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800188
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800189# Track this dependency explicitly instead of using BUILT_SOURCES. We
190# add BUILT_SOURCES to CLEANFILES, but we want to keep git-version.h
191# in case we're building from tarballs.
192
Emil Velikova8840242016-07-04 14:57:12 +0100193compositor/main.c : $(top_builddir)/libweston/git-version.h
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300194libweston/compositor.c : $(top_builddir)/libweston/git-version.h
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800195
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800196noinst_LTLIBRARIES += \
197 libsession-helper.la
198
199libsession_helper_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300200 libweston/launcher-util.c \
201 libweston/launcher-util.h \
202 libweston/launcher-impl.h \
203 libweston/weston-launch.h \
204 libweston/launcher-weston-launch.c \
205 libweston/launcher-direct.c
Derek Foreman4ff38742015-06-18 11:43:11 -0500206libsession_helper_la_CFLAGS = $(AM_CFLAGS) $(LIBDRM_CFLAGS) $(PIXMAN_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800207libsession_helper_la_LIBADD = $(LIBDRM_LIBS)
208
209if ENABLE_DBUS
210if HAVE_SYSTEMD_LOGIN
211libsession_helper_la_SOURCES += \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300212 libweston/dbus.h \
213 libweston/dbus.c \
214 libweston/launcher-logind.c
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800215libsession_helper_la_CFLAGS += $(SYSTEMD_LOGIN_CFLAGS) $(DBUS_CFLAGS)
216libsession_helper_la_LIBADD += $(SYSTEMD_LOGIN_LIBS) $(DBUS_LIBS)
217endif
218endif
219
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800220if HAVE_GIT_REPO
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300221libweston/git-version.h : $(top_srcdir)/.git/logs/HEAD
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800222 $(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 -0800223else
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300224libweston/git-version.h :
Kristian Høgsberg1d2dd072014-02-03 10:55:51 -0800225 $(AM_V_GEN)echo "#define BUILD_ID \"unknown (not built from git or tarball)\"" > $@
226
Kristian Høgsberg0aa19e92014-01-31 16:33:48 -0800227endif
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800228
229.FORCE :
230
231if BUILD_WESTON_LAUNCH
232bin_PROGRAMS += weston-launch
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300233weston_launch_SOURCES = libweston/weston-launch.c libweston/weston-launch.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800234weston_launch_CPPFLAGS = -DBINDIR='"$(bindir)"'
235weston_launch_CFLAGS= \
Derek Foreman4ff38742015-06-18 11:43:11 -0500236 $(AM_CFLAGS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800237 $(PAM_CFLAGS) \
238 $(SYSTEMD_LOGIN_CFLAGS) \
239 $(LIBDRM_CFLAGS)
240weston_launch_LDADD = $(PAM_LIBS) $(SYSTEMD_LOGIN_LIBS) $(LIBDRM_LIBS)
241
242if ENABLE_SETUID_INSTALL
243install-exec-hook:
Jon A. Cruz90f23ca2015-04-09 17:52:56 -0700244 can_suid_files=no; \
245 chown root $(DESTDIR)$(bindir)/weston-launch \
246 && chmod u+s $(DESTDIR)$(bindir)/weston-launch \
247 && can_suid_files=yes;\
Derek Foreman6d116792015-04-10 11:55:27 -0500248 if test $$can_suid_files = no; then \
Jon A. Cruz90f23ca2015-04-09 17:52:56 -0700249 echo 'Error: unable to unable to change ownership/setuid on weston-launch.'; \
250 echo 'To skip this step, re-run ./configure using --disable-setuid-install'; \
251 false; \
252 fi
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800253endif
254
255endif # BUILD_WESTON_LAUNCH
256
257pkgconfigdir = $(libdir)/pkgconfig
Quentin Glidic248dd102016-08-12 10:41:34 +0200258pkgconfig_DATA = \
259 libweston/libweston-${LIBWESTON_MAJOR}.pc \
260 libweston-desktop/libweston-desktop-${LIBWESTON_MAJOR}.pc \
261 compositor/weston.pc
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800262
Lubomir Rintel4f4b47a2014-12-28 14:20:49 +0100263wayland_sessiondir = $(datadir)/wayland-sessions
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300264dist_wayland_session_DATA = compositor/weston.desktop
Lubomir Rintel4f4b47a2014-12-28 14:20:49 +0100265
Emil Velikov7fe47f32016-07-22 14:51:51 +0100266libwestonincludedir = $(includedir)/libweston-${LIBWESTON_MAJOR}
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300267libwestoninclude_HEADERS = \
268 libweston/version.h \
269 libweston/compositor.h \
270 libweston/compositor-drm.h \
271 libweston/compositor-fbdev.h \
272 libweston/compositor-headless.h \
273 libweston/compositor-rdp.h \
274 libweston/compositor-wayland.h \
275 libweston/compositor-x11.h \
Pekka Paalanen827b5d22016-06-29 11:54:26 +0200276 libweston/plugin-registry.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300277 libweston/timeline-object.h \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800278 shared/matrix.h \
279 shared/config-parser.h \
Emil Velikovcbcf5452016-07-04 15:34:17 +0100280 shared/zalloc.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800281
Quentin Glidic248dd102016-08-12 10:41:34 +0200282libwestoninclude_HEADERS += \
283 libweston-desktop/libweston-desktop.h
284
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300285westonincludedir = $(includedir)/weston
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300286westoninclude_HEADERS = compositor/weston.h
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300287
Ucan, Emre \(ADITG/SW1\)ae2541d2015-10-15 14:51:43 +0000288if ENABLE_IVI_SHELL
289westoninclude_HEADERS += \
290 ivi-shell/ivi-layout-export.h
291endif
292
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800293if ENABLE_EGL
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300294libweston_module_LTLIBRARIES += gl-renderer.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800295gl_renderer_la_LDFLAGS = -module -avoid-version
296gl_renderer_la_LIBADD = $(COMPOSITOR_LIBS) $(EGL_LIBS)
297gl_renderer_la_CFLAGS = \
298 $(COMPOSITOR_CFLAGS) \
299 $(EGL_CFLAGS) \
Pekka Paalanena3525802014-06-12 16:49:29 +0300300 $(GL_RENDERER_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500301 $(AM_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800302gl_renderer_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300303 libweston/gl-renderer.h \
304 libweston/gl-renderer.c \
305 libweston/vertex-clipping.c \
306 libweston/vertex-clipping.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700307 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800308endif
309
310if ENABLE_X11_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300311libweston_module_LTLIBRARIES += x11-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800312x11_backend_la_LDFLAGS = -module -avoid-version
313x11_backend_la_LIBADD = $(COMPOSITOR_LIBS) $(X11_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800314 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800315x11_backend_la_CFLAGS = \
316 $(COMPOSITOR_CFLAGS) \
317 $(EGL_CFLAGS) \
318 $(PIXMAN_CFLAGS) \
319 $(CAIRO_CFLAGS) \
320 $(X11_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500321 $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700322x11_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300323 libweston/compositor-x11.c \
324 libweston/compositor-x11.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700325 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800326endif
327
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100328INPUT_BACKEND_LIBS = $(LIBINPUT_BACKEND_LIBS)
Peter Hutterer823ad332014-11-26 07:06:31 +1000329INPUT_BACKEND_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300330 libweston/libinput-seat.c \
331 libweston/libinput-seat.h \
332 libweston/libinput-device.c \
333 libweston/libinput-device.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700334 shared/helpers.h
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100335
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800336if ENABLE_DRM_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300337libweston_module_LTLIBRARIES += drm-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800338drm_backend_la_LDFLAGS = -module -avoid-version
339drm_backend_la_LIBADD = \
340 $(COMPOSITOR_LIBS) \
341 $(DRM_COMPOSITOR_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100342 $(INPUT_BACKEND_LIBS) \
Gustavo Zacarias34d59852016-04-21 11:18:48 -0300343 libshared.la \
344 $(CLOCK_GETTIME_LIBS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800345 libsession-helper.la
346drm_backend_la_CFLAGS = \
347 $(COMPOSITOR_CFLAGS) \
348 $(EGL_CFLAGS) \
349 $(DRM_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500350 $(AM_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800351drm_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300352 libweston/compositor-drm.c \
353 libweston/compositor-drm.h \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100354 $(INPUT_BACKEND_SOURCES) \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700355 shared/helpers.h \
Mario Kleinerf507ec32015-06-21 21:25:14 +0200356 shared/timespec-util.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300357 libweston/libbacklight.c \
358 libweston/libbacklight.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800359
360if ENABLE_VAAPI_RECORDER
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300361drm_backend_la_SOURCES += libweston/vaapi-recorder.c libweston/vaapi-recorder.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800362drm_backend_la_LIBADD += $(LIBVA_LIBS)
363drm_backend_la_CFLAGS += $(LIBVA_CFLAGS)
364endif
365endif
366
367if ENABLE_WAYLAND_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300368libweston_module_LTLIBRARIES += wayland-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800369wayland_backend_la_LDFLAGS = -module -avoid-version
370wayland_backend_la_LIBADD = \
371 $(COMPOSITOR_LIBS) \
372 $(WAYLAND_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800373 libshared-cairo.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800374wayland_backend_la_CFLAGS = \
375 $(COMPOSITOR_CFLAGS) \
376 $(EGL_CFLAGS) \
377 $(PIXMAN_CFLAGS) \
378 $(CAIRO_CFLAGS) \
379 $(WAYLAND_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500380 $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700381wayland_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300382 libweston/compositor-wayland.c \
383 libweston/compositor-wayland.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700384 shared/helpers.h
Jason Ekstrand53ee0dc2014-04-02 19:53:54 -0500385nodist_wayland_backend_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800386 protocol/fullscreen-shell-unstable-v1-protocol.c \
387 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800388endif
389
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800390if ENABLE_HEADLESS_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300391libweston_module_LTLIBRARIES += headless-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800392headless_backend_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800393headless_backend_la_LIBADD = $(COMPOSITOR_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500394headless_backend_la_CFLAGS = $(COMPOSITOR_CFLAGS) $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700395headless_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300396 libweston/compositor-headless.c \
397 libweston/compositor-headless.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700398 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800399endif
400
401if ENABLE_FBDEV_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300402libweston_module_LTLIBRARIES += fbdev-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800403fbdev_backend_la_LDFLAGS = -module -avoid-version
404fbdev_backend_la_LIBADD = \
405 $(COMPOSITOR_LIBS) \
406 $(FBDEV_COMPOSITOR_LIBS) \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100407 $(INPUT_BACKEND_LIBS) \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800408 libsession-helper.la \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800409 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800410fbdev_backend_la_CFLAGS = \
411 $(COMPOSITOR_CFLAGS) \
412 $(EGL_CFLAGS) \
413 $(FBDEV_COMPOSITOR_CFLAGS) \
414 $(PIXMAN_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500415 $(AM_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800416fbdev_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300417 libweston/compositor-fbdev.c \
418 libweston/compositor-fbdev.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700419 shared/helpers.h \
Jonas Ådahle0de3c22014-03-12 22:08:42 +0100420 $(INPUT_BACKEND_SOURCES)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800421endif
422
423if ENABLE_RDP_COMPOSITOR
Giulio Camuffo179fcda2016-06-02 21:48:14 +0300424libweston_module_LTLIBRARIES += rdp-backend.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800425rdp_backend_la_LDFLAGS = -module -avoid-version
426rdp_backend_la_LIBADD = $(COMPOSITOR_LIBS) \
427 $(RDP_COMPOSITOR_LIBS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800428 libshared.la
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800429rdp_backend_la_CFLAGS = \
430 $(COMPOSITOR_CFLAGS) \
431 $(RDP_COMPOSITOR_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500432 $(AM_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -0700433rdp_backend_la_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300434 libweston/compositor-rdp.c \
435 libweston/compositor-rdp.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700436 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800437endif
438
439if HAVE_LCMS
440module_LTLIBRARIES += cms-static.la
441cms_static_la_LDFLAGS = -module -avoid-version
Kristian Høgsberg0987f812014-01-27 22:02:41 -0800442cms_static_la_LIBADD = $(COMPOSITOR_LIBS) $(LCMS_LIBS) libshared.la
Derek Foreman4ff38742015-06-18 11:43:11 -0500443cms_static_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(LCMS_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800444cms_static_la_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300445 compositor/cms-static.c \
446 compositor/cms-helper.c \
447 compositor/cms-helper.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700448 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800449if ENABLE_COLORD
450module_LTLIBRARIES += cms-colord.la
451cms_colord_la_LDFLAGS = -module -avoid-version
452cms_colord_la_LIBADD = $(COMPOSITOR_LIBS) $(COLORD_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500453cms_colord_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS) $(COLORD_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800454cms_colord_la_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300455 compositor/cms-colord.c \
456 compositor/cms-helper.c \
457 compositor/cms-helper.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700458 shared/helpers.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800459endif
460endif
461
462noinst_PROGRAMS += spring-tool
Derek Foreman4ff38742015-06-18 11:43:11 -0500463spring_tool_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800464spring_tool_LDADD = $(COMPOSITOR_LIBS) -lm
465spring_tool_SOURCES = \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300466 libweston/spring-tool.c \
467 libweston/animation.c \
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800468 shared/matrix.c \
469 shared/matrix.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300470 libweston/compositor.h
Kristian Høgsbergb7e3ef42014-01-27 23:05:52 -0800471
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800472if BUILD_CLIENTS
473
474bin_PROGRAMS += weston-terminal weston-info
475
476libexec_PROGRAMS += \
477 weston-desktop-shell \
478 weston-screenshooter \
479 weston-keyboard \
480 weston-simple-im
481
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900482if ENABLE_IVI_SHELL
483libexec_PROGRAMS += \
484 weston-ivi-shell-user-interface
485endif
486
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800487demo_clients = \
488 weston-flower \
489 weston-image \
490 weston-cliptest \
491 weston-dnd \
492 weston-smoke \
493 weston-resizor \
494 weston-eventdemo \
495 weston-clickdot \
Jonas Ådahl61831f42016-03-15 18:14:00 +0800496 weston-confine \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800497 weston-transformed \
498 weston-fullscreen \
499 weston-stacking \
500 weston-calibrator \
501 weston-scaler
502
503if INSTALL_DEMO_CLIENTS
504bin_PROGRAMS += $(demo_clients)
505else
506noinst_PROGRAMS += $(demo_clients)
507endif
508
509
510if BUILD_SIMPLE_CLIENTS
511demo_clients += \
512 weston-simple-shm \
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500513 weston-simple-damage \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800514 weston-simple-touch \
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400515 weston-presentation-shm \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800516 weston-multi-resource
517
Kristian Høgsbergfe84a972014-02-11 14:23:19 -0800518weston_simple_shm_SOURCES = clients/simple-shm.c
519nodist_weston_simple_shm_SOURCES = \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800520 protocol/xdg-shell-unstable-v5-protocol.c \
521 protocol/xdg-shell-unstable-v5-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800522 protocol/fullscreen-shell-unstable-v1-protocol.c \
523 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Nobuhiko Tanibatafba4ea32014-11-27 13:24:29 +0900524 protocol/ivi-application-protocol.c \
525 protocol/ivi-application-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800526weston_simple_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800527weston_simple_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800528
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500529weston_simple_damage_SOURCES = clients/simple-damage.c
530nodist_weston_simple_damage_SOURCES = \
Pekka Paalanen7b69d6c2016-04-15 17:00:21 +0300531 protocol/viewporter-protocol.c \
532 protocol/viewporter-client-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800533 protocol/xdg-shell-unstable-v5-protocol.c \
534 protocol/xdg-shell-unstable-v5-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800535 protocol/fullscreen-shell-unstable-v1-protocol.c \
536 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Jason Ekstrand549a53f2014-04-05 09:22:15 -0500537weston_simple_damage_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
538weston_simple_damage_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
539
Jon A. Cruzb09da242015-06-16 13:15:13 -0700540weston_simple_touch_SOURCES = \
541 clients/simple-touch.c \
542 shared/helpers.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800543weston_simple_touch_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800544weston_simple_touch_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800545
Jon A. Cruzb09da242015-06-16 13:15:13 -0700546weston_presentation_shm_SOURCES = \
547 clients/presentation-shm.c \
548 shared/helpers.h
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400549nodist_weston_presentation_shm_SOURCES = \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200550 protocol/presentation-time-protocol.c \
551 protocol/presentation-time-client-protocol.h
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400552weston_presentation_shm_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Gustavo Zacarias34d59852016-04-21 11:18:48 -0300553weston_presentation_shm_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la -lm $(CLOCK_GETTIME_LIBS)
Pekka Paalanenef2b5922014-09-23 22:08:49 -0400554
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800555weston_multi_resource_SOURCES = clients/multi-resource.c
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800556weston_multi_resource_CFLAGS = $(AM_CFLAGS) $(SIMPLE_CLIENT_CFLAGS)
Gustavo Zacarias34d59852016-04-21 11:18:48 -0300557weston_multi_resource_LDADD = $(SIMPLE_CLIENT_LIBS) libshared.la $(CLOCK_GETTIME_LIBS) -lm
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800558endif
559
560if BUILD_SIMPLE_EGL_CLIENTS
561demo_clients += weston-simple-egl
Kristian Høgsbergfe84a972014-02-11 14:23:19 -0800562weston_simple_egl_SOURCES = clients/simple-egl.c
563nodist_weston_simple_egl_SOURCES = \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800564 protocol/xdg-shell-unstable-v5-protocol.c \
565 protocol/xdg-shell-unstable-v5-client-protocol.h \
Nobuhiko Tanibata4f01a0b2014-11-27 13:24:42 +0900566 protocol/ivi-application-protocol.c \
567 protocol/ivi-application-client-protocol.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800568weston_simple_egl_CFLAGS = $(AM_CFLAGS) $(SIMPLE_EGL_CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800569weston_simple_egl_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
570endif
571
Emmanuel Gil Peyrot3b65b0b2016-01-11 19:04:36 +0000572if BUILD_SIMPLE_DMABUF_INTEL_CLIENT
573demo_clients += weston-simple-dmabuf-intel
574weston_simple_dmabuf_intel_SOURCES = clients/simple-dmabuf-intel.c
575nodist_weston_simple_dmabuf_intel_SOURCES = \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800576 protocol/xdg-shell-unstable-v5-protocol.c \
577 protocol/xdg-shell-unstable-v5-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800578 protocol/fullscreen-shell-unstable-v1-protocol.c \
579 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Jonas Ådahl57e48f02015-11-17 16:00:28 +0800580 protocol/linux-dmabuf-unstable-v1-protocol.c \
581 protocol/linux-dmabuf-unstable-v1-client-protocol.h
Emmanuel Gil Peyrot3b65b0b2016-01-11 19:04:36 +0000582weston_simple_dmabuf_intel_CFLAGS = $(AM_CFLAGS) $(SIMPLE_DMABUF_INTEL_CLIENT_CFLAGS)
583weston_simple_dmabuf_intel_LDADD = $(SIMPLE_DMABUF_INTEL_CLIENT_LIBS) libshared.la
Jonas Ådahl57e48f02015-11-17 16:00:28 +0800584BUILT_SOURCES += protocol/linux-dmabuf-unstable-v1-client-protocol.h
George Kiagiadakis53868982014-06-12 16:26:49 +0200585endif
586
Emmanuel Gil Peyrot5d43af32016-01-11 19:04:38 +0000587if BUILD_SIMPLE_DMABUF_V4L_CLIENT
588demo_clients += weston-simple-dmabuf-v4l
589weston_simple_dmabuf_v4l_SOURCES = clients/simple-dmabuf-v4l.c
590nodist_weston_simple_dmabuf_v4l_SOURCES = \
591 protocol/xdg-shell-unstable-v5-protocol.c \
592 protocol/xdg-shell-unstable-v5-client-protocol.h \
593 protocol/fullscreen-shell-unstable-v1-protocol.c \
594 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
595 protocol/linux-dmabuf-unstable-v1-protocol.c \
596 protocol/linux-dmabuf-unstable-v1-client-protocol.h
597weston_simple_dmabuf_v4l_CFLAGS = $(AM_CFLAGS) $(SIMPLE_DMABUF_V4L_CLIENT_CFLAGS)
598weston_simple_dmabuf_v4l_LDADD = $(SIMPLE_DMABUF_V4L_CLIENT_LIBS) libshared.la
599BUILT_SOURCES += protocol/linux-dmabuf-unstable-v1-client-protocol.h
600endif
601
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800602noinst_LTLIBRARIES += libtoytoolkit.la
603
604libtoytoolkit_la_SOURCES = \
605 clients/window.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700606 clients/window.h \
607 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800608
609nodist_libtoytoolkit_la_SOURCES = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100610 protocol/text-cursor-position-protocol.c \
611 protocol/text-cursor-position-client-protocol.h \
Pekka Paalanen73511002016-04-15 16:53:41 +0300612 protocol/viewporter-protocol.c \
613 protocol/viewporter-client-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800614 protocol/xdg-shell-unstable-v5-protocol.c \
615 protocol/xdg-shell-unstable-v5-client-protocol.h \
Nobuhiko Tanibatabff1b4a2014-11-27 13:21:34 +0900616 protocol/ivi-application-protocol.c \
Jonas Ådahle5a1bb42014-11-25 10:25:27 +0800617 protocol/ivi-application-client-protocol.h \
618 protocol/pointer-constraints-unstable-v1-protocol.c \
619 protocol/pointer-constraints-unstable-v1-client-protocol.h \
620 protocol/relative-pointer-unstable-v1-protocol.c \
621 protocol/relative-pointer-unstable-v1-client-protocol.h
Jasper St. Pierre0790e392013-12-09 14:58:00 -0500622
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800623BUILT_SOURCES += $(nodist_libtoytoolkit_la_SOURCES)
624
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800625
626libtoytoolkit_la_LIBADD = \
627 $(CLIENT_LIBS) \
628 $(CAIRO_EGL_LIBS) \
Gustavo Zacarias34d59852016-04-21 11:18:48 -0300629 libshared-cairo.la $(CLOCK_GETTIME_LIBS) -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800630libtoytoolkit_la_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(CAIRO_EGL_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800631
632weston_flower_SOURCES = clients/flower.c
633weston_flower_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800634weston_flower_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800635
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100636weston_screenshooter_SOURCES = \
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800637 clients/screenshot.c
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800638nodist_weston_screenshooter_SOURCES = \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800639 protocol/weston-screenshooter-protocol.c \
640 protocol/weston-screenshooter-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800641weston_screenshooter_LDADD = $(CLIENT_LIBS) libshared.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800642weston_screenshooter_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800643
Jon A. Cruzb09da242015-06-16 13:15:13 -0700644weston_terminal_SOURCES = \
645 clients/terminal.c \
646 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800647weston_terminal_LDADD = libtoytoolkit.la -lutil
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800648weston_terminal_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800649
650weston_image_SOURCES = clients/image.c
651weston_image_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800652weston_image_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800653
Pekka Paalanen461e93c2014-08-20 11:58:47 +0300654weston_cliptest_SOURCES = \
655 clients/cliptest.c \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300656 libweston/vertex-clipping.c \
657 libweston/vertex-clipping.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -0800658weston_cliptest_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800659weston_cliptest_LDADD = libtoytoolkit.la
660
Jon A. Cruzb09da242015-06-16 13:15:13 -0700661weston_dnd_SOURCES = \
662 clients/dnd.c \
663 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800664weston_dnd_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800665weston_dnd_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800666
667weston_smoke_SOURCES = clients/smoke.c
668weston_smoke_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800669weston_smoke_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800670
671weston_resizor_SOURCES = clients/resizor.c
672weston_resizor_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800673weston_resizor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800674
675weston_scaler_SOURCES = clients/scaler.c
676weston_scaler_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800677weston_scaler_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800678
679if HAVE_CAIRO_GLESV2
680demo_clients += weston-nested weston-nested-client
681
Jon A. Cruzb09da242015-06-16 13:15:13 -0700682weston_nested_SOURCES = \
683 clients/nested.c \
684 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800685weston_nested_LDADD = libtoytoolkit.la $(SERVER_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800686weston_nested_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800687
688weston_nested_client_SOURCES = clients/nested-client.c
689weston_nested_client_LDADD = $(SIMPLE_EGL_CLIENT_LIBS) -lm
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800690weston_nested_client_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800691endif
692
Jon A. Cruzb09da242015-06-16 13:15:13 -0700693weston_eventdemo_SOURCES = \
694 clients/eventdemo.c \
695 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800696weston_eventdemo_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800697weston_eventdemo_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800698
Jon A. Cruzb09da242015-06-16 13:15:13 -0700699weston_clickdot_SOURCES = \
700 clients/clickdot.c \
701 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800702weston_clickdot_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800703weston_clickdot_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800704
Jonas Ådahl61831f42016-03-15 18:14:00 +0800705weston_confine_SOURCES = \
706 clients/confine.c \
707 shared/helpers.h
708weston_confine_LDADD = libtoytoolkit.la
709weston_confine_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
710
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800711weston_transformed_SOURCES = clients/transformed.c
712weston_transformed_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800713weston_transformed_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800714
715weston_fullscreen_SOURCES = clients/fullscreen.c
Jason Ekstrand2bb72fe2014-04-02 19:53:52 -0500716nodist_weston_fullscreen_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800717 protocol/fullscreen-shell-unstable-v1-protocol.c \
718 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800719weston_fullscreen_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800720weston_fullscreen_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800721
Jon A. Cruzb09da242015-06-16 13:15:13 -0700722weston_stacking_SOURCES = \
723 clients/stacking.c \
724 shared/helpers.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800725weston_stacking_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800726weston_stacking_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800727
Jon A. Cruzb09da242015-06-16 13:15:13 -0700728weston_calibrator_SOURCES = \
729 clients/calibrator.c \
730 shared/helpers.h \
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800731 shared/matrix.c \
732 shared/matrix.h
733weston_calibrator_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800734weston_calibrator_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800735
736if BUILD_SUBSURFACES_CLIENT
737demo_clients += weston-subsurfaces
Jon A. Cruzb09da242015-06-16 13:15:13 -0700738weston_subsurfaces_SOURCES = \
739 clients/subsurfaces.c \
740 shared/helpers.h
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800741weston_subsurfaces_CFLAGS = \
742 $(AM_CFLAGS) \
743 $(SIMPLE_EGL_CLIENT_CFLAGS) \
744 $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800745weston_subsurfaces_LDADD = libtoytoolkit.la $(SIMPLE_EGL_CLIENT_LIBS) -lm
746endif
747
748if HAVE_PANGO
749demo_clients += weston-editor
Jon A. Cruzb09da242015-06-16 13:15:13 -0700750weston_editor_SOURCES = \
751 clients/editor.c \
752 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800753nodist_weston_editor_SOURCES = \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800754 protocol/text-input-unstable-v1-protocol.c \
755 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800756weston_editor_LDADD = libtoytoolkit.la $(PANGO_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800757weston_editor_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS) $(PANGO_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800758endif
759
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800760weston_keyboard_SOURCES = clients/keyboard.c
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800761nodist_weston_keyboard_SOURCES = \
762 protocol/weston-desktop-shell-client-protocol.h \
763 protocol/weston-desktop-shell-protocol.c \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800764 protocol/input-method-unstable-v1-protocol.c \
765 protocol/input-method-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800766weston_keyboard_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800767weston_keyboard_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800768
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800769weston_simple_im_SOURCES = clients/weston-simple-im.c
770nodist_weston_simple_im_SOURCES = \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800771 protocol/input-method-unstable-v1-protocol.c \
772 protocol/input-method-unstable-v1-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800773weston_simple_im_LDADD = $(CLIENT_LIBS)
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800774weston_simple_im_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800775
Jon A. Cruzb09da242015-06-16 13:15:13 -0700776weston_info_SOURCES = \
777 clients/weston-info.c \
778 shared/helpers.h
Pekka Paalanen93a6afd2014-09-23 22:08:44 -0400779nodist_weston_info_SOURCES = \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200780 protocol/presentation-time-protocol.c \
781 protocol/presentation-time-client-protocol.h
Kristian Høgsberg4c1bfc92014-02-11 14:21:39 -0800782weston_info_LDADD = $(WESTON_INFO_LIBS) libshared.la
Pekka Paalanen5124b532014-02-03 13:12:34 +0200783weston_info_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800784
Jon A. Cruzb09da242015-06-16 13:15:13 -0700785weston_desktop_shell_SOURCES = \
786 clients/desktop-shell.c \
787 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800788nodist_weston_desktop_shell_SOURCES = \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800789 protocol/weston-desktop-shell-client-protocol.h \
790 protocol/weston-desktop-shell-protocol.c
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800791weston_desktop_shell_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800792weston_desktop_shell_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800793
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900794if ENABLE_IVI_SHELL
Jon A. Cruzb09da242015-06-16 13:15:13 -0700795weston_ivi_shell_user_interface_SOURCES = \
796 clients/ivi-shell-user-interface.c \
797 shared/helpers.h
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900798nodist_weston_ivi_shell_user_interface_SOURCES = \
799 protocol/ivi-hmi-controller-client-protocol.h \
800 protocol/ivi-hmi-controller-protocol.c \
801 protocol/ivi-application-client-protocol.h \
802 protocol/ivi-application-protocol.c
803weston_ivi_shell_user_interface_LDADD = libtoytoolkit.la
804weston_ivi_shell_user_interface_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
805endif
806
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800807if BUILD_FULL_GL_CLIENTS
808demo_clients += weston-gears
809weston_gears_SOURCES = clients/gears.c
810weston_gears_LDADD = libtoytoolkit.la
Kristian Høgsberge5b4dce2014-02-05 22:00:59 -0800811weston_gears_CFLAGS = $(AM_CFLAGS) $(CLIENT_CFLAGS)
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800812endif
813
814endif
815
816BUILT_SOURCES += \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +0800817 protocol/weston-screenshooter-protocol.c \
818 protocol/weston-screenshooter-client-protocol.h \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100819 protocol/text-cursor-position-client-protocol.h \
820 protocol/text-cursor-position-protocol.c \
Jonas Ådahl3bcba342015-11-17 16:00:29 +0800821 protocol/text-input-unstable-v1-protocol.c \
822 protocol/text-input-unstable-v1-client-protocol.h \
Jonas Ådahlb57f4722015-11-17 16:00:30 +0800823 protocol/input-method-unstable-v1-protocol.c \
824 protocol/input-method-unstable-v1-client-protocol.h \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800825 protocol/weston-desktop-shell-client-protocol.h \
826 protocol/weston-desktop-shell-protocol.c \
Pekka Paalanen73511002016-04-15 16:53:41 +0300827 protocol/viewporter-client-protocol.h \
828 protocol/viewporter-protocol.c \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +0200829 protocol/presentation-time-protocol.c \
830 protocol/presentation-time-client-protocol.h \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800831 protocol/fullscreen-shell-unstable-v1-protocol.c \
832 protocol/fullscreen-shell-unstable-v1-client-protocol.h \
Jonas Ådahl2a229332015-11-17 16:00:32 +0800833 protocol/xdg-shell-unstable-v5-protocol.c \
834 protocol/xdg-shell-unstable-v5-client-protocol.h \
Nobuhiko Tanibata923bc142014-11-27 13:23:32 +0900835 protocol/ivi-hmi-controller-protocol.c \
836 protocol/ivi-hmi-controller-client-protocol.h \
837 protocol/ivi-application-protocol.c \
838 protocol/ivi-application-client-protocol.h
Kristian Høgsberge73eccd2014-01-31 16:15:11 -0800839
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -0800840westondatadir = $(datadir)/weston
841dist_westondata_DATA = \
842 data/wayland.svg \
843 data/wayland.png \
844 data/pattern.png \
845 data/terminal.png \
846 data/border.png \
Bryce Harrington6bc52542016-03-24 17:57:39 -0700847 data/icon_editor.png \
848 data/icon_flower.png \
849 data/icon_terminal.png \
Kristian Høgsberg5b9f9f82014-01-27 21:40:28 -0800850 data/icon_window.png \
851 data/sign_close.png \
852 data/sign_maximize.png \
Manuel Bachmannd2c68922015-02-16 11:00:36 +0100853 data/sign_minimize.png
854
855if ENABLE_IVI_SHELL
856dist_westondata_DATA += \
Nobuhiko Tanibata001a5432014-03-11 11:54:45 +0900857 data/background.png \
858 data/tiling.png \
859 data/fullscreen.png \
860 data/panel.png \
861 data/random.png \
862 data/sidebyside.png \
863 data/home.png \
864 data/icon_ivi_clickdot.png \
865 data/icon_ivi_flower.png \
866 data/icon_ivi_simple-egl.png \
867 data/icon_ivi_simple-shm.png \
868 data/icon_ivi_smoke.png
Manuel Bachmannd2c68922015-02-16 11:00:36 +0100869endif
Kristian Høgsberge895f142014-01-27 21:46:30 -0800870
871
872if BUILD_WCAP_TOOLS
873bin_PROGRAMS += wcap-decode
874
875wcap_decode_SOURCES = \
876 wcap/main.c \
877 wcap/wcap-decode.c \
878 wcap/wcap-decode.h
879
Derek Foreman4ff38742015-06-18 11:43:11 -0500880wcap_decode_CFLAGS = $(AM_CFLAGS) $(WCAP_CFLAGS)
Kristian Høgsberge895f142014-01-27 21:46:30 -0800881wcap_decode_LDADD = $(WCAP_LIBS)
882endif
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800883
884
885if ENABLE_DESKTOP_SHELL
886
887module_LTLIBRARIES += desktop-shell.la
888
889desktop_shell_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +0100890 -I$(top_builddir)/protocol \
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800891 -I$(top_srcdir)/shared \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300892 -I$(top_builddir)/libweston \
Emil Velikov4ad45ca2016-07-04 14:57:11 +0100893 -I$(top_srcdir)/libweston \
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800894 -I$(top_builddir)/desktop-shell \
895 -DDATADIR='"$(datadir)"' \
896 -DMODULEDIR='"$(moduledir)"' \
897 -DLIBEXECDIR='"$(libexecdir)"' \
898 -DIN_WESTON
899
900desktop_shell_la_LDFLAGS = -module -avoid-version
Quentin Glidic8f9d90a2016-08-12 10:41:36 +0200901desktop_shell_la_LIBADD = libshared.la libweston-desktop-@LIBWESTON_MAJOR@.la $(COMPOSITOR_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500902desktop_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800903desktop_shell_la_SOURCES = \
904 desktop-shell/shell.h \
905 desktop-shell/shell.c \
906 desktop-shell/exposay.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700907 desktop-shell/input-panel.c \
908 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800909nodist_desktop_shell_la_SOURCES = \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +0800910 protocol/weston-desktop-shell-protocol.c \
Jonas Ådahl5ac91a12016-08-15 17:31:02 +0800911 protocol/weston-desktop-shell-server-protocol.h
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800912
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -0800913BUILT_SOURCES += $(nodist_desktop_shell_la_SOURCES)
Kristian Høgsbergbc00dbe2014-01-27 21:56:12 -0800914endif
915
Jason Ekstrand946a9482014-04-02 19:53:47 -0500916if ENABLE_FULLSCREEN_SHELL
917
918module_LTLIBRARIES += fullscreen-shell.la
919
920fullscreen_shell_la_CPPFLAGS = \
921 -I$(top_builddir)/protocol \
922 -I$(top_srcdir)/shared \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +0300923 -I$(top_builddir)/libweston \
Emil Velikov4ad45ca2016-07-04 14:57:11 +0100924 -I$(top_srcdir)/libweston \
Jason Ekstrand946a9482014-04-02 19:53:47 -0500925 -DIN_WESTON
926
927fullscreen_shell_la_LDFLAGS = -module -avoid-version
928fullscreen_shell_la_LIBADD = $(COMPOSITOR_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500929fullscreen_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Jason Ekstrand946a9482014-04-02 19:53:47 -0500930fullscreen_shell_la_SOURCES = \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700931 fullscreen-shell/fullscreen-shell.c \
932 shared/helpers.h
Jason Ekstrand946a9482014-04-02 19:53:47 -0500933nodist_fullscreen_shell_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +0800934 protocol/fullscreen-shell-unstable-v1-protocol.c \
935 protocol/fullscreen-shell-unstable-v1-server-protocol.h
Jason Ekstrand946a9482014-04-02 19:53:47 -0500936
937BUILT_SOURCES += $(nodist_fullscreen_shell_la_SOURCES)
938endif
Kristian Høgsberg058bd322014-01-27 21:59:55 -0800939
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900940if ENABLE_IVI_SHELL
941
942module_LTLIBRARIES += \
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900943 $(ivi_shell) \
944 $(hmi_controller)
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900945
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900946ivi_shell = ivi-shell.la
947ivi_shell_la_LDFLAGS = -module -avoid-version
Emil Velikov67351452016-07-22 14:52:42 +0100948ivi_shell_la_LIBADD = libshared.la $(COMPOSITOR_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500949ivi_shell_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900950ivi_shell_la_SOURCES = \
Nobuhiko Tanibata28dc18c2014-12-15 13:22:31 +0900951 ivi-shell/ivi-layout-export.h \
952 ivi-shell/ivi-layout-private.h \
Pekka Paalanen32ca7912016-03-15 17:21:00 +0200953 ivi-shell/ivi-layout-shell.h \
Nobuhiko Tanibata28dc18c2014-12-15 13:22:31 +0900954 ivi-shell/ivi-layout.c \
955 ivi-shell/ivi-layout-transition.c \
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900956 ivi-shell/ivi-shell.h \
957 ivi-shell/ivi-shell.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700958 ivi-shell/input-panel-ivi.c \
959 shared/helpers.h
Nobuhiko Tanibata487adc42014-11-27 13:22:37 +0900960nodist_ivi_shell_la_SOURCES = \
961 protocol/ivi-application-protocol.c \
962 protocol/ivi-application-server-protocol.h
963
964BUILT_SOURCES += $(nodist_ivi_shell_la_SOURCES)
965
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900966hmi_controller = hmi-controller.la
967hmi_controller_la_LDFLAGS = -module -avoid-version
Emil Velikov67351452016-07-22 14:52:42 +0100968hmi_controller_la_LIBADD = libshared.la $(COMPOSITOR_LIBS)
Derek Foreman4ff38742015-06-18 11:43:11 -0500969hmi_controller_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900970hmi_controller_la_SOURCES = \
971 ivi-shell/ivi-layout-export.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700972 ivi-shell/hmi-controller.c \
973 shared/helpers.h
Nobuhiko Tanibata4f6853b2014-11-27 13:23:12 +0900974nodist_hmi_controller_la_SOURCES = \
975 protocol/ivi-hmi-controller-protocol.c \
976 protocol/ivi-hmi-controller-server-protocol.h
977
978BUILT_SOURCES += $(nodist_hmi_controller_la_SOURCES)
979
Nobuhiko Tanibata6f9df652014-11-27 13:22:00 +0900980endif
981
982
Jason Ekstrand47928d82014-04-02 19:54:01 -0500983if ENABLE_SCREEN_SHARING
984
985module_LTLIBRARIES += screen-share.la
986
987screen_share_la_CPPFLAGS = $(AM_CPPFLAGS) -DBINDIR='"$(bindir)"'
988screen_share_la_LDFLAGS = -module -avoid-version
989screen_share_la_LIBADD = \
Emil Velikov67351452016-07-22 14:52:42 +0100990 libshared-cairo.la \
Jason Ekstrand47928d82014-04-02 19:54:01 -0500991 $(COMPOSITOR_LIBS) \
Emil Velikov67351452016-07-22 14:52:42 +0100992 $(SCREEN_SHARE_LIBS)
Jason Ekstrand47928d82014-04-02 19:54:01 -0500993screen_share_la_CFLAGS = \
994 $(COMPOSITOR_CFLAGS) \
995 $(SCREEN_SHARE_CFLAGS) \
Derek Foreman4ff38742015-06-18 11:43:11 -0500996 $(AM_CFLAGS)
Jason Ekstrand47928d82014-04-02 19:54:01 -0500997screen_share_la_SOURCES = \
Pekka Paalanen58f98c92016-06-03 16:45:21 +0300998 compositor/screen-share.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -0700999 shared/helpers.h
Jason Ekstrand47928d82014-04-02 19:54:01 -05001000nodist_screen_share_la_SOURCES = \
Jonas Ådahl496adb32015-11-17 16:00:27 +08001001 protocol/fullscreen-shell-unstable-v1-protocol.c \
1002 protocol/fullscreen-shell-unstable-v1-client-protocol.h
Jason Ekstrand47928d82014-04-02 19:54:01 -05001003
1004endif
1005
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001006if ENABLE_XWAYLAND
1007
Giulio Camuffo9c764df2016-06-29 11:54:27 +02001008libweston_module_LTLIBRARIES += xwayland.la
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001009
1010xwayland_la_CPPFLAGS = \
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001011 -I$(top_builddir)/protocol \
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001012 -I$(top_srcdir)/shared \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +03001013 -I$(top_builddir)/libweston \
Emil Velikov4ad45ca2016-07-04 14:57:11 +01001014 -I$(top_srcdir)/libweston \
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001015 -I$(top_builddir)/xwayland \
1016 -DDATADIR='"$(datadir)"' \
1017 -DMODULEDIR='"$(moduledir)"' \
Giulio Camuffo9c764df2016-06-29 11:54:27 +02001018 -DLIBEXECDIR='"$(libexecdir)"'
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001019
1020xwayland_la_LDFLAGS = -module -avoid-version
1021xwayland_la_LIBADD = \
Emil Velikov67351452016-07-22 14:52:42 +01001022 libshared-cairo.la \
1023 $(XWAYLAND_LIBS)
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001024xwayland_la_CFLAGS = \
Derek Foreman4ff38742015-06-18 11:43:11 -05001025 $(AM_CFLAGS) \
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001026 $(COMPOSITOR_CFLAGS) \
1027 $(PIXMAN_CFLAGS) \
1028 $(CAIRO_CFLAGS)
1029xwayland_la_SOURCES = \
1030 xwayland/xwayland.h \
Quentin Glidic955cec02016-08-12 10:41:35 +02001031 xwayland/xwayland-internal-interface.h \
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001032 xwayland/window-manager.c \
1033 xwayland/selection.c \
1034 xwayland/dnd.c \
1035 xwayland/launcher.c \
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001036 xwayland/hash.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001037 xwayland/hash.h \
1038 shared/helpers.h
Giulio Camuffo9c764df2016-06-29 11:54:27 +02001039
1040libwestoninclude_HEADERS += xwayland/xwayland-api.h
1041
Kristian Høgsberg058bd322014-01-27 21:59:55 -08001042endif
1043
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001044
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001045#
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001046# Shared utilities
1047#
1048
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001049noinst_LTLIBRARIES += libshared.la libshared-cairo.la \
1050 libzunitc.la libzunitcmain.la
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001051
Derek Foreman4ff38742015-06-18 11:43:11 -05001052libshared_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001053
1054libshared_la_SOURCES = \
1055 shared/config-parser.c \
1056 shared/option-parser.c \
1057 shared/config-parser.h \
Pekka Paalanen899b50b2015-02-12 12:52:21 +02001058 shared/file-util.c \
1059 shared/file-util.h \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001060 shared/helpers.h \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001061 shared/os-compatibility.c \
Bryce Harringtone99e4bf2016-03-16 14:15:18 -07001062 shared/os-compatibility.h \
1063 shared/xalloc.c \
1064 shared/xalloc.h
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001065
1066libshared_cairo_la_CFLAGS = \
1067 -DDATADIR='"$(datadir)"' \
Derek Foreman4ff38742015-06-18 11:43:11 -05001068 $(AM_CFLAGS) \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001069 $(COMPOSITOR_CFLAGS) \
1070 $(PIXMAN_CFLAGS) \
1071 $(CAIRO_CFLAGS) \
1072 $(PNG_CFLAGS) \
1073 $(WEBP_CFLAGS)
1074
1075libshared_cairo_la_LIBADD = \
1076 $(PIXMAN_LIBS) \
1077 $(CAIRO_LIBS) \
1078 $(PNG_LIBS) \
1079 $(WEBP_LIBS) \
1080 $(JPEG_LIBS)
1081
1082libshared_cairo_la_SOURCES = \
1083 $(libshared_la_SOURCES) \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001084 shared/helpers.h \
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001085 shared/image-loader.c \
1086 shared/image-loader.h \
1087 shared/cairo-util.c \
1088 shared/frame.c \
1089 shared/cairo-util.h
1090
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001091libzunitc_la_SOURCES = \
1092 tools/zunitc/inc/zunitc/zunitc.h \
1093 tools/zunitc/inc/zunitc/zunitc_impl.h \
1094 tools/zunitc/src/zuc_base_logger.c \
1095 tools/zunitc/src/zuc_base_logger.h \
1096 tools/zunitc/src/zuc_collector.c \
1097 tools/zunitc/src/zuc_collector.h \
1098 tools/zunitc/src/zuc_context.h \
1099 tools/zunitc/src/zuc_event.h \
1100 tools/zunitc/src/zuc_event_listener.h \
Jon A. Cruz646aef52015-07-15 19:22:41 -07001101 tools/zunitc/src/zuc_junit_reporter.c \
1102 tools/zunitc/src/zuc_junit_reporter.h \
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001103 tools/zunitc/src/zuc_types.h \
1104 tools/zunitc/src/zunitc_impl.c \
1105 shared/helpers.h
1106
1107libzunitc_la_CFLAGS = \
1108 $(AM_CFLAGS) \
1109 -I$(top_srcdir)/tools/zunitc/inc
1110
1111libzunitc_la_LIBADD = \
Gustavo Zacarias57c83f62016-04-22 10:54:35 -03001112 libshared.la \
1113 $(CLOCK_GETTIME_LIBS)
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001114
Jon A. Cruz646aef52015-07-15 19:22:41 -07001115if ENABLE_JUNIT_XML
1116libzunitc_la_CFLAGS += \
1117 $(LIBXML2_CFLAGS)
1118libzunitc_la_LIBADD += \
1119 $(LIBXML2_LIBS)
1120endif
1121
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001122libzunitcmain_la_SOURCES = \
1123 tools/zunitc/src/main.c
1124
1125libzunitcmain_la_CFLAGS = \
1126 $(AM_CFLAGS) \
1127 -I$(top_srcdir)/tools/zunitc/inc
1128
1129libzunitcmain_la_LIBADD = \
1130 libzunitc.la \
1131 libshared.la
Kristian Høgsberg0987f812014-01-27 22:02:41 -08001132
1133#
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001134# tests subdirectory
1135#
1136
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001137TESTS = $(internal_tests) $(shared_tests) $(module_tests) $(weston_tests) $(ivi_tests)
1138
1139internal_tests = \
1140 internal-screenshot.weston
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001141
1142shared_tests = \
1143 config-parser.test \
Bryce Harrington82b9f2b2016-08-03 17:40:51 -07001144 string.test \
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001145 vertex-clip.test \
1146 zuctest
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001147
1148module_tests = \
Pekka Paalanen827b5d22016-06-29 11:54:26 +02001149 plugin-registry-test.la \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001150 surface-test.la \
1151 surface-global-test.la
1152
1153weston_tests = \
1154 bad_buffer.weston \
1155 keyboard.weston \
1156 event.weston \
1157 button.weston \
1158 text.weston \
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001159 presentation.weston \
Pekka Paalanen82d95a62016-04-19 17:20:42 +03001160 viewporter.weston \
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +03001161 roles.weston \
Marek Chalupa5fd81402015-03-30 09:21:29 -04001162 subsurface.weston \
1163 devices.weston
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001164
Pekka Paalanenf3a34532015-03-24 13:51:05 +02001165ivi_tests =
1166
1167$(ivi_tests) : $(builddir)/tests/weston-ivi.ini
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001168
1169AM_TESTS_ENVIRONMENT = \
Bryce Harringtoned2c6442015-04-15 15:31:11 -07001170 abs_builddir='$(abs_builddir)'; export abs_builddir; \
1171 abs_top_srcdir='$(abs_top_srcdir)'; export abs_top_srcdir;
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001172
1173TEST_EXTENSIONS = .la .weston
1174LA_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
1175WESTON_LOG_COMPILER = $(srcdir)/tests/weston-tests-env
1176
1177clean-local:
Pekka Paalanen15f85632014-05-12 10:08:57 +03001178 -rm -rf logs
Jon A. Cruz179c1862015-07-15 19:22:43 -07001179 -rm -rf $(DOCDIRS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001180
1181# To remove when automake 1.11 support is dropped
1182export abs_builddir
1183
1184noinst_LTLIBRARIES += \
1185 weston-test.la \
1186 $(module_tests) \
1187 libtest-runner.la \
1188 libtest-client.la
1189
1190noinst_PROGRAMS += \
1191 $(setbacklight) \
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001192 $(internal_tests) \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001193 $(shared_tests) \
1194 $(weston_tests) \
Pekka Paalanenf3a34532015-03-24 13:51:05 +02001195 $(ivi_tests) \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001196 matrix-test
1197
1198test_module_ldflags = \
1199 -module -avoid-version -rpath $(libdir) $(COMPOSITOR_LIBS)
1200
Pekka Paalanen827b5d22016-06-29 11:54:26 +02001201plugin_registry_test_la_SOURCES = tests/plugin-registry-test.c
1202plugin_registry_test_la_LDFLAGS = $(test_module_ldflags)
1203plugin_registry_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
1204
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001205surface_global_test_la_SOURCES = tests/surface-global-test.c
1206surface_global_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001207surface_global_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001208
1209surface_test_la_SOURCES = tests/surface-test.c
1210surface_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001211surface_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001212
Emil Velikov67351452016-07-22 14:52:42 +01001213weston_test_la_LIBADD = libshared.la $(COMPOSITOR_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001214weston_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001215weston_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Jon A. Cruzb09da242015-06-16 13:15:13 -07001216weston_test_la_SOURCES = \
1217 tests/weston-test.c \
1218 shared/helpers.h
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001219nodist_weston_test_la_SOURCES = \
Derek Foremanf6a65922015-02-24 09:32:14 -06001220 protocol/weston-test-protocol.c \
1221 protocol/weston-test-server-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001222
1223if ENABLE_EGL
1224weston_test_la_CFLAGS += $(EGL_TESTS_CFLAGS)
1225weston_test_la_LDFLAGS += $(EGL_TESTS_LIBS)
1226endif
1227
1228libtest_runner_la_SOURCES = \
1229 tests/weston-test-runner.c \
1230 tests/weston-test-runner.h
Derek Foreman4ff38742015-06-18 11:43:11 -05001231libtest_runner_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001232
1233config_parser_test_SOURCES = tests/config-parser-test.c
Jon A. Cruza67c5412015-07-15 19:22:42 -07001234config_parser_test_LDADD = \
1235 libshared.la \
1236 $(COMPOSITOR_LIBS) \
1237 libzunitc.la \
1238 libzunitcmain.la
1239config_parser_test_CFLAGS = \
1240 $(AM_CFLAGS) \
1241 -I$(top_srcdir)/tools/zunitc/inc
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001242
Bryce Harrington82b9f2b2016-08-03 17:40:51 -07001243string_test_SOURCES = \
1244 tests/string-test.c \
1245 shared/string-helpers.h
1246string_test_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1247string_test_LDADD = libtest-client.la
1248
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001249vertex_clip_test_SOURCES = \
1250 tests/vertex-clip-test.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001251 shared/helpers.h \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +03001252 libweston/vertex-clipping.c \
1253 libweston/vertex-clipping.h
Gustavo Zacarias34d59852016-04-21 11:18:48 -03001254vertex_clip_test_LDADD = libtest-runner.la -lm $(CLOCK_GETTIME_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001255
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001256libtest_client_la_SOURCES = \
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001257 tests/weston-test-client-helper.c \
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001258 tests/weston-test-client-helper.h
1259nodist_libtest_client_la_SOURCES = \
Derek Foremanf6a65922015-02-24 09:32:14 -06001260 protocol/weston-test-protocol.c \
1261 protocol/weston-test-client-protocol.h
Bryce Harrington892122e2015-09-24 14:31:44 -07001262libtest_client_la_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS) $(CAIRO_CFLAGS)
Emil Velikov67351452016-07-22 14:52:42 +01001263libtest_client_la_LIBADD = libshared.la libtest-runner.la $(TEST_CLIENT_LIBS) $(CAIRO_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001264
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001265
1266#
1267# Internal tests - tests functionality of the testsuite itself
1268#
1269
1270internal_screenshot_weston_SOURCES = tests/internal-screenshot-test.c
Bryce Harrington892122e2015-09-24 14:31:44 -07001271internal_screenshot_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1272internal_screenshot_weston_LDADD = libtest-client.la
Bryce Harringtonfb9089d2014-11-04 16:39:38 -08001273
1274
1275#
1276# Weston Tests
1277#
1278
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001279bad_buffer_weston_SOURCES = tests/bad-buffer-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001280bad_buffer_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001281bad_buffer_weston_LDADD = libtest-client.la
1282
1283keyboard_weston_SOURCES = tests/keyboard-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001284keyboard_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001285keyboard_weston_LDADD = libtest-client.la
1286
1287event_weston_SOURCES = tests/event-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001288event_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001289event_weston_LDADD = libtest-client.la
1290
1291button_weston_SOURCES = tests/button-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001292button_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001293button_weston_LDADD = libtest-client.la
1294
Marek Chalupa5fd81402015-03-30 09:21:29 -04001295devices_weston_SOURCES = tests/devices-test.c
1296devices_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1297devices_weston_LDADD = libtest-client.la
1298
Kristian Høgsbergbece0ee2014-02-01 21:52:17 -08001299text_weston_SOURCES = tests/text-test.c
1300nodist_text_weston_SOURCES = \
Jonas Ådahl3bcba342015-11-17 16:00:29 +08001301 protocol/text-input-unstable-v1-protocol.c \
1302 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001303text_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001304text_weston_LDADD = libtest-client.la
1305
1306subsurface_weston_SOURCES = tests/subsurface-test.c
Kristian Høgsberg49fcd002014-02-03 11:05:41 -08001307subsurface_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001308subsurface_weston_LDADD = libtest-client.la
1309
Jon A. Cruzb09da242015-06-16 13:15:13 -07001310presentation_weston_SOURCES = \
1311 tests/presentation-test.c \
1312 shared/helpers.h
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001313nodist_presentation_weston_SOURCES = \
Pekka Paalanenb00c79b2016-02-18 16:53:27 +02001314 protocol/presentation-time-protocol.c \
1315 protocol/presentation-time-client-protocol.h
Pekka Paalanende7f5c82014-09-23 22:08:48 -04001316presentation_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1317presentation_weston_LDADD = libtest-client.la
1318
Pekka Paalanen3c5f1c72014-10-01 16:34:48 +03001319roles_weston_SOURCES = tests/roles-test.c
1320roles_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1321roles_weston_LDADD = libtest-client.la
1322
Pekka Paalanen82d95a62016-04-19 17:20:42 +03001323viewporter_weston_SOURCES = \
1324 tests/viewporter-test.c \
1325 shared/helpers.h
1326nodist_viewporter_weston_SOURCES = \
1327 protocol/viewporter-protocol.c \
1328 protocol/viewporter-client-protocol.h
1329viewporter_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1330viewporter_weston_LDADD = libtest-client.la
1331
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001332if ENABLE_EGL
1333weston_tests += buffer-count.weston
1334buffer_count_weston_SOURCES = tests/buffer-count-test.c
Pekka Paalanen924cd942016-05-20 17:25:38 +03001335buffer_count_weston_CFLAGS = $(AM_CFLAGS) $(EGL_TESTS_CFLAGS) $(TEST_CLIENT_CFLAGS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001336buffer_count_weston_LDADD = libtest-client.la $(EGL_TESTS_LIBS)
1337endif
1338
1339if ENABLE_XWAYLAND_TEST
Pekka Paalanenf9a26262014-05-07 16:26:29 +03001340weston_tests += xwayland-test.weston
1341xwayland_test_weston_SOURCES = tests/xwayland-test.c
Derek Foreman4ff38742015-06-18 11:43:11 -05001342xwayland_test_weston_CFLAGS = $(AM_CFLAGS) $(XWAYLAND_TEST_CFLAGS)
Pekka Paalanenf9a26262014-05-07 16:26:29 +03001343xwayland_test_weston_LDADD = libtest-client.la $(XWAYLAND_TEST_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001344endif
1345
1346matrix_test_SOURCES = \
1347 tests/matrix-test.c \
1348 shared/matrix.c \
1349 shared/matrix.h
1350matrix_test_CPPFLAGS = -DUNIT_TEST
Gustavo Zacarias34d59852016-04-21 11:18:48 -03001351matrix_test_LDADD = -lm $(CLOCK_GETTIME_LIBS)
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001352
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001353if ENABLE_IVI_SHELL
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001354module_tests += \
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001355 ivi-layout-internal-test.la \
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001356 ivi-layout-test.la
1357
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001358ivi_layout_internal_test_la_LIBADD = $(COMPOSITOR_LIBS)
1359ivi_layout_internal_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001360ivi_layout_internal_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanen46804ca2015-03-27 11:55:21 +02001361ivi_layout_internal_test_la_SOURCES = \
1362 tests/ivi_layout-internal-test.c
1363
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001364ivi_layout_test_la_LIBADD = $(COMPOSITOR_LIBS)
1365ivi_layout_test_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001366ivi_layout_test_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001367ivi_layout_test_la_SOURCES = \
1368 tests/ivi_layout-test-plugin.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001369 tests/ivi-test.h \
1370 shared/helpers.h
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001371nodist_ivi_layout_test_la_SOURCES = \
1372 protocol/weston-test-protocol.c \
1373 protocol/weston-test-server-protocol.h
1374
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001375ivi_tests += \
1376 ivi-shell-app.weston
1377
1378ivi_shell_app_weston_SOURCES = tests/ivi-shell-app-test.c
1379nodist_ivi_shell_app_weston_SOURCES = \
1380 protocol/ivi-application-protocol.c \
1381 protocol/ivi-application-client-protocol.h
1382ivi_shell_app_weston_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1383ivi_shell_app_weston_LDADD = libtest-client.la
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001384
1385noinst_PROGRAMS += ivi-layout.ivi
1386
1387ivi_layout_ivi_SOURCES = \
1388 tests/ivi_layout-test.c \
Jon A. Cruzb09da242015-06-16 13:15:13 -07001389 tests/ivi-test.h \
1390 shared/helpers.h
Pekka Paalanenf5b74f72015-03-25 12:50:31 +02001391nodist_ivi_layout_ivi_SOURCES = \
1392 protocol/ivi-application-protocol.c \
1393 protocol/ivi-application-client-protocol.h
1394ivi_layout_ivi_CFLAGS = $(AM_CFLAGS) $(TEST_CLIENT_CFLAGS)
1395ivi_layout_ivi_LDADD = libtest-client.la
Pekka Paalanen0eb09412015-03-23 13:55:06 +02001396endif
1397
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001398if BUILD_SETBACKLIGHT
1399noinst_PROGRAMS += setbacklight
1400setbacklight_SOURCES = \
1401 tests/setbacklight.c \
Pekka Paalanenb5e3ea22016-06-03 17:12:10 +03001402 libweston/libbacklight.c \
1403 libweston/libbacklight.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001404setbacklight_CFLAGS = $(AM_CFLAGS) $(SETBACKLIGHT_CFLAGS)
1405setbacklight_LDADD = $(SETBACKLIGHT_LIBS)
1406endif
1407
Jon A. Cruz5a75a412015-07-02 23:36:44 -07001408all-local: zuctest$(EXEEXT)
1409
1410noinst_PROGRAMS += zuctest$(EXEEXT)
1411
1412zuctest_LDADD = \
1413 libzunitc.la \
1414 libzunitcmain.la
1415
1416zuctest_CFLAGS = \
1417 $(AM_CFLAGS) \
1418 -I$(top_srcdir)/tools/zunitc/inc
1419
1420zuctest_SOURCES = \
1421 tools/zunitc/test/fixtures_test.c \
1422 tools/zunitc/test/zunitc_test.c
1423
Derek Foreman1ce2ef52015-05-26 10:21:03 -05001424EXTRA_DIST += \
1425 tests/weston-tests-env \
1426 tests/internal-screenshot.ini \
1427 tests/reference/internal-screenshot-bad-00.png \
1428 tests/reference/internal-screenshot-good-00.png
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001429
1430BUILT_SOURCES += \
Derek Foremanf6a65922015-02-24 09:32:14 -06001431 protocol/weston-test-protocol.c \
1432 protocol/weston-test-server-protocol.h \
1433 protocol/weston-test-client-protocol.h \
Jonas Ådahl3bcba342015-11-17 16:00:29 +08001434 protocol/text-input-unstable-v1-protocol.c \
1435 protocol/text-input-unstable-v1-client-protocol.h
Kristian Høgsberg1e80afa2014-01-31 14:03:09 -08001436
Kristian Høgsbergcd312752014-02-01 00:38:15 -08001437EXTRA_DIST += \
Jonas Ådahl6d6fb612015-11-17 16:00:33 +08001438 protocol/weston-desktop-shell.xml \
Jonas Ådahlcf1efd22015-11-17 16:00:34 +08001439 protocol/weston-screenshooter.xml \
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001440 protocol/text-cursor-position.xml \
Derek Foremanf6a65922015-02-24 09:32:14 -06001441 protocol/weston-test.xml \
Nobuhiko Tanibata68cfabb2014-11-27 13:22:53 +09001442 protocol/ivi-application.xml \
Jonas Ådahl57e48f02015-11-17 16:00:28 +08001443 protocol/ivi-hmi-controller.xml
Kristian Høgsbergf9bc6f62014-01-27 22:26:29 -08001444
Pekka Paalanen312fe5f2015-02-09 11:23:48 +02001445#
1446# manual test modules in tests subdirectory
1447#
1448
1449noinst_LTLIBRARIES += \
1450 surface-screenshot.la
1451
Emil Velikov67351452016-07-22 14:52:42 +01001452surface_screenshot_la_LIBADD = libshared.la $(COMPOSITOR_LIBS)
Pekka Paalanen312fe5f2015-02-09 11:23:48 +02001453surface_screenshot_la_LDFLAGS = $(test_module_ldflags)
Derek Foreman4ff38742015-06-18 11:43:11 -05001454surface_screenshot_la_CFLAGS = $(AM_CFLAGS) $(COMPOSITOR_CFLAGS)
Pekka Paalanen312fe5f2015-02-09 11:23:48 +02001455surface_screenshot_la_SOURCES = tests/surface-screenshot.c
1456
1457
1458#
1459# Documentation
1460#
1461
Kristian Høgsberg68c5c102014-01-27 22:33:04 -08001462man_MANS = weston.1 weston.ini.5
1463
1464if ENABLE_DRM_COMPOSITOR
1465man_MANS += weston-drm.7
1466endif
1467
1468MAN_SUBSTS = \
1469 -e 's|__weston_native_backend__|$(WESTON_NATIVE_BACKEND)|g' \
1470 -e 's|__weston_modules_dir__|$(pkglibdir)|g' \
1471 -e 's|__weston_shell_client__|$(WESTON_SHELL_CLIENT)|g' \
1472 -e 's|__version__|$(PACKAGE_VERSION)|g'
1473
1474SUFFIXES = .1 .5 .7 .man
1475
1476%.1 %.5 %.7 : man/%.man
1477 $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@
1478
1479EXTRA_DIST += \
1480 man/weston.man \
1481 man/weston-drm.man \
1482 man/weston.ini.man
1483
1484CLEANFILES += $(man_MANS)
1485
Jon A. Cruz179c1862015-07-15 19:22:43 -07001486if ENABLE_DEVDOCS
1487DOXYGEN_INDICES = docs/developer/html/index.html docs/tools/html/index.html
1488
1489docs/developer/html/index.html: doc/doxygen/tooldev.doxygen | docs/developer
1490 cd doc/doxygen && $(DOXYGEN) tooldev.doxygen
1491
1492docs/tools/html/index.html: doc/doxygen/tools.doxygen | docs/tools
1493 cd doc/doxygen && $(DOXYGEN) tools.doxygen
1494endif
1495
1496DOCDIRS = \
1497 docs/developer \
1498 docs/tools
1499
1500$(DOCDIRS):
1501 $(MKDIR_P) $@
1502
1503.PHONY: doc $(DOXYGEN_INDICES)
1504
1505doc: $(DOXYGEN_INDICES)
1506
Jonas Ådahl496adb32015-11-17 16:00:27 +08001507.SECONDEXPANSION:
1508
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001509define protostability
Pekka Paalanen35552aa2016-02-18 16:56:13 +02001510$(if $(findstring unstable,$1),unstable,stable)
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001511endef
1512
1513define protoname
1514$(shell echo $1 | sed 's/\([a-z\-]\+\)-[a-z]\+-v[0-9]\+/\1/')
1515endef
1516
1517protocol/%-protocol.c : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001518 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
1519
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001520protocol/%-server-protocol.h : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001521 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
1522
Jonas Ådahl08ab0bc2015-11-17 16:00:31 +08001523protocol/%-client-protocol.h : $(WAYLAND_PROTOCOLS_DATADIR)/$$(call protostability,$$*)/$$(call protoname,$$*)/$$*.xml
Jonas Ådahl496adb32015-11-17 16:00:27 +08001524 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@
1525
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001526protocol/%-protocol.c : $(top_srcdir)/protocol/%.xml
1527 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) code < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001528
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001529protocol/%-server-protocol.h : $(top_srcdir)/protocol/%.xml
1530 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) server-header < $< > $@
Kristian Høgsberg08229422014-02-01 00:33:04 -08001531
Quentin Glidic088ba5e2014-02-01 21:39:12 +01001532protocol/%-client-protocol.h : $(top_srcdir)/protocol/%.xml
1533 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(wayland_scanner) client-header < $< > $@