f913a920f3a6486c1791de06e69cf73c19ff461f
[profile/ivi/weston-ivi-shell.git] / compositor / Makefile.am
1 bin_PROGRAMS = wayland-compositor
2
3 AM_CPPFLAGS =                                   \
4         -DDATADIR='"$(datadir)"'                \
5         -DMODULEDIR='"$(moduledir)"'            \
6         -DBINDIR='"$(bindir)"'                  \
7         $(COMPOSITOR_CFLAGS)
8
9 wayland_compositor_LDFLAGS = -export-dynamic
10 wayland_compositor_CFLAGS = $(GCC_CFLAGS)
11 wayland_compositor_LDADD = \
12         $(COMPOSITOR_LIBS) $(DLOPEN_LIBS) $(XSERVER_LAUNCHER_LIBS)
13
14 wayland_compositor_SOURCES =                    \
15         compositor.c                            \
16         compositor.h                            \
17         image-loader.c                          \
18         screenshooter.c                         \
19         screenshooter-protocol.c                \
20         screenshooter-server-protocol.h         \
21         $(xserver_launcher_sources)
22
23 if ENABLE_XSERVER_LAUNCHER
24 xserver_launcher_sources =                      \
25         xserver-launcher.c                      \
26         xserver-protocol.c                      \
27         xserver-server-protocol.h
28 endif
29
30 moduledir = @libdir@/wayland
31 module_LTLIBRARIES =                            \
32         $(desktop_shell)                        \
33         $(meego_tablet_shell)                   \
34         $(x11_backend)                          \
35         $(drm_backend)                          \
36         $(wayland_backend)                      \
37         $(openwfd_backend)
38
39 if ENABLE_X11_COMPOSITOR
40 x11_backend = x11-backend.la
41 x11_backend_la_LDFLAGS = -module -avoid-version
42 x11_backend_la_LIBADD = $(COMPOSITOR_LIBS) $(X11_COMPOSITOR_LIBS)
43 x11_backend_la_CFLAGS = $(X11_COMPOSITOR_CFLAGS) $(GCC_CFLAGS)
44 x11_backend_la_SOURCES = compositor-x11.c
45 endif
46
47 if ENABLE_DRM_COMPOSITOR
48 drm_backend = drm-backend.la
49 drm_backend_la_LDFLAGS = -module -avoid-version
50 drm_backend_la_LIBADD = $(COMPOSITOR_LIBS) $(DRM_COMPOSITOR_LIBS)
51 drm_backend_la_CFLAGS = $(DRM_COMPOSITOR_CFLAGS) $(GCC_CFLAGS)
52 drm_backend_la_SOURCES = compositor-drm.c tty.c evdev.c
53 endif
54
55 if ENABLE_WAYLAND_COMPOSITOR
56 wayland_backend = wayland-backend.la
57 wayland_backend_la_LDFLAGS = -module -avoid-version
58 wayland_backend_la_LIBADD = $(COMPOSITOR_LIBS) $(WAYLAND_COMPOSITOR_LIBS)
59 wayland_backend_la_CFLAGS = $(WAYLAND_COMPOSITOR_CFLAGS) $(GCC_CFLAGS)
60 wayland_backend_la_SOURCES = compositor-wayland.c
61 endif
62
63 if ENABLE_OPENWFD_COMPOSITOR
64 openwfd_backend = openwfd-backend.la
65 openwfd_backend_la_LDFLAGS = -module -avoid-version
66 openwfd_backend_la_LIBADD = $(COMPOSITOR_LIBS) $(OPENWFD_COMPOSITOR_LIBS)
67 openwfd_backend_la_CFLAGS = $(OPENWFD_COMPOSITOR_CFLAGS) $(GCC_CFLAGS)
68 openwfd_backend_la_SOURCES = compositor-openwfd.c tty.c evdev.c
69 endif
70
71 if ENABLE_DESKTOP_SHELL
72 desktop_shell = desktop-shell.la
73 desktop_shell_la_LDFLAGS = -module -avoid-version
74 desktop_shell_la_LIBADD = $(COMPOSITOR_LIBS)
75 desktop_shell_la_CFLAGS = $(GCC_CFLAGS)
76 desktop_shell_la_SOURCES =                      \
77         shell.c                                 \
78         switcher.c
79 endif
80
81 if ENABLE_MEEGO_TABLET_SHELL
82 meego_tablet_shell = meego-tablet-shell.la
83 meego_tablet_shell_la_LDFLAGS = -module -avoid-version
84 meego_tablet_shell_la_LIBADD = $(COMPOSITOR_LIBS)
85 meego_tablet_shell_la_CFLAGS = $(GCC_CFLAGS)
86 meego_tablet_shell_la_SOURCES =                 \
87         meego-tablet-shell.c                    \
88         meego-tablet-shell.h                    \
89         meego-tablet-protocol.c                 \
90         meego-tablet-server-protocol.h
91 endif
92
93 BUILT_SOURCES =                                 \
94         screenshooter-server-protocol.h         \
95         screenshooter-protocol.c                \
96         meego-tablet-protocol.c                 \
97         meego-tablet-server-protocol.h          \
98         xserver-protocol.c                      \
99         xserver-server-protocol.h
100
101 CLEANFILES = $(BUILT_SOURCES)
102
103 @wayland_scanner_rules@