{% set version = "1.6.9" %}

package:
  name: orc
  version: {{ version }}

source:
  url: https://archive.apache.org/dist/orc/orc-{{ version }}/orc-{{ version }}.tar.gz
  sha256: d19af60cd81cdb17872aa99b3687e471683e22c6fae73a21d5fc5aed636ebbb8
  patches:
    # ORC builds by default with -Werror but some dependencies omit warnings.
    # This deactivates -Werror
    - 0001-Deactivate-aggressive-failures-on-warnings.patch
    - 0002-Partially-rework-cmake-modules-to-accommodate-librar.patch
    - 0003-Don-t-force-orc-to-be-a-static-library-let-end-user-.patch

build:
  number: 0
  skip: true  # [win]
  run_exports:
    - {{ pin_subpackage("orc", max_pin="x.x.x") }}

requirements:
  build:
    - {{ compiler('c') }}
    - {{ compiler('cxx') }}
    - ninja       # [unix]
    # `protoc` is also used for building
    - libprotobuf
    - cmake
  host:
    - zlib
    - snappy
    - libprotobuf
    - lz4-c
    - zstd

test:
  commands:
    - test -f $PREFIX/lib/liborc${SHLIB_EXT}  # [unix]
    - test -f $PREFIX/include/orc/Common.hh   # [unix]

about:
  home: http://github.com/apache/orc
  license: Apache-2.0
  license_family: Apache
  license_file: LICENSE
  summary: C++ libraries for Apache ORC

extra:
  recipe-maintainers:
    - wesm
    - xhochy
    - nehaljwani
