package:
  name: torchaudio
  version: "{{ environ.get('TORCHAUDIO_BUILD_VERSION') }}"

source:
  path: "{{ environ.get('TORCHAUDIO_GITHUB_ROOT_DIR') }}"

requirements:
  build:
    - {{ compiler('c') }} # [win]
    - {{ compiler('cxx') }} # [win]

  host:
    - python
    - setuptools
{{ environ.get('CONDA_PYTORCH_CONSTRAINT') }}

  run:
    - python
    - typing
{{ environ.get('CONDA_PYTORCH_CONSTRAINT') }}

build:
  number: {{ environ.get('TORCHAUDIO_BUILD_NUMBER') }}
  string: py{{py}}_{{environ.get('TORCHAUDIO_BUILD_NUMBER')}}

test:
  imports:
    - torchaudio
    - torchaudio.datasets
    - torchaudio.kaldi_io
    - torchaudio.sox_effects
    - torchaudio.transforms

  source_files:
    - test

  requires:
    - pytest
    # Ideally we would test this, but conda doesn't provide librosa
    # - librosa >=0.4.3
    - scipy

about:
  home: https://github.com/pytorch/audio
  license: BSD
  license_file: LICENSE
  summary: 'simple audio I/O for pytorch'
