{% set version = "1.1.20" %}
{% set posix = 'm2-' if win else '' %}
{% set native = 'm2w64-' if win else '' %}

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/IDPmisc_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/IDPmisc/IDPmisc_{{ version }}.tar.gz
  sha256: bcb9cd7b8097e5089d1936286ef310ac2030ea7791350df706382ba470afc67f

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

requirements:
  build:
    - {{ compiler('c') }}              # [not win]
    - {{ compiler('m2w64_c') }}        # [win]
    - {{posix}}filesystem        # [win]
    - {{posix}}make
    - {{posix}}sed               # [win]
    - {{posix}}coreutils         # [win]
    - {{posix}}zip               # [win]
  host:
    - r-base
    - r-lattice
  run:
    - r-base
    - r-lattice

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

about:
  home: https://CRAN.R-project.org/package=IDPmisc
  license: GPL (>= 3)
  summary: |
    The IDPmisc package contains different high-level graphics functions for displaying
    large datasets, displaying circular data in a very flexible way, finding local maxima,
    brewing color ramps, drawing nice arrows, zooming 2D-plots, creating figures with
    differently colored margin and plot region.  In addition, the package contains auxiliary
    functions for data manipulation like omitting observations with irregular values
    or selecting data by logical vectors, which include NAs. Other functions are especially
    useful in spectroscopy and analyses of environmental data: robust baseline fitting,
    finding peaks in spectra.
  license_family: GPL3
  license_file:
    - '{{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-3'

extra:
  recipe-maintainers:
    - conda-forge/r
