{% set version = '0.1-5' %}
{% set posix = 'm2-' if win else '' %}
{% set native = 'm2w64-' if win else '' %}

package:
  name: r-sizer
  version: {{ version|replace("-", "_") }}

source:
  fn: SiZer_{{ version }}.tar.gz
  url:
    - {{ cran_mirror }}/src/contrib/SiZer_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/SiZer/SiZer_{{ version }}.tar.gz
  sha256: d844b947ef2dc77e1b1ea1e6aeb325e478e8a05533e416f172dfa1a27e3eb4d1

build:
  merge_build_host: True  # [win]
  number: 0
  skip: true  # [win32]
  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - {{posix}}zip               # [win]
  host:
    - r-base
    - r-boot
  run:
    - r-base
    - r-boot

test:
  commands:
    - $R -e "library('SiZer')"           # [not win]
    - "\"%R%\" -e \"library('SiZer')\""  # [win]

about:
  home: https://github.com/dereksonderegger/SiZer
  license: GPL (>= 2)
  summary: Calculates and plots the SiZer map for scatterplot data.  A  SiZer map is a way of
    examining when the p-th derivative of a  scatterplot-smoother is significantly negative,
    possibly zero or  significantly positive across a range of smoothing bandwidths.
  license_family: GPL3
  license_file: '{{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-3'  # [unix]
  license_file: '{{ environ["PREFIX"] }}\R\share\licenses\GPL-3'  # [win]

extra:
  recipe-maintainers:
    - johanneskoester
    - bgruening
    - daler
    - jdblischak
    - cbrueffer
