libarchive: static executables, executables split
parent
388fc77877
commit
a6ab3d7b94
|
@ -1,4 +1,35 @@
|
|||
name: libarchive
|
||||
version: 3.3.3
|
||||
release: 1
|
||||
release: 2
|
||||
sources: https://www.libarchive.org/downloads/libarchive-%{version}.tar.gz
|
||||
build-dependencies: xz-dev, zlib-dev, bzip2-dev, lzo-dev
|
||||
dependencies: xz, zlib, bzip2, lzo
|
||||
|
||||
options:
|
||||
- configure: --with-zlib --with-lzo2 --with-lzma --with-bz2lib --without-zstd --without-cng --without-nettle --without-openssl --without-expat --without-xml2 --enable-posix-regex-lib=libc LDFLAGS="-L%{prefix}/lib -static"
|
||||
|
||||
@build
|
||||
cd %{name}-%{version}
|
||||
make
|
||||
|
||||
for i in tar cpio cat; do
|
||||
${CC:-cc} -static -o bsd${i} \
|
||||
${i}/*.o \
|
||||
.libs/libarchive.a .libs/libarchive_fe.a \
|
||||
-llzma -lz -llzo2 -lbz2
|
||||
done
|
||||
|
||||
# FIXME: We’ll want to use those as default `tar`, `cpio` and `zcat`
|
||||
# implementations in the future.
|
||||
%split bsdtar
|
||||
files: %{prefix}/bin/bsdtar
|
||||
dependencies: libarchive
|
||||
|
||||
%split bsdcpio
|
||||
files: %{prefix}/bin/bsdcpio
|
||||
dependencies: libarchive
|
||||
|
||||
%split bsdcat
|
||||
files: %{prefix}/bin/bsdcat
|
||||
dependencies: libarchive
|
||||
|
||||
|
|
Reference in New Issue