mirror of
https://gitdl.cn/https://github.com/chakralinux/core.git
synced 2025-02-11 08:14:37 +08:00
53 lines
1.4 KiB
Bash
53 lines
1.4 KiB
Bash
# Contributions from Arch: https://www.archlinux.org/packages/extra/x86_64/p7zip/
|
|
|
|
pkgname=p7zip
|
|
pkgver=15.14.1
|
|
pkgrel=1
|
|
pkgdesc="A command-line port of the 7zip compression utility"
|
|
arch=('x86_64')
|
|
license=('GPL')
|
|
url="http://p7zip.sourceforge.net"
|
|
depends=('gcc-libs' 'bash')
|
|
makedepends=('yasm')
|
|
options=('!makeflags')
|
|
source=("http://downloads.sourceforge.net/project/${pkgname}/${pkgname}/${pkgver}/${pkgname}_${pkgver}_src_all.tar.bz2"
|
|
'CVE-2016-2334.patch'
|
|
'CVE-2016-2335.patch')
|
|
md5sums=('92cca093312b5a71a7be7dc7d1d32509'
|
|
'509d8fa040de07c79424f52faf403df3'
|
|
'11dfad35c8e160d98ef804bda80df1b5')
|
|
|
|
|
|
prepare() {
|
|
cd "$srcdir/${pkgname}_$pkgver"
|
|
cp makefile.linux_amd64_asm makefile.machine
|
|
|
|
# https://sourceforge.net/p/p7zip/discussion/383043/thread/9d0fb86b/
|
|
patch -Np1 -i ../CVE-2016-2334.patch
|
|
patch -Np1 -i ../CVE-2016-2335.patch
|
|
}
|
|
|
|
build() {
|
|
cd "${srcdir}/${pkgname}_${pkgver}"
|
|
make all3 OPTFLAGS="${CXXFLAGS}"
|
|
}
|
|
|
|
package() {
|
|
cd "${srcdir}/${pkgname}_${pkgver}"
|
|
|
|
make install \
|
|
DEST_DIR="${pkgdir}" \
|
|
DEST_HOME="/usr" \
|
|
DEST_MAN="/usr/share/man"
|
|
|
|
# Licenses
|
|
install -d "${pkgdir}"/usr/share/licenses/p7zip
|
|
ln -s -t "${pkgdir}"/usr/share/licenses/p7zip \
|
|
/usr/share/doc/p7zip/DOCS/License.txt \
|
|
/usr/share/doc/p7zip/DOCS/unRarLicense.txt
|
|
|
|
# Integration with stuff...
|
|
ln -s 7zCon.sfx "${pkgdir}"/usr/lib/p7zip/7z.sfx
|
|
chmod -R u+w "${pkgdir}/usr"
|
|
}
|