package:
  name: torchtext
  version: "{{ environ.get('BUILD_VERSION') }}"

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

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

  host:
    - python
    - setuptools
    - cpuonly
    {{ environ.get('CONDA_PYTORCH_BUILD_CONSTRAINT', 'pytorch') }}
    {{ environ.get('CONDA_EXTRA_BUILD_CONSTRAINT', '') }}


  run:
    - python
    - requests
    - tqdm
    {{ environ.get('CONDA_PYTORCH_CONSTRAINT') }}
    {{ environ.get('CONDA_TORCHDATA_CONSTRAINT') }}

build:
  string: py{{py}}
  script_env:
    - BUILD_VERSION
    - MACOSX_DEPLOYMENT_TARGET

test:
  imports:
    - torchtext
    - torchtext.datasets
    - torchtext.data
    - torchtext.prototype

  source_files:
    - test

  requires:
    - pytest
    - cpuonly

about:
  home: https://github.com/pytorch/text
  license: BSD
  license_file: LICENSE
  summary: 'Data loaders and abstractions for text and NLP'
