{% set version = "2.9" %}

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

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

source:
  fn: rsm_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/rsm_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/rsm/rsm_{{ version }}.tar.gz
  sha256: d172384d5b60aa969c6ad81ee696b9d78364b5be0d9e7d63d80b12b269c342e6

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

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

requirements:
  build:
    - r-base
    - r-estimability
    - r-lsmeans

  run:
    - r-base
    - r-estimability
    - r-lsmeans

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

about:
  home: https://CRAN.R-project.org/package=rsm
  license: GPL-2
  summary: Provides functions to generate response-surface designs,  fit first- and second-order
    response-surface models,  make surface plots, obtain the path of steepest ascent,  and
    do canonical analysis.
  license_family: GPL2

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