1 # Maintainer: Eric BĂ©langer <eric@archlinux.org>
6 pkgdesc="A high-quality MPEG audio decoder"
8 url="https://www.underbit.com/products/mad/"
11 source=(https://downloads.sourceforge.net/sourceforge/mad/${pkgname}-${pkgver}.tar.gz{,.sign}
12 libmad-pkgconfig.patch
13 libmad-amd64-64bit.diff
15 libmad-length-check.patch
16 libmad-0.15.1b-gcc43.patch)
17 sha512sums=('2cad30347fb310dc605c46bacd9da117f447a5cabedd8fefdb24ab5de641429e5ec5ce8af7aefa6a75a3f545d3adfa255e3fa0a2d50971f76bc0c4fc0400cc45'
19 'ff815f5aa32aec4230351b258430ca2184c0a44f80845c92b46aedb9942b3cd85c7b3aa575f4f562a5e02f7fadf6f3d6fe06e64d2b65418dbcd10762214695b1'
20 '4fc15af4ef497220ee75e3798fbf504be2495fded7202b202169440a387573a3b3105a278d6e5c2ae10d2351a6f9b61895ccde323787314605519ffa23bb080f'
21 '511fc4496044bc676e1957c5085aded89e33248c5ee4c965c76c609904086911dcc912a943be98244b2d7e5f140f432584722cc3b53fdb27265328322a727427'
22 'dd412962246d4c9db8c07dbafcaba2f64fdc0c94cf6bcc3f4f0f88a92800f40e550cc56dc8a2324c0123d9c70a89055dc50cd714206d7886e2f6877d4cc26600'
23 '464a81b5ec9cac77fe8913de5625bb1dcbaa761f83508afe49a216e8d3fe85d10afee7bdc0922606c3fadc3894b07edc758f36c112612a5a5daadd58216d3dca')
24 validpgpkeys=('4229B6BBA00DE143B485B74D2CE2036B4BF38A33')
27 cd ${pkgname}-${pkgver}
28 patch -p1 -i "${srcdir}/libmad-pkgconfig.patch"
29 patch -p1 -i "${srcdir}/libmad-amd64-64bit.diff"
30 patch -p1 -i "${srcdir}/libmad-md_size.diff" # CVE-2017-8372 CVE-2017-8373
31 patch -p1 -i "${srcdir}/libmad-length-check.patch" # CVE-2017-8374
32 patch -p1 -i "${srcdir}/libmad-0.15.1b-gcc43.patch"
36 cd ${pkgname}-${pkgver}
39 ./configure --prefix=/usr
44 cd ${pkgname}-${pkgver}
45 make DESTDIR="${pkgdir}" install