# This file created by conda-build 25.1.2
# meta.yaml template originally from:
# /home/task_176115161206218/libarchive-feedstock/recipe, last modified Wed Oct 22 16:46:53 2025
# ------------------------------------------------

package:
  name: libarchive
  version: 3.8.2
source:
  patches:
    - patches/0001-Add-lib-to-CMAKE_FIND_LIBRARY_PREFIXES-for-lzma.patch
  sha256: 5f2d3c2fde8dc44583a61165549dc50ba8a37c5947c90fc02c8e5ce7f1cfb80d
  url: https://github.com/libarchive/libarchive/releases/download/v3.8.2/libarchive-3.8.2.tar.gz
build:
  number: '0'
  run_exports:
    - libarchive >=3.8.2,<3.9.0a0
  string: h3ec8f01_0
requirements:
  build:
    - _libgcc_mutex 0.1 main
    - _openmp_mutex 5.1 1_gnu
    - binutils_impl_linux-64 2.40 h5293946_0
    - binutils_linux-64 2.40.0 hc2dff05_2
    - bzip2 1.0.8 h5eee18b_6
    - c-ares 1.34.5 hef5626c_0
    - ca-certificates 2025.9.9 h06a4308_0
    - cmake 4.1.2 hc946e07_0
    - expat 2.7.1 h6a678d5_0
    - gcc_impl_linux-64 11.2.0 h1234567_1
    - gcc_linux-64 11.2.0 h5c386dc_2
    - kernel-headers_linux-64 4.18.0 h528b178_0
    - ld_impl_linux-64 2.40 h12ee557_0
    - libcurl 8.15.0 hc1efc7f_0
    - libev 4.33 h7f8727e_1
    - libgcc-devel_linux-64 11.2.0 h1234567_1
    - libgcc-ng 11.2.0 h1234567_1
    - libgomp 11.2.0 h1234567_1
    - libnghttp2 1.57.0 h2d74bed_0
    - libssh2 1.11.1 h251f7ec_0
    - libstdcxx-ng 11.2.0 h1234567_1
    - libuv 1.48.0 h5eee18b_0
    - libzlib 1.3.1 hb25bd0a_0
    - lz4-c 1.9.4 h6a678d5_1
    - ncurses 6.5 h7934f7d_0
    - ninja-base 1.12.1 hdb19cb5_0
    - openssl 3.0.18 hd6dcaed_0
    - rhash 1.4.6 ha914fed_0
    - sysroot_linux-64 2.28 h528b178_0
    - tzdata 2025b h04d1e81_0
    - xz 5.6.4 h5eee18b_1
    - zlib 1.3.1 hb25bd0a_0
    - zstd 1.5.7 h11fc155_0
  host:
    - _libgcc_mutex 0.1 main
    - _openmp_mutex 5.1 1_gnu
    - bzip2 1.0.8 h5eee18b_6
    - ca-certificates 2025.9.9 h06a4308_0
    - icu 73.1 h6a678d5_0
    - libgcc-ng 11.2.0 h1234567_1
    - libgomp 11.2.0 h1234567_1
    - libstdcxx-ng 11.2.0 h1234567_1
    - libxml2 2.13.8 hfdd30dd_0
    - lz4-c 1.9.4 h6a678d5_1
    - openssl 3.0.18 hd6dcaed_0
    - xz 5.6.4 h5eee18b_1
    - zlib 1.2.13 hd233ad5_2
    - zstd 1.5.6 hc292b87_0
  run:
    - __glibc >=2.28,<3.0.a0
    - bzip2 >=1.0.8,<2.0a0
    - libgcc-ng >=11.2.0
    - libxml2 >=2.13.8,<2.14.0a0
    - lz4-c >=1.9.4,<1.10.0a0
    - openssl >=3.0.18,<4.0a0
    - xz >=5.6.4,<6.0a0
    - zlib >=1.2.13,<2.0a0
    - zstd >=1.5.6,<1.6.0a0
test:
  commands:
    - test -f "${PREFIX}/lib/pkgconfig/libarchive.pc"
    - test -f "${PREFIX}/include/archive.h"
    - test -f "${PREFIX}/include/archive_entry.h"
    - test -f "${PREFIX}/lib/libarchive.a"
    - test -f "${PREFIX}/lib/libarchive${SHLIB_EXT}"
    - bsdcat --version
    - bsdcpio --version
    - bsdtar --version
    - pushd test-archives
    - bsdtar -vxf hello_world.xar 2>&1 | rg "x hello_world"
    - bsdtar -vxf archive.7z 2>&1 | rg "x 7zip-archive"
    - bsdtar -vxf hello_world.tar.zst 2>&1 | rg "greets"
    - popd
  files:
    - test-archives/archive.7z
    - test-archives/hello_world.tar.zst
    - test-archives/hello_world.xar
  requires:
    - ripgrep
about:
  description: 'Libarchive is an open-source BSD-licensed C programming library that
    provides streaming access

    to a variety of different archive formats, including tar, cpio, pax, Zip, and
    ISO9660 images.

    The distribution also includes bsdtar and bsdcpio, full-featured implementations
    of tar and cpio

    that use libarchive.

    When reading archives, libarchive uses a robust automatic format detector that
    can automatically handle archives

    that have been compressed with gzip, bzip2, xz, lzip, and several other popular
    compression algorithms.

    '
  dev_url: https://github.com/libarchive/libarchive
  doc_url: https://github.com/libarchive/libarchive/wiki
  home: https://libarchive.org
  license: BSD-2-Clause
  license_family: BSD
  license_file: COPYING
  summary: Multi-format archive and compression library
extra:
  copy_test_source_files: true
  final: true
  recipe-maintainers:
    - jakirkham
    - mingwandroid
    - ocefpaf
