summaryrefslogtreecommitdiff
path: root/main/lame/APKBUILD
blob: f69cf15768805123b7f841edfcde0156d3f8507c (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
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=lame
pkgver=3.100
pkgrel=2
pkgdesc="An MP3 encoder and graphical frame analyzer"
url="https://lame.sourceforge.net/"
arch="all"
license="LGPL-2.0-or-later"
subpackages="$pkgname-dev $pkgname-doc"
makedepends="nasm ncurses-dev autoconf automake libtool"
source="https://downloads.sourceforge.net/project/lame/lame/$pkgver/lame-$pkgver.tar.gz"

# secfixes:
#   3.99.5-r6:
#     - CVE-2015-9099
#     - CVE-2015-9100
#     - CVE-2017-9410
#     - CVE-2017-9411
#     - CVE-2017-9412
#     - CVE-2017-11720

prepare() {
	default_prepare

	# fix for parallel builds
	mkdir -p libmp3lame/i386/.libs

	# fix for pic build with new nasm
	sed -i -e '/define sp/s/+/ + /g' libmp3lame/i386/nasm.h

	aclocal && automake --force --add-missing
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--enable-nasm \
		--disable-mp3x \
		--enable-shared \
		--with-pic
	make
}

check() {
	make test
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="0844b9eadb4aacf8000444621451277de365041cc1d97b7f7a589da0b7a23899310afd4e4d81114b9912aa97832621d20588034715573d417b2923948c08634b  lame-3.100.tar.gz"