aboutsummaryrefslogtreecommitdiffstats
path: root/community/sox/APKBUILD
blob: 1c6c41a6f8017a78a64aa4b50ce9f75df9ea03a7 (plain) (blame)
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
# Contributor: Ɓukasz Jendrysik <scadu@yandex.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=sox
pkgver=14.4.2
pkgrel=3
pkgdesc="The Swiss Army knife of sound processing tools"
url="http://sox.sourceforge.net/"
arch="all"
options="!check"  # No test suite.
license="GPL LGPL"
makedepends="ffmpeg-dev libao-dev libvorbis-dev libogg-dev lame-dev
	libmad-dev bash alsa-lib-dev libsndfile-dev libsamplerate-dev
	file-dev libid3tag-dev flac-dev gsm-dev opusfile-dev libpng-dev
	autoconf automake libtool
	"
depends=
subpackages="$pkgname-dev $pkgname-doc"
source="https://downloads.sourceforge.net/sourceforge/$pkgname/$pkgname-$pkgver.tar.gz
	sox-uclibc.patch
	sox-dynamic.patch
	CVE-2019-8357.patch
	CVE-2019-8356.patch
	CVE-2019-8355.patch
	"

# secfixes:
#   14.4.2-r3:
#     - CVE-2019-8357
#     - CVE-2019-8356
#     - CVE-2019-8355

prepare() {
	cd "$builddir"
	default_prepare
	autoreconf -vif
}

build() {
	cd "$builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--with-dyn-default \
		--with-distro="${DISTRO_NAME:-Alpine Linux}"
	make
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" install
	ln -sf play "$pkgdir"/usr/bin/rec
	ln -sf ../man1/sox.1.gz "$pkgdir"/usr/share/man/man7/soxeffect.7
	rm "$pkgdir"/usr/lib/sox/*.a
}
sha512sums="b5c6203f4f5577503a034fe5b3d6a033ee97fe4d171c533933e2b036118a43a14f97c9668433229708609ccf9ee16abdeca3fc7501aa0aafe06baacbba537eca  sox-14.4.2.tar.gz
08c55a0de96733e10544d450f39c2205b4057b9fc024503ec97b1906a075752ee8a4b0a1b4c5bbad2eebec17bcf8d069b22d243a63d28b77c23d545efcca6aec  sox-uclibc.patch
3950834db26faa0523006c6fd8e0769d080518f127d345c8ec9bf53e9db8a6bd67cd724f0f86492aaf9ce6ede2dfbde167049768f35c14ef3c2b96e7e00302b6  sox-dynamic.patch
b5daae78fc4eb855049c298da98ff6bb16933fb9b308801c02853fe58fb9086304343007740e2783a64fddc09c3ba576645e10cf4d5fe24f99ae98c4c1d943d7  CVE-2019-8357.patch
38f0572603181422ffa9d25ee17dea924b9b523803d0a835039c64aab1408d8e7cc36f9d2285d6d9a310901c3449b90ccc34da1273e33842e9f0634a5bb2757f  CVE-2019-8356.patch
7a5499a5dea5635eb67703f95144e57b68c4c0c50aea04f2ecbfffd4cdd31cc183d97410da4f79cdbb9af4f357792a04fc7496f031cd2e30eb9dacf258050ff3  CVE-2019-8355.patch"