summaryrefslogtreecommitdiffstats
path: root/rules/pulseaudio.make
blob: 394f1d0985f227eb7788d99884ebacb17df18589 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
# -*-makefile-*-
#
# Copyright (C) 2015 by Michael Olbrich <m.olbrich@pengutronix.de>
#
# For further information about the PTXdist project and license conditions
# see the README file.
#

#
# We provide this package
#
PACKAGES-$(PTXCONF_PULSEAUDIO) += pulseaudio

#
# Paths and names
#
PULSEAUDIO_VERSION	:= 13.0
PULSEAUDIO_MD5		:= e41d606f90254ed45c90520faf83d95c
PULSEAUDIO		:= pulseaudio-$(PULSEAUDIO_VERSION)
PULSEAUDIO_SUFFIX	:= tar.xz
PULSEAUDIO_URL		:= http://freedesktop.org/software/pulseaudio/releases/$(PULSEAUDIO).$(PULSEAUDIO_SUFFIX)
PULSEAUDIO_SOURCE	:= $(SRCDIR)/$(PULSEAUDIO).$(PULSEAUDIO_SUFFIX)
PULSEAUDIO_DIR		:= $(BUILDDIR)/$(PULSEAUDIO)
PULSEAUDIO_LICENSE	:= MIT AND GPL-2.0-or-later AND LGPL-2.1-or-later AND Rdisc AND ADRIAN
PULSEAUDIO_LICENSE_FILES	:= \
	file://LICENSE;md5=0e5cd938de1a7a53ea5adac38cc10c39 \
	file://GPL;md5=4325afd396febcb659c36b49533135d4 \
	file://LGPL;md5=2d5025d4aa3495befef8f17206a5b0a1 \
	file://src/pulsecore/g711.c;startline=2;endline=24;md5=663902612456e1794f328632f8b6a20a \
	file://src/modules/echo-cancel/adrian-license.txt;md5=abbab006a561fbffccedf1c3531f34ab

# ----------------------------------------------------------------------------
# Prepare
# ----------------------------------------------------------------------------

PULSEAUDIO_CONF_ENV	:= \
	$(CROSS_MESON_ENV) \
	ORCC=orcc

#
# autoconf
#
PULSEAUDIO_CONF_TOOL	:= meson
PULSEAUDIO_CONF_OPT	:= \
	$(CROSS_MESON_USR) \
	-Daccess_group=pulse-access \
	-Dadrian-aec=true \
	-Dalsa=enabled \
	-Dasyncns=disabled \
	-Datomic-arm-linux-helpers=true \
	-Datomic-arm-memory-barrier=true \
	-Davahi=disabled \
	-Dbluez5=$(call ptx/truefalse, PTXCONF_PULSEAUDIO_BLUETOOTH) \
	-Dbluez5-native-headset=false \
	-Dbluez5-ofono-headset=false \
	-Ddatabase=simple \
	-Ddbus=$(call ptx/endis, PTXCONF_PULSEAUDIO_BLUETOOTH)d \
	-Dfftw=disabled \
	-Dgcov=false \
	-Dglib=disabled \
	-Dgsettings=disabled \
	-Dgtk=disabled \
	-Dhal-compat=false \
	-Dipv6=$(call ptx/truefalse, PTXCONF_GLOBAL_IPV6) \
	-Djack=disabled \
	-Dlegacy-database-entry-format=false \
	-Dlirc=disabled \
	-Dman=false \
	-Dmodlibexecdir=/usr/lib/pulse-$(PULSEAUDIO_VERSION)/modules \
	-Dopenssl=disabled \
	-Dorc=enabled \
	-Dpadsplibdir= \
	-Dpulsedsp-location= \
	-Drunning-from-build-tree=false \
	-Dsamplerate=disabled \
	-Dsoxr=disabled \
	-Dspeex=$(call ptx/endis, PTXCONF_PULSEAUDIO_SPEEX)d \
	-Dsystem_group= \
	-Dsystem_user= \
	-Dsystemd=$(call ptx/endis, PTXCONF_PULSEAUDIO_SYSTEMD)d \
	-Dsystemduserunitdir=/usr/lib/systemd/user \
	-Dtests=false \
	-Dudev=enabled \
	-Dudevrulesdir=/lib/udev/rules.d \
	-Dwebrtc-aec=disabled \
	-Dx11=disabled \
	-Dzshcompletiondir=

