2008-12-26 10:02:30 +00:00
|
|
|
# Template file for 'libarchive'
|
|
|
|
pkgname=libarchive
|
2013-02-20 13:34:18 +00:00
|
|
|
version=3.1.2
|
2014-03-14 08:17:44 +00:00
|
|
|
revision=5
|
2014-01-01 15:10:11 +00:00
|
|
|
bootstrap=yes
|
2011-10-24 12:14:47 +00:00
|
|
|
build_style=gnu-configure
|
2013-10-18 06:15:42 +00:00
|
|
|
configure_args="--without-xml2 --without-nettle --disable-rpath"
|
|
|
|
makedepends="zlib-devel bzip2-devel liblzma-devel"
|
2010-02-19 16:59:43 +00:00
|
|
|
short_desc="Library to read/write several different streaming archive formats"
|
2008-12-26 10:02:30 +00:00
|
|
|
maintainer="Juan RP <xtraeme@gmail.com>"
|
2013-02-20 13:34:18 +00:00
|
|
|
homepage="http://www.libarchive.org/"
|
2011-09-07 09:17:19 +00:00
|
|
|
license="BSD"
|
2013-02-20 13:34:18 +00:00
|
|
|
distfiles="http://www.libarchive.org/downloads/libarchive-${version}.tar.gz"
|
|
|
|
checksum=eb87eacd8fe49e8d90c8fdc189813023ccc319c5e752b01fb6ad0cc7b2c53d5e
|
2013-02-06 16:10:58 +00:00
|
|
|
|
2013-10-24 08:06:51 +00:00
|
|
|
if [ -z "$CHROOT_READY" ]; then
|
|
|
|
CFLAGS+=" -I${XBPS_MASTERDIR}/usr/include"
|
|
|
|
LDFLAGS+=" -L${XBPS_MASTERDIR}/usr/lib"
|
|
|
|
fi
|
|
|
|
|
2013-04-08 23:49:27 +00:00
|
|
|
if [ "$CROSS_BUILD" ]; then
|
2013-10-18 06:15:42 +00:00
|
|
|
hostmakedepends="libtool"
|
2013-02-20 13:34:18 +00:00
|
|
|
pre_configure() {
|
2013-10-18 06:15:42 +00:00
|
|
|
libtoolize -f
|
2013-02-20 13:34:18 +00:00
|
|
|
}
|
2013-02-06 16:10:58 +00:00
|
|
|
fi
|
2013-04-12 11:13:49 +00:00
|
|
|
|
2013-10-18 06:15:42 +00:00
|
|
|
# Package build options
|
2013-10-19 10:30:08 +00:00
|
|
|
build_options="acl expat lzo ssl"
|
2013-10-18 06:15:42 +00:00
|
|
|
desc_option_acl="Enable support for ACLs and Extended Attributes"
|
|
|
|
desc_option_expat="Enable support for XAR format through expat"
|
|
|
|
desc_option_lzo="Enable support for LZO format"
|
|
|
|
desc_option_ssl="Enable support for mtree/XAR hashes"
|
|
|
|
|
|
|
|
# Enable acl and ssl by default.
|
|
|
|
build_options_default="acl ssl"
|
|
|
|
|
|
|
|
if [ "$build_option_acl" ]; then
|
|
|
|
configure_args+=" --enable-xattr --enable-acl"
|
|
|
|
makedepends+=" acl-devel"
|
|
|
|
else
|
|
|
|
configure_args+=" --disable-xattr --disable-acl"
|
|
|
|
fi
|
|
|
|
|
|
|
|
if [ "$build_option_expat" ]; then
|
|
|
|
configure_args+=" --with-expat"
|
|
|
|
makedepends+=" expat-devel"
|
|
|
|
else
|
|
|
|
configure_args+=" --without-expat"
|
|
|
|
fi
|
|
|
|
|
|
|
|
if [ "$build_option_lzo" ]; then
|
|
|
|
configure_args+=" --with-lzo2"
|
|
|
|
makedepends+=" lzo-devel"
|
|
|
|
else
|
|
|
|
configure_args+=" --without-lzo2"
|
|
|
|
fi
|
|
|
|
|
|
|
|
if [ "$build_option_ssl" ]; then
|
|
|
|
configure_args+=" --with-openssl"
|
|
|
|
makedepends+=" openssl-devel"
|
|
|
|
else
|
|
|
|
configure_args+=" --without-openssl"
|
|
|
|
fi
|
|
|
|
|
2013-04-12 11:13:49 +00:00
|
|
|
bsdtar_package() {
|
|
|
|
short_desc="BSD tar(1) using libarchive"
|
|
|
|
pkg_install() {
|
|
|
|
vmove usr/bin/bsdtar
|
|
|
|
vmove usr/share/man/man1/bsdtar.1
|
|
|
|
vmove usr/share/man/man5/tar.5
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
bsdcpio_package() {
|
|
|
|
short_desc="BSD cpio(1) using libarchive"
|
|
|
|
pkg_install() {
|
|
|
|
vmove usr/bin/bsdcpio
|
|
|
|
vmove usr/share/man/man1/bsdcpio.1
|
|
|
|
vmove usr/share/man/man5/cpio.5
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
libarchive-devel_package() {
|
2013-10-18 06:15:42 +00:00
|
|
|
depends="zlib-devel bzip2-devel liblzma-devel"
|
|
|
|
if [ "$build_option_acl" ]; then
|
|
|
|
depends+=" acl-devel"
|
|
|
|
fi
|
|
|
|
if [ "$build_option_expat" ]; then
|
|
|
|
depends+=" expat-devel"
|
|
|
|
fi
|
|
|
|
if [ "$build_option_lzo" ]; then
|
|
|
|
depends+=" lzo-devel"
|
|
|
|
fi
|
|
|
|
if [ "$build_option_ssl" ]; then
|
|
|
|
depends+=" openssl-devel"
|
|
|
|
fi
|
|
|
|
depends+=" libarchive>=${version}_${revision}"
|
2013-05-25 09:45:14 +00:00
|
|
|
short_desc+=" - development files"
|
2013-04-12 11:13:49 +00:00
|
|
|
pkg_install() {
|
|
|
|
vmove usr/include
|
|
|
|
vmove "usr/lib/*.a"
|
2013-10-18 06:15:42 +00:00
|
|
|
vmove "usr/lib/*.so"
|
2013-04-12 11:13:49 +00:00
|
|
|
vmove usr/lib/pkgconfig
|
|
|
|
vmove usr/share
|
|
|
|
}
|
|
|
|
}
|