{% set version = '1.0-14' %}

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

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

source:
  fn: automap_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/automap_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/automap/automap_{{ version }}.tar.gz
  sha256: 1c58303679313633cb9d395997f74c07cb48165dabb9e821e8007570eb9a2085

build:
  number: 0
  skip: true  # [win32]

  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - r-base
    - r-gstat
    - r-lattice
    - r-reshape
    - r-sp >=0.9

  run:
    - r-base
    - r-gstat
    - r-lattice
    - r-reshape
    - r-sp >=0.9

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

about:
  home: https://CRAN.R-project.org/package=automap
  license: GPL-2.0 or GPL-3.0
  summary: This package performs an automatic interpolation by automatically estimating the variogram
    and then calling gstat.
  license_family: GPL

extra:
  recipe-maintainers:
    - daf
