{% set version = '4.0-1' %}
{% set sha256 = 'd8f0aa490242dafa5339f5a65d6068b37b7a3f6dcd34ae3ac64fa574d6334e10' %}
{% set posix = 'm2-' if win else '' %}
{% set native = 'm2w64-' if win else '' %}

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

source:
  fn: effects_{{ version }}.tar.gz
  url:
    - {{ cran_mirror }}/src/contrib/effects_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/effects/effects_{{ version }}.tar.gz
  sha256: {{ sha256 }}

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

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

requirements:
  build:

  host:
    - r-base
    - r-cardata
    - r-colorspace
    - r-estimability
    - r-lattice
    - r-lme4
    - r-nnet
    - r-survey

  run:
    - r-base
    - r-cardata
    - r-colorspace
    - r-estimability
    - r-lattice
    - r-lme4
    - r-nnet
    - r-survey

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

about:
  home: https://CRAN.R-project.org/package=effects
  license: GPL2, GPL3
  summary: Graphical and tabular effect displays, e.g., of interactions, for  various statistical
    models with linear predictors.

  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
    - ccwang002
