# Contributor: Sergey Lukin # Maintainer: A. Wilcox pkgname=libarchive pkgver=3.7.2 pkgrel=0 pkgdesc="Multi-format archive and compression library" url="https://www.libarchive.org/" arch="all" license="BSD-2-Clause AND BSD-3-Clause AND Public-Domain" depends="" makedepends="zlib-dev bzip2-dev xz-dev lz4-dev acl-dev openssl-dev expat-dev attr-dev zstd-dev" subpackages="$pkgname-dev $pkgname-doc $pkgname-tools" source="https://github.com/libarchive/libarchive/releases/download/v$pkgver/$pkgname-$pkgver.tar.gz disable-locale-tests.patch disable-unaligned-access-arm32-xxhash.patch fix-test-32-bit-zstd.patch " # secfixes: # 3.6.2-r0: # - CVE-2022-36227 # 3.6.1-r0: # - CVE-2022-26280 # 3.4.2-r0: # - CVE-2020-9308 # 3.3.2-r1: # - CVE-2017-14166 build () { ./configure \ --build=$CBUILD \ --host=$CHOST \ --prefix=/usr \ --with-expat \ --without-xml2 \ --with-bz2lib \ --with-zlib \ --with-lzma \ --with-lz4 \ --enable-acl \ --enable-xattr \ ac_cv_header_linux_fiemap_h=no make } check() { make check } package() { make DESTDIR="$pkgdir" install } tools() { pkgdesc="libarchive tools - bsdtar and bsdcpio" mkdir -p "$subpkgdir"/usr/ mv "$pkgdir"/usr/bin "$subpkgdir"/usr/ ln -s bsdtar "$subpkgdir"/usr/bin/tar ln -s bsdcpio "$subpkgdir"/usr/bin/cpio } sha512sums="1af253203df3014d1fbf3e99ebdc7aa2a3f036c7c2606d0f0550c49973b0fff99ee7262f4a6e20090c0806c40e964731334360daa3b718bde40108183eacc8a1 libarchive-3.7.2.tar.gz 27cf2aaa3e70e3a2a9944fac0c96c411e669c7e1a48daad1423bff68eef0f49153e5ef9d22dc9591a65353119d7fe203a28258ab82278aeb86b46fe691bcfb6a disable-locale-tests.patch 56a2b13b6cd7b127c04ac50ebf49994ec91ff2467d5d0f32b8428bd4df82b167459d4630dee5d1b5119f70b04ea6fe4411d44b768e0f313fa302c9e5fe51b7cd disable-unaligned-access-arm32-xxhash.patch f0a8e3881e742395afc74e418eceab419280152f0884fd6b9dc971d90e117de1cd0a7578c08f14f694c75b904f12fa71fb0102dde0d67a095f6369b3413f7348 fix-test-32-bit-zstd.patch"