{% set name = "rdkit" %}
{% set version = "2021.03.3" %}
{% set filename = "Release_%s.tar.gz" % version.replace(".", "_") %}

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

source:
  fn: {{ filename }}
  url: https://github.com/rdkit/rdkit/archive/{{ filename }}
  sha256: e95f07adaee9280df077cb147210ee75e16957d81687ab0836d62ebf1f6f715f

build:
  number: 0

requirements:
  build:
    - python                                 # [build_platform != target_platform]
    - cross-python_{{ target_platform }}     # [build_platform != target_platform]
    - numpy                                  # [build_platform != target_platform]
    - {{ compiler('cxx') }}
    - cmake
    - jom  # [win]
    - make  # [unix]
    - pkg-config
  host:
    - boost
    - cairo
    - eigen
    - freetype
    - python
    - numpy
    - pillow
    - pandas
  run:
    - boost
    - cairo
    - python
    - pillow
    - pandas
    - {{ pin_compatible('numpy') }}
    - pycairo
    - matplotlib-base
    - sqlalchemy
    - reportlab

test:
  imports:
    - rdkit
    - rdkit.Avalon
    - rdkit.Chem
    - rdkit.Chem.AllChem
    - rdkit.DataManip
    - rdkit.Dbase
    - rdkit.DistanceGeometry
    - rdkit.ForceField
    - rdkit.Geometry
    - rdkit.ML
    - rdkit.Numerics
    - rdkit.SimDivFilters
    - rdkit.VLib
    - rdkit.VLib.NodeLib

outputs:
  - name: rdkit
  - name: rdkit-dev
    script: install_rdkit_dev.bat  # [win]
    requirements:
      run:
        - rdkit
    test:
      commands:
        - if not exist %LIBRARY_INC%\\rdkit\\Catalogs\\Catalog.h exit 1   # [win]
    about:
      summary: RDKit headers and library used in rdkit package
      license: BSD-3-Clause
      license_file: license.txt

about:
  home: http://rdkit.org
  license: BSD-3-Clause
  license_file: license.txt
  summary: RDKit is a collection of cheminformatics and machine-learning software written in C++ and Python.
  doc_url: http://www.rdkit.org/docs/index.html
  dev_url: https://github.com/rdkit/rdkit

extra:
  recipe-maintainers:
    - pstjohn
    - mcs07
    - jaimergp
