{% set name = "Trinity" %}
{% set version = "2.12.0" %}
{% set sha256 = "0d47dc433cc3003e1c732b97da605e29c6ccafa38cd52cdb8ecc42399a9195d0" %}

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

source:
  url: https://github.com/trinityrnaseq/trinityrnaseq/releases/download/v{{ version }}/trinityrnaseq-v{{ version }}.FULL.tar.gz
  sha256: {{ sha256 }}
  patches:
    - makefile.patch

build:
  skip: True  # [osx]
  number: 3

requirements:
  build:
    - make
    - {{ compiler('cxx') }}
    - {{ compiler('c') }}
    - cmake
    - autoconf
    - libgomp  # [linux]
    - llvm-openmp  # [osx]
  host:
    - zlib
    - htslib
  run:
    - zlib
    - trimmomatic >=0.36
    - bowtie
    - bowtie2 >=2.3.0
    - kmer-jellyfish >=2.2
    - openjdk >=8
    - perl
    - python >=3.6
    - samtools >=1.9
    - salmon >=1.0
    - kallisto
    - numpy
    - r-cluster
    - r-gplots
    - bioconductor-qvalue
    - r-fastcluster
    - r-argparse
    - bioconductor-ctc
    - r-ape
    - bioconductor-edger
    - r-phangorn
    - r-gplots
    - r-tidyverse
    - bioconductor-goseq
    - bioconductor-go.db
    - r-sm
    - bioconductor-dexseq
    - r-vioplot
    - htslib
    - coreutils
    - r-base >=4

test:
  commands:
    - "Trinity --cite"
    - "align_and_estimate_abundance.pl --help || [[ \"$?\" == 255 ]]"
    - "abundance_estimates_to_matrix.pl --help || [[ \"$?\" == 255 ]]"
    - "run_DE_analysis.pl -h || [[ \"$?\" == 255 ]]"
    - "analyze_diff_expr.pl -h || [[ \"$?\" == 255 ]]"
    - "PtR --help || [[ \"$?\" == 255 ]]"
    - "TrinityStats.pl 2>&1 | grep \"usage:\""
    - "define_clusters_by_cutting_tree.pl 2>&1 | grep \"define K clusters via k-means algorithm\""
    - "Trinity_gene_splice_modeler.py --help"

about:
  home: https://github.com/trinityrnaseq/trinityrnaseq/
  license: BSD-3-Clause
  license_family: BSD
  license_file:
    - LICENSE
    - LICENSE.txt
  summary: "Trinity assembles transcript sequences from Illumina RNA-Seq data."
  doc_url: https://github.com/trinityrnaseq/trinityrnaseq/wiki
  dev_url: https://github.com/trinityrnaseq/trinityrnaseq/

extra:
  identifiers:
    - biotools:trinity
    - doi:10.1038/nbt.1883
    - usegalaxy-eu:trinity
