{% set name = "cgat-apps" %}
{% set version = "0.7.4" %}

package:
  name: {{ name|lower }}
  version: {{ version }}

source:
  url: https://github.com/cgat-developers/cgat-apps/archive/refs/tags/v{{ version }}.tar.gz
  sha256: 3e161597c6e4cf59fc121a8527aeddefd1526f7d13c370d5eaf15b4d3a1894e6
  patches:
    - 0001-setup.py.patch
  
build:
  number: 0
  run_exports:
    - {{ pin_subpackage('cgat-apps', max_pin="x.x") }}
  entry_points:
    - cgat = cgat.cgat:main

requirements:
  build:
    - {{ compiler('c') }}
    - {{ compiler('cxx') }}
  host:
    - python
    - pip
    - cython >=0.29.35
    - numpy
    - pysam
    - htslib
  run:
    - python
    - cgatcore
    - alignlib-lite
    - biopython
    - matplotlib-base
    - numpy
    - pandas
    - pybedtools
    - pybigwig
    - pysam
    - htslib
    - pyyaml
    - quicksect
    - scipy
    - scikit-learn
    - sortedcontainers
    # Misc dependencies
    - bedtools
    - ucsc-bedgraphtobigwig
    - ucsc-wigtobigwig
    - coreutils
    - grep

test:
  imports:
    - cgat
  commands:
    - cgat --help
    - cgat --help Conversion
    - cgat gtf2table -h
    - find ${PREFIX} -iname "*bamtools.cpython-*-x86_64-linux-gnu.so*" -exec ldd {} \;
    - cgat bam2bed -h

about:
  home: "https://github.com/cgat-developers/cgat-apps"
  license: MIT
  license_family: MIT
  license_file: LICENSE
  summary: "Computational Genomics Analysis Toolkit."
  dev_url: "https://github.com/cgat-developers/cgat-apps"
  doc_url: "https://cgat-apps.readthedocs.io/en/latest"
