rabbitmq-server: security bump to version 3.6.6
[buildroot-gz.git] / package / pulseaudio / pulseaudio.mk
blob74a028be45b087cae1620caae9f472b013bab9f3
1 ################################################################################
3 # pulseaudio
5 ################################################################################
7 PULSEAUDIO_VERSION = 9.0
8 PULSEAUDIO_SOURCE = pulseaudio-$(PULSEAUDIO_VERSION).tar.xz
9 PULSEAUDIO_SITE = http://freedesktop.org/software/pulseaudio/releases
10 PULSEAUDIO_INSTALL_STAGING = YES
11 PULSEAUDIO_LICENSE = LGPLv2.1+ (specific license for modules, see LICENSE file)
12 PULSEAUDIO_LICENSE_FILES = LICENSE GPL LGPL
13 PULSEAUDIO_CONF_OPTS = \
14 --disable-default-build-tests \
15 --disable-legacy-database-entry-format \
16 --disable-manpages
18 # Make sure we don't detect libatomic_ops. Indeed, since pulseaudio
19 # requires json-c, which needs 4 bytes __sync builtins, there should
20 # be no need for pulseaudio to rely on libatomic_ops.
21 PULSEAUDIO_CONF_ENV += \
22 ac_cv_header_atomic_ops_h=no
24 # 0002-webrtc-C-11-is-only-required-for-WebRTC-support.patch
25 PULSEAUDIO_AUTORECONF = YES
27 PULSEAUDIO_DEPENDENCIES = \
28 host-pkgconf libtool json-c libsndfile speex host-intltool \
29 $(if $(BR2_PACKAGE_LIBSAMPLERATE),libsamplerate) \
30 $(if $(BR2_PACKAGE_ALSA_LIB),alsa-lib) \
31 $(if $(BR2_PACKAGE_LIBGLIB2),libglib2) \
32 $(if $(BR2_PACKAGE_AVAHI_DAEMON),avahi) \
33 $(if $(BR2_PACKAGE_DBUS),dbus) \
34 $(if $(BR2_PACKAGE_BLUEZ_UTILS),bluez_utils) \
35 $(if $(BR2_PACKAGE_OPENSSL),openssl) \
36 $(if $(BR2_PACKAGE_FFTW),fftw) \
37 $(if $(BR2_PACKAGE_SYSTEMD),systemd)
39 ifeq ($(BR2_PACKAGE_GDBM),y)
40 PULSEAUDIO_CONF_OPTS += --with-database=gdbm
41 PULSEAUDIO_DEPENDENCIES += gdbm
42 else
43 PULSEAUDIO_CONF_OPTS += --with-database=simple
44 endif
46 ifeq ($(BR2_PACKAGE_JACK2),y)
47 PULSEAUDIO_CONF_OPTS += --enable-jack
48 PULSEAUDIO_DEPENDENCIES += jack2
49 else
50 PULSEAUDIO_CONF_OPTS += --disable-jack
51 endif
53 ifeq ($(BR2_PACKAGE_ORC),y)
54 PULSEAUDIO_DEPENDENCIES += orc
55 PULSEAUDIO_CONF_ENV += ORCC=$(HOST_DIR)/usr/bin/orcc
56 PULSEAUDIO_CONF_OPTS += --enable-orc
57 else
58 PULSEAUDIO_CONF_OPTS += --disable-orc
59 endif
61 ifeq ($(BR2_PACKAGE_LIBCAP),y)
62 PULSEAUDIO_DEPENDENCIES += libcap
63 PULSEAUDIO_CONF_OPTS += --with-caps
64 else
65 PULSEAUDIO_CONF_OPTS += --without-caps
66 endif
68 # gtk3 support needs X11 backend
69 ifeq ($(BR2_PACKAGE_LIBGTK3_X11),y)
70 PULSEAUDIO_DEPENDENCIES += libgtk3
71 PULSEAUDIO_CONF_OPTS += --enable-gtk3
72 else
73 PULSEAUDIO_CONF_OPTS += --disable-gtk3
74 endif
76 ifeq ($(BR2_PACKAGE_LIBSOXR),y)
77 PULSEAUDIO_CONF_OPTS += --with-soxr
78 PULSEAUDIO_DEPENDENCIES += libsoxr
79 else
80 PULSEAUDIO_CONF_OPTS += --without-soxr
81 endif
83 ifeq ($(BR2_PACKAGE_HAS_UDEV),y)
84 PULSEAUDIO_CONF_OPTS += --enable-udev
85 PULSEAUDIO_DEPENDENCIES += udev
86 else
87 PULSEAUDIO_CONF_OPTS += --disable-udev
88 endif
90 ifeq ($(BR2_PACKAGE_WEBRTC_AUDIO_PROCESSING),y)
91 PULSEAUDIO_CONF_OPTS += --enable-webrtc-aec
92 PULSEAUDIO_DEPENDENCIES += webrtc-audio-processing
93 else
94 PULSEAUDIO_CONF_OPTS += --disable-webrtc-aec
95 endif
97 # neon intrinsics not available with float-abi=soft
98 ifeq ($(BR2_ARM_SOFT_FLOAT),)
99 ifeq ($(BR2_ARM_CPU_HAS_NEON),y)
100 PULSEAUDIO_USE_NEON = y
101 endif
102 endif
104 ifeq ($(PULSEAUDIO_USE_NEON),y)
105 PULSEAUDIO_CONF_OPTS += --enable-neon-opt=yes
106 else
107 PULSEAUDIO_CONF_OPTS += --enable-neon-opt=no
108 endif
110 # pulseaudio alsa backend needs pcm/mixer apis
111 ifneq ($(BR2_PACKAGE_ALSA_LIB_PCM)$(BR2_PACKAGE_ALSA_LIB_MIXER),yy)
112 PULSEAUDIO_CONF_OPTS += --disable-alsa
113 endif
115 ifeq ($(BR2_PACKAGE_LIBXCB)$(BR2_PACKAGE_XLIB_LIBSM)$(BR2_PACKAGE_XLIB_LIBXTST),yyy)
116 PULSEAUDIO_DEPENDENCIES += libxcb xlib_libSM xlib_libXtst
118 # .desktop file generation needs nls support, so fake it for !locale builds
119 # https://bugs.freedesktop.org/show_bug.cgi?id=54658
120 ifneq ($(BR2_ENABLE_LOCALE),y)
121 define PULSEAUDIO_FIXUP_DESKTOP_FILES
122 cp $(@D)/src/daemon/pulseaudio.desktop.in \
123 $(@D)/src/daemon/pulseaudio.desktop
124 cp $(@D)/src/daemon/pulseaudio-kde.desktop.in \
125 $(@D)/src/daemon/pulseaudio-kde.desktop
126 endef
127 PULSEAUDIO_POST_PATCH_HOOKS += PULSEAUDIO_FIXUP_DESKTOP_FILES
128 endif
130 else
131 PULSEAUDIO_CONF_OPTS += --disable-x11
132 endif
134 define PULSEAUDIO_REMOVE_VALA
135 rm -rf $(TARGET_DIR)/usr/share/vala
136 endef
138 PULSEAUDIO_POST_INSTALL_TARGET_HOOKS += PULSEAUDIO_REMOVE_VALA
140 ifeq ($(BR2_PACKAGE_PULSEAUDIO_DAEMON),y)
141 define PULSEAUDIO_USERS
142 pulse -1 pulse -1 * /var/run/pulse - audio,pulse-access
143 endef
145 define PULSEAUDIO_INSTALL_INIT_SYSV
146 $(INSTALL) -D -m 755 package/pulseaudio/S50pulseaudio \
147 $(TARGET_DIR)/etc/init.d/S50pulseaudio
148 endef
150 define PULSEAUDIO_INSTALL_INIT_SYSTEMD
151 $(INSTALL) -D -m 644 package/pulseaudio/pulseaudio.service \
152 $(TARGET_DIR)/usr/lib/systemd/system/pulseaudio.service
153 mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
154 ln -sf ../../../../usr/lib/systemd/system/pulseaudio.service \
155 $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/pulseaudio.service
156 endef
158 endif
160 $(eval $(autotools-package))