{% set name = "Jmol" %}
{% set version = "14.32.10" %}
{% set majmin = '.'.join(version.split('.')[:2]) %}
{% set sha256 = "e8de64705a80afc27a6c8ba28d624459305be98d2b41f9737effed856de74d5a" %}

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

source:
  url: https://sourceforge.net/projects/jmol/files/Jmol/Version {{ majmin }}/Jmol {{ version }}/Jmol-{{ version }}-binary.tar.gz
  sha256: {{ sha256 }}

build:
  number: 0

requirements:
  build:
    - unzip      # [not win]
    - m2-unzip   # [win]
  run:
    # https://github.com/conda-forge/jmol-feedstock/issues/1
    - openjdk >8.0.121

test:
  commands:
    # In windows following command opens the GUI and conda build gets stuck.
    - jmol -n    # [not win]

about:
  home: http://www.jmol.org
  license: LGPL
  license_file: LICENSE.txt
  summary: Jmol is an open-source molecule viewer and editor
  description: |
    Jmol is a free, open source molecule viewer for students, educators, and
    researchers in chemistry, biochemistry, physics, and materials science.
  doc_url: http://jmol.sourceforge.net/#Learn%20to%20use%20Jmol
  dev_url: https://github.com/BobHanson/Jmol-SwingJS

extra:
  recipe-maintainers:
    - isuruf
    - saraedum
