{% set name = "conda-build" %}
{% set version = "24.1.2" %}
{% set build_number = "0" %}
{% set sha256 = "4a93cfe56d40dee3e444d845f44feb9f0cc2ec8e9427a699341d5eb177961d29" %}


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

source:
  url: https://github.com/conda/{{ name }}/archive/{{ version }}.tar.gz
  sha256: {{ sha256 }}

build:
  skip: True  # [py<38]
  number: {{ build_number }}
  script: {{ PYTHON }} -m pip install . --no-deps --no-build-isolation -vv
  entry_points:
    - conda-build = conda_build.cli.main_build:execute
    - conda-convert = conda_build.cli.main_convert:execute
    - conda-debug = conda_build.cli.main_debug:execute
    - conda-develop = conda_build.cli.main_develop:execute
    - conda-inspect = conda_build.cli.main_inspect:execute
    - conda-metapackage = conda_build.cli.main_metapackage:execute
    - conda-render = conda_build.cli.main_render:execute
    - conda-skeleton = conda_build.cli.main_skeleton:execute

requirements:
  build:
    # The build workers have cygwin git already installed so it is not necessary,
    # see https://github.com/anaconda-distribution/anaconda-linter/issues/189#issue-1568495905
    - git  # [not win]
  host:
    - python
    - pip
    - hatchling >=1.12.2
    - hatch-vcs >=0.2.0
    - wheel
  run:
    - beautifulsoup4
    - cctools # [osx]
    - chardet
    - conda >=22.11.0
    - conda-index >=0.4.0
    - conda-package-handling >=1.3
    - filelock
    - jinja2
    - jsonschema >=4.19
    - m2-patch  >=2.6   # [win]
    - menuinst >=2
    - packaging
    - patch     >=2.6   # [not win]
    - patchelf      # [linux]
    - pkginfo
    - psutil
    - py-lief
    - python
    - python-libarchive-c
    - pytz
    - pyyaml
    - requests
    - tomli         # [py<311]
    - tqdm
  run_constrained:
    - conda-verify >=3.1.0

test:
  imports:
    # high-level import
    - conda_build
    # updated submodules (can be dropped after 1-2 releases)
    - conda_build.index
  requires:
    - setuptools
    - pip
  files:
    - test_bdist_conda_setup.py
  commands:
    - python -m pip check
    # subcommands
    - conda --help
    - conda build --help
    - conda convert --help
    - conda develop --help
    - conda inspect --help
    - conda inspect linkages --help  # [unix]
    - conda inspect objects --help  # [osx]
    - conda metapackage --help
    - conda render --help
    - conda skeleton --help
    - conda debug --help
    # entrypoints
    - conda-build --help
    - conda-convert --help
    - conda-develop --help
    - conda-inspect --help
    - conda-inspect linkages --help  # [unix]
    - conda-inspect objects --help  # [osx]
    - conda-metapackage --help
    - conda-render --help
    - conda-skeleton --help
    - conda-debug --help
    # bdist_conda
    - python test_bdist_conda_setup.py bdist_conda --help

about:
  home: https://github.com/conda/conda-build
  summary: tools for building conda packages
  license: BSD-3-Clause
  license_family: BSD
  license_file: LICENSE
  description: |
    Conda-build contains commands and tools to allow you to build your own
    packages for conda.
  doc_url: https://docs.conda.io/projects/conda-build/en/latest/
  dev_url: https://github.com/conda/conda-build

extra:
  skip-lints:
    - python_build_tool_in_run
    - missing_pip_check
    - build_tools_must_be_in_build
    - patch_unnecessary
