xref: /OK3568_Linux_fs/buildroot/package/pipewire/pipewire.mk (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun################################################################################
2*4882a593Smuzhiyun#
3*4882a593Smuzhiyun# pipewire
4*4882a593Smuzhiyun#
5*4882a593Smuzhiyun################################################################################
6*4882a593Smuzhiyun
7*4882a593SmuzhiyunPIPEWIRE_VERSION = 0.3.52
8*4882a593SmuzhiyunPIPEWIRE_SOURCE = pipewire-$(PIPEWIRE_VERSION).tar.bz2
9*4882a593SmuzhiyunPIPEWIRE_SITE = https://gitlab.freedesktop.org/pipewire/pipewire/-/archive/$(PIPEWIRE_VERSION)
10*4882a593SmuzhiyunPIPEWIRE_LICENSE = MIT, LGPL-2.1+ (libspa-alsa), GPL-2.0 (libjackserver)
11*4882a593SmuzhiyunPIPEWIRE_LICENSE_FILES = COPYING LICENSE
12*4882a593SmuzhiyunPIPEWIRE_INSTALL_STAGING = YES
13*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES = host-pkgconf $(TARGET_NLS_DEPENDENCIES)
14*4882a593SmuzhiyunPIPEWIRE_LDFLAGS = $(TARGET_NLS_LIBS)
15*4882a593Smuzhiyun
16*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += \
17*4882a593Smuzhiyun	-Ddocs=disabled \
18*4882a593Smuzhiyun	-Dman=disabled \
19*4882a593Smuzhiyun	-Dtests=disabled \
20*4882a593Smuzhiyun	-Dspa-plugins=enabled \
21*4882a593Smuzhiyun	-Daudiomixer=enabled \
22*4882a593Smuzhiyun	-Daudioconvert=enabled \
23*4882a593Smuzhiyun	-Dbluez5-codec-lc3plus=disabled \
24*4882a593Smuzhiyun	-Dcontrol=enabled \
25*4882a593Smuzhiyun	-Daudiotestsrc=enabled \
26*4882a593Smuzhiyun	-Dsupport=enabled \
27*4882a593Smuzhiyun	-Devl=disabled \
28*4882a593Smuzhiyun	-Dtest=disabled \
29*4882a593Smuzhiyun	-Dvideoconvert=enabled \
30*4882a593Smuzhiyun	-Dvideotestsrc=enabled \
31*4882a593Smuzhiyun	-Dvolume=enabled \
32*4882a593Smuzhiyun	-Dsession-managers=[] \
33*4882a593Smuzhiyun	-Dlegacy-rtkit=false \
34*4882a593Smuzhiyun	-Dlibcanberra=disabled
35*4882a593Smuzhiyun
36*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_DBUS),y)
37*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Ddbus=enabled
38*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += dbus
39*4882a593Smuzhiyunelse
40*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Ddbus=disabled
41*4882a593Smuzhiyunendif
42*4882a593Smuzhiyun
43*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_HAS_UDEV),y)
44*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dudev=enabled
45*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += udev
46*4882a593Smuzhiyunelse
47*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dudev=disabled
48*4882a593Smuzhiyunendif
49*4882a593Smuzhiyun
50*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_PIPEWIRE_EXAMPLES),y)
51*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dexamples=enabled
52*4882a593Smuzhiyunelse
53*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dexamples=disabled
54*4882a593Smuzhiyunendif
55*4882a593Smuzhiyun
56*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_PIPEWIRE_GSTREAMER),y)
57*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dgstreamer=enabled
58*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += libglib2 gstreamer1 gst1-plugins-base
59*4882a593Smuzhiyunelse
60*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dgstreamer=disabled
61*4882a593Smuzhiyunendif
62*4882a593Smuzhiyun
63*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_SYSTEMD),y)
64*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += \
65*4882a593Smuzhiyun	-Dsystemd=enabled \
66*4882a593Smuzhiyun	-Dsystemd-system-service=enabled \
67*4882a593Smuzhiyun	-Dsystemd-user-service=enabled
68*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += systemd
69*4882a593Smuzhiyunelse
70*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += \
71*4882a593Smuzhiyun	-Dsystemd=disabled \
72*4882a593Smuzhiyun	-Dsystemd-system-service=disabled \
73*4882a593Smuzhiyun	-Dsystemd-user-service=disabled
74*4882a593Smuzhiyunendif
75*4882a593Smuzhiyun
76*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_ALSA_LIB),y)
77*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dpipewire-alsa=enabled
78*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += alsa-lib
79*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_ALSA_LIB_SEQ)$(BR2_PACKAGE_ALSA_LIB_UCM)$(BR2_PACKAGE_HAS_UDEV),yyy)
80*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dalsa=enabled
81*4882a593Smuzhiyunelse
82*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dalsa=disabled
83*4882a593Smuzhiyunendif
84*4882a593Smuzhiyunelse
85*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dalsa=disabled -Dpipewire-alsa=disabled
86*4882a593Smuzhiyunendif
87*4882a593Smuzhiyun
88*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_AVAHI_LIBAVAHI_CLIENT),y)
89*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Davahi=enabled
90*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += avahi
91*4882a593Smuzhiyunelse
92*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Davahi=disabled
93*4882a593Smuzhiyunendif
94*4882a593Smuzhiyun
95*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_JACK2),y)
96*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dpipewire-jack=enabled -Djack=enabled
97*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += jack2
98*4882a593Smuzhiyunelse
99*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dpipewire-jack=disabled -Djack=disabled
100*4882a593Smuzhiyunendif
101*4882a593Smuzhiyun
102*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_BLUEZ5_UTILS)$(BR2_PACKAGE_SBC),yy)
103*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dbluez5=enabled
104*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += bluez5_utils sbc
105*4882a593Smuzhiyunelse
106*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dbluez5=disabled
107*4882a593Smuzhiyunendif
108*4882a593Smuzhiyun
109*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_FFMPEG),y)
110*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dffmpeg=enabled
111*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += ffmpeg
112*4882a593Smuzhiyunelse
113*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dffmpeg=disabled
114*4882a593Smuzhiyunendif
115*4882a593Smuzhiyun
116*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_NCURSES_WCHAR),y)
117*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += ncurses
118*4882a593Smuzhiyunendif
119*4882a593Smuzhiyun
120*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_PIPEWIRE_V4L2),y)
121*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dpipewire-v4l2=enabled -Dv4l2=enabled
122*4882a593Smuzhiyunelse
123*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dpipewire-v4l2=disabled -Dv4l2=disabled
124*4882a593Smuzhiyunendif
125*4882a593Smuzhiyun
126*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_LIBCAMERA)$(BR2_PACKAGE_LIBDRM)$(BR2_PACKAGE_HAS_UDEV),yyy)
127*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dlibcamera=enabled
128*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += libcamera libdrm
129*4882a593Smuzhiyunelse
130*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dlibcamera=disabled
131*4882a593Smuzhiyunendif
132*4882a593Smuzhiyun
133*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_LILV),y)
134*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dlv2=enabled
135*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += lilv
136*4882a593Smuzhiyunelse
137*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dlv2=disabled
138*4882a593Smuzhiyunendif
139*4882a593Smuzhiyun
140*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_XLIB_LIBX11),y)
141*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dx11=enabled
142*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += xlib_libX11
143*4882a593Smuzhiyunelse
144*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dx11=disabled
145*4882a593Smuzhiyunendif
146*4882a593Smuzhiyun
147*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_XLIB_LIBXFIXES),y)
148*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dx11-xfixes=enabled
149*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += xlib_libXfixes
150*4882a593Smuzhiyunelse
151*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dx11-xfixes=disabled
152*4882a593Smuzhiyunendif
153*4882a593Smuzhiyun
154*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_LIBUSB),y)
155*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dlibusb=enabled
156*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += libusb
157*4882a593Smuzhiyunelse
158*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dlibusb=disabled
159*4882a593Smuzhiyunendif
160*4882a593Smuzhiyun
161*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_MESA3D_VULKAN_DRIVER),y)
162*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dvulkan=enabled
163*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += mesa3d
164*4882a593Smuzhiyunelse
165*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dvulkan=disabled
166*4882a593Smuzhiyunendif
167*4882a593Smuzhiyun
168*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_LIBSNDFILE),y)
169*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dpw-cat=enabled -Dsndfile=enabled
170*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += libsndfile
171*4882a593Smuzhiyunelse
172*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dpw-cat=disabled -Dsndfile=disabled
173*4882a593Smuzhiyunendif
174*4882a593Smuzhiyun
175*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_PULSEAUDIO),y)
176*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dlibpulse=enabled
177*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += pulseaudio
178*4882a593Smuzhiyunelse
179*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dlibpulse=disabled
180*4882a593Smuzhiyunendif
181*4882a593Smuzhiyun
182*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_READLINE),y)
183*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += readline
184*4882a593Smuzhiyunendif
185*4882a593Smuzhiyun
186*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_SDL2),y)
187*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += sdl2
188*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dsdl2=enabled
189*4882a593Smuzhiyunelse
190*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Dsdl2=disabled
191*4882a593Smuzhiyunendif
192*4882a593Smuzhiyun
193*4882a593Smuzhiyunifeq ($(WEBRTC_AUDIO_PROCESSING),y)
194*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Decho-cancel-webrtc=enabled
195*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += webrtc-audio-processing
196*4882a593Smuzhiyunelse
197*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Decho-cancel-webrtc=disabled
198*4882a593Smuzhiyunendif
199*4882a593Smuzhiyun
200*4882a593Smuzhiyunifeq ($(BR2_PACKAGE_OPENSSL),y)
201*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Draop=enabled
202*4882a593SmuzhiyunPIPEWIRE_DEPENDENCIES += openssl
203*4882a593Smuzhiyunelse
204*4882a593SmuzhiyunPIPEWIRE_CONF_OPTS += -Draop=disabled
205*4882a593Smuzhiyunendif
206*4882a593Smuzhiyun
207*4882a593Smuzhiyundefine PIPEWIRE_USERS
208*4882a593Smuzhiyun	pipewire -1 pipewire -1 * - - audio,video PipeWire System Daemon
209*4882a593Smuzhiyunendef
210*4882a593Smuzhiyun
211*4882a593Smuzhiyun$(eval $(meson-package))
212