PKGBUILDs/extra/p7zip/PKGBUILD

77 lines
2.4 KiB
Bash
Raw Normal View History

2015-04-15 22:29:59 +00:00
# Maintainer: Evangelos Foutras <evangelos@foutrelis.com>
# Contributor: Gaetan Bisson <bisson@archlinux.org>
2012-03-03 06:25:26 +00:00
# Contributor: Thayer Williams <thayer@archlinux.org>
# Contributor: Hugo Doria <hugo@archlinux.org>
# Contributor: TuxSpirit<tuxspirit@archlinux.fr> 2007/11/17 21:22:36 UTC
# Contributor: Daniel J Griffiths <ghost1227@archlinux.us>
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
# - use makefile.linux_any_cpu
pkgname=p7zip
2016-07-16 15:21:34 +00:00
pkgver=16.02
2020-05-19 01:53:56 +00:00
pkgrel=6
2015-04-15 22:29:59 +00:00
pkgdesc="Command-line file archiver with high compression ratio"
2018-02-05 19:18:10 +00:00
arch=('x86_64')
2015-04-15 22:29:59 +00:00
url="http://p7zip.sourceforge.net/"
license=('LGPL' 'custom:unRAR')
depends=('gcc-libs' 'sh')
makedepends_i686=('nasm')
makedepends_x86_64=('yasm')
install=$pkgname.install
2017-02-05 20:24:48 +00:00
source=(https://downloads.sourceforge.net/project/$pkgname/$pkgname/$pkgver/${pkgname}_${pkgver}_src_all.tar.bz2
2020-05-19 01:53:56 +00:00
gcc10-conversion.patch
2018-02-05 19:18:10 +00:00
CVE-2016-9296.patch
CVE-2017-17969.patch
2018-06-09 21:38:19 +00:00
CVE-2018-5996.patch
CVE-2018-10115.patch)
2017-02-05 20:24:48 +00:00
sha256sums=('5eb20ac0e2944f6cb9c2d51dd6c4518941c185347d4089ea89087ffdd6e2341f'
2020-05-19 01:53:56 +00:00
'f90013d66d3c9865cb56fed2fb0432057a07283d5361e2ae9e98c3d3657f42a1'
2018-02-05 19:18:10 +00:00
'f9bcbf21d4aa8938861a6cba992df13dec19538286e9ed747ccec6d9a4e8f983'
2018-06-09 21:38:19 +00:00
'c6af5ba588b8932a5e99f3741fcf1011b7c94b533de903176c7d1d4c02a9ebef'
'9c92b9060fb0ecc3e754e6440d7773d04bc324d0f998ebcebc263264e5a520df'
'c397eb6ad60bfab8d388ea9b39c0c13ae818f86746210c6435e35b35c786607f')
2012-03-03 06:25:26 +00:00
2014-01-12 01:04:08 +00:00
prepare() {
2015-04-15 22:29:59 +00:00
cd "$srcdir/${pkgname}_$pkgver"
2015-02-11 16:36:21 +00:00
2020-05-19 01:53:56 +00:00
# https://sourceforge.net/p/p7zip/bugs/226/ (patch from Fedora)
patch -Np1 -i ../gcc10-conversion.patch
2017-02-05 20:24:48 +00:00
# https://sourceforge.net/p/p7zip/bugs/185/
patch -Np1 -i ../CVE-2016-9296.patch
2018-02-05 19:18:10 +00:00
# https://sourceforge.net/p/p7zip/bugs/204/
patch -Np1 -i ../CVE-2017-17969.patch
2018-06-09 21:38:19 +00:00
# Security patches from Debian
2018-02-05 19:18:10 +00:00
patch -Np1 -i ../CVE-2018-5996.patch
2018-06-09 21:38:19 +00:00
patch -Np1 -i ../CVE-2018-10115.patch
2018-02-05 19:18:10 +00:00
2015-04-15 22:29:59 +00:00
cp makefile.linux_any_cpu_gcc_4.X makefile.machine
2013-10-01 01:03:17 +00:00
}
2012-03-03 06:25:26 +00:00
2013-10-01 01:03:17 +00:00
build() {
2015-04-15 22:29:59 +00:00
cd "$srcdir/${pkgname}_$pkgver"
make all3 OPTFLAGS="$CFLAGS"
2012-03-03 06:25:26 +00:00
}
package() {
2015-04-15 22:29:59 +00:00
cd "$srcdir/${pkgname}_$pkgver"
2012-03-03 06:25:26 +00:00
2015-04-15 22:29:59 +00:00
make install \
DEST_DIR="$pkgdir" \
DEST_HOME=/usr \
DEST_MAN=/usr/share/man
2012-03-03 06:25:26 +00:00
2016-08-07 16:55:36 +00:00
# Remove documentation for the GUI file manager
rm -r "$pkgdir/usr/share/doc/p7zip/DOC/MANUAL/fm"
2015-04-15 22:29:59 +00:00
install -d "${pkgdir}"/usr/share/licenses/p7zip
ln -s -t "$pkgdir/usr/share/licenses/p7zip/" \
/usr/share/doc/p7zip/DOC/License.txt \
/usr/share/doc/p7zip/DOC/unRarLicense.txt
2012-03-03 06:25:26 +00:00
}
2015-04-15 22:29:59 +00:00
# vim:set ts=2 sw=2 et: