blob: 91f521fa4dbfd207f4904e0e908b40b8c3f917b6 [file] [log] [blame]
Andrew Geissler517393d2023-01-13 08:55:19 -06001SUMMARY = "Support for reading various archive formats"
2DESCRIPTION = "C library and command-line tools for reading and writing tar, cpio, zip, ISO, and other archive formats"
3HOMEPAGE = "http://www.libarchive.org/"
4SECTION = "devel"
5LICENSE = "BSD-2-Clause"
6LIC_FILES_CHKSUM = "file://COPYING;md5=d499814247adaee08d88080841cb5665"
7
8DEPENDS = "e2fsprogs-native"
9
Patrick Williams8e7b46e2023-05-01 14:19:06 -050010PACKAGECONFIG ?= "zlib bz2 xz zstd ${@bb.utils.filter('DISTRO_FEATURES', 'acl xattr', d)}"
Andrew Geissler517393d2023-01-13 08:55:19 -060011
12DEPENDS_BZIP2 = "bzip2-replacement-native"
13DEPENDS_BZIP2:class-target = "bzip2"
14
15PACKAGECONFIG[acl] = "--enable-acl,--disable-acl,acl,"
16PACKAGECONFIG[xattr] = "--enable-xattr,--disable-xattr,attr,"
17PACKAGECONFIG[zlib] = "--with-zlib,--without-zlib,zlib,"
18PACKAGECONFIG[bz2] = "--with-bz2lib,--without-bz2lib,${DEPENDS_BZIP2},"
19PACKAGECONFIG[xz] = "--with-lzma,--without-lzma,xz,"
20PACKAGECONFIG[openssl] = "--with-openssl,--without-openssl,openssl,"
Patrick Williamsac13d5f2023-11-24 18:59:46 -060021PACKAGECONFIG[libb2] = "--with-libb2,--without-libb2,libb2,"
Andrew Geissler517393d2023-01-13 08:55:19 -060022PACKAGECONFIG[libxml2] = "--with-xml2,--without-xml2,libxml2,"
23PACKAGECONFIG[expat] = "--with-expat,--without-expat,expat,"
24PACKAGECONFIG[lzo] = "--with-lzo2,--without-lzo2,lzo,"
25PACKAGECONFIG[nettle] = "--with-nettle,--without-nettle,nettle,"
26PACKAGECONFIG[lz4] = "--with-lz4,--without-lz4,lz4,"
27PACKAGECONFIG[mbedtls] = "--with-mbedtls,--without-mbedtls,mbedtls,"
28PACKAGECONFIG[zstd] = "--with-zstd,--without-zstd,zstd,"
29
30EXTRA_OECONF += "--enable-largefile --without-iconv"
31
32SRC_URI = "http://libarchive.org/downloads/libarchive-${PV}.tar.gz"
Patrick Williams2a254922023-08-11 09:48:11 -050033SRC_URI += "file://configurehack.patch"
Andrew Geissler517393d2023-01-13 08:55:19 -060034UPSTREAM_CHECK_URI = "http://libarchive.org/"
35
Andrew Geissler220dafd2023-10-04 10:18:08 -050036SRC_URI[sha256sum] = "df404eb7222cf30b4f8f93828677890a2986b66ff8bf39dac32a804e96ddf104"
Andrew Geissler517393d2023-01-13 08:55:19 -060037
Patrick Williams2a254922023-08-11 09:48:11 -050038CVE_STATUS[CVE-2023-30571] = "upstream-wontfix: upstream has documented that reported function is not thread-safe"
39
Andrew Geissler517393d2023-01-13 08:55:19 -060040inherit autotools update-alternatives pkgconfig
41
42CPPFLAGS += "-I${WORKDIR}/extra-includes"
43
44do_configure[cleandirs] += "${WORKDIR}/extra-includes"
45do_configure:prepend() {
46 # We just need the headers for some type constants, so no need to
47 # build all of e2fsprogs for the target
48 cp -R ${STAGING_INCDIR_NATIVE}/ext2fs ${WORKDIR}/extra-includes/
49}
50
51ALTERNATIVE_PRIORITY = "80"
52
53PACKAGES =+ "bsdtar"
54FILES:bsdtar = "${bindir}/bsdtar"
55
56ALTERNATIVE:bsdtar = "tar"
57ALTERNATIVE_LINK_NAME[tar] = "${base_bindir}/tar"
58ALTERNATIVE_TARGET[tar] = "${bindir}/bsdtar"
59
60PACKAGES =+ "bsdcpio"
61FILES:bsdcpio = "${bindir}/bsdcpio"
62
63ALTERNATIVE:bsdcpio = "cpio"
64ALTERNATIVE_LINK_NAME[cpio] = "${base_bindir}/cpio"
65ALTERNATIVE_TARGET[cpio] = "${bindir}/bsdcpio"
66
67BBCLASSEXTEND = "native nativesdk"