The cirros image was rebuilt against the 3.13.0-83 kernel, drivers e1000e, igbvf...
[packages/trusty/cirros-testvm.git] / cirros-testvm / src-cirros / buildroot-2015.05 / package / spice / spice.mk
1 ################################################################################
2 #
3 # spice
4 #
5 ################################################################################
6
7 SPICE_VERSION = 0.12.4
8 SPICE_SOURCE = spice-$(SPICE_VERSION).tar.bz2
9 SPICE_SITE = http://www.spice-space.org/download/releases
10 SPICE_LICENSE = LGPLv2.1+
11 SPICE_LICENSE_FILES = COPYING
12 SPICE_INSTALL_STAGING = YES
13 SPICE_DEPENDENCIES =        \
14         alsa-lib            \
15         celt051             \
16         jpeg                \
17         openssl             \
18         pixman              \
19         python-pyparsing    \
20         spice-protocol      \
21
22 # We disable everything for now, because the dependency tree can become
23 # quite deep if we try to enable some features, and I have not tested that.
24 SPICE_CONF_OPTS =                 \
25         --disable-opengl          \
26         --disable-smartcard       \
27         --disable-automated-tests \
28         --without-sasl            \
29
30 SPICE_DEPENDENCIES += host-pkgconf
31
32 ifeq ($(BR2_PACKAGE_SPICE_CLIENT),y)
33 SPICE_CONF_OPTS += --enable-client
34 SPICE_DEPENDENCIES += xlib_libXfixes xlib_libXrandr
35 else
36 SPICE_CONF_OPTS += --disable-client
37 endif
38
39 ifeq ($(BR2_PACKAGE_SPICE_GUI),y)
40 SPICE_CONF_OPTS += --enable-gui
41 SPICE_DEPENDENCIES += cegui06
42 else
43 SPICE_CONF_OPTS += --disable-gui
44 endif
45
46 ifeq ($(BR2_PACKAGE_SPICE_TUNNEL),y)
47 SPICE_CONF_OPTS += --enable-tunnel
48 SPICE_DEPENDENCIES += slirp
49 else
50 SPICE_CONF_OPTS += --disable-tunnel
51 endif
52
53 SPICE_CONF_ENV = PYTHONPATH=$(TARGET_DIR)/usr/lib/python$(PYTHON_VERSION_MAJOR)/site-packages
54 SPICE_MAKE_ENV = PYTHONPATH=$(TARGET_DIR)/usr/lib/python$(PYTHON_VERSION_MAJOR)/site-packages
55
56 # We need to tweak spice.pc because it /forgets/ (for static linking) that
57 # it should link against libz and libjpeg. libz is pkg-config-aware, while
58 # libjpeg isn't, hence the two-line tweak
59 define SPICE_POST_INSTALL_STAGING_FIX_PC
60         $(SED) 's/^\(Requires.private:.*\)$$/\1 zlib/; s/^\(Libs.private:.*\)$$/\1 -ljpeg/;'    \
61                 "$(STAGING_DIR)/usr/lib/pkgconfig/spice-server.pc"
62 endef
63 SPICE_POST_INSTALL_STAGING_HOOKS += SPICE_POST_INSTALL_STAGING_FIX_PC
64
65 # It is currently not possible to detect if stack-protection is available
66 # or not, because it requires support from both the compiler *and* the
67 # C library, but the C library (eg. uClibc) can be compiled without that
68 # support, even if gcc accepts the -fstack-protector-all option.
69 # spice's ./configure only checks for gcc's -fstack-protector-all option,
70 # so it misses the case where the C library doe not provide the requires
71 # support.
72 # A correct fix would be to fix spice's ./configure to also check the C
73 # library, but it might be much more involved.
74 # So, we simply disable it for now. After all, as uClibc's help puts it:
75 #     Note that NOEXECSTACK on a kernel with address space randomization
76 #     is generally sufficient to prevent most buffer overflow exploits
77 #     without increasing code size.
78 SPICE_CONF_OPTS += gl_cv_warn__fstack_protector_all=no
79
80 $(eval $(autotools-package))