PULSEAUDIO_LDFLAGS	:= -Wl,-rpath,/usr/lib/pulseaudio:/usr/lib/pulse-$(PULSEAUDIO_VERSION)/modules

# ----------------------------------------------------------------------------
# Install
# ----------------------------------------------------------------------------

$(STATEDIR)/pulseaudio.install:
	@$(call targetinfo)
	@$(call world/install, PULSEAUDIO)
	@$(call touch)

# ----------------------------------------------------------------------------
# Target-Install
# ----------------------------------------------------------------------------

$(STATEDIR)/pulseaudio.targetinstall:
	@$(call targetinfo)

	@$(call install_init, pulseaudio)
	@$(call install_fixup, pulseaudio,PRIORITY,optional)
	@$(call install_fixup, pulseaudio,SECTION,base)
	@$(call install_fixup, pulseaudio,AUTHOR,"Michael Olbrich <m.olbrich@pengutronix.de>")
	@$(call install_fixup, pulseaudio,DESCRIPTION,missing)

	@$(call install_alternative, pulseaudio, 0, 0, 0644, /etc/pulse/client.conf)
	@$(call install_alternative, pulseaudio, 0, 0, 0644, /etc/pulse/daemon.conf)
	@$(call install_alternative, pulseaudio, 0, 0, 0644, /etc/pulse/system.pa)
	@$(call install_alternative, pulseaudio, 0, 0, 0644, /etc/pulse/default.pa)

ifdef PTXCONF_PULSEAUDIO_BLUETOOTH
	@$(call install_alternative, pulseaudio, 0, 0, 0644, \
		/etc/dbus-1/system.d/pulseaudio-system.conf)
endif

ifdef PTXCONF_PULSEAUDIO_SYSTEMD
	@$(call install_alternative, pulseaudio, 0, 0, 0644, \
		/usr/lib/systemd/system/pulseaudio.service)
	@$(call install_alternative, pulseaudio, 0, 0, 0644, \
		/usr/lib/systemd/system/pulseaudio.socket)
	@$(call install_link, pulseaudio, ../pulseaudio.socket, \
		/usr/lib/systemd/system/sockets.target.wants/pulseaudio.socket)
ifdef PTXCONF_PULSEAUDIO_SYSTEMD_USER
	@$(call install_alternative, pulseaudio, 0, 0, 0644, \
		/usr/lib/systemd/user/pulseaudio.service)
	@$(call install_alternative, pulseaudio, 0, 0, 0644, \
		/usr/lib/systemd/user/pulseaudio.socket)
	@$(call install_link, pulseaudio, ../pulseaudio.socket, \
		/usr/lib/systemd/user/sockets.target.wants/pulseaudio.socket)
endif
endif

	@$(call install_copy, pulseaudio, 0, 0, 0755, -, /usr/bin/pulseaudio)
	@$(call install_copy, pulseaudio, 0, 0, 0755, -, /usr/bin/pactl)
	@$(call install_copy, pulseaudio, 0, 0, 0755, -, /usr/bin/pacmd)
	@$(call install_copy, pulseaudio, 0, 0, 0755, -, /usr/bin/pacat)
	@$(call install_link, pulseaudio, pacat, /usr/bin/pamon)
	@$(call install_link, pulseaudio, pacat, /usr/bin/paplay)
	@$(call install_link, pulseaudio, pacat, /usr/bin/parec)
	@$(call install_link, pulseaudio, pacat, /usr/bin/parecord)

	@$(call install_lib, pulseaudio, 0, 0, 0644, libpulse)
	@$(call install_lib, pulseaudio, 0, 0, 0644, libpulse-simple)
	@$(call install_lib, pulseaudio, 0, 0, 0644, pulseaudio/libpulsecore-$(PULSEAUDIO_VERSION))
	@$(call install_lib, pulseaudio, 0, 0, 0644, pulseaudio/libpulsecommon-$(PULSEAUDIO_VERSION))
	@$(call install_tree, pulseaudio, 0, 0, -, /usr/lib/pulse-$(PULSEAUDIO_VERSION)/modules)

	@$(call install_tree, pulseaudio, 0, 0, -, /usr/share/pulseaudio)

	@$(call install_finish, pulseaudio)

	@$(call touch)

# vim: syntax=make