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

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

source:
  fn: pbkrtest_{{ version }}.tar.gz
  url:
    - {{ cran_mirror }}/src/contrib/pbkrtest_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/pbkrtest/pbkrtest_{{ version }}.tar.gz
  sha256: 5cbb03ad2b2468720a5a610a0ebda48ac08119a34fca77810a85f554225c23ea

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

requirements:
  build:
    - {{posix}}zip               # [win]
  host:
    - r-base
    - r-mass
    - r-matrix >=1.2.3
    - r-lme4 >=1.1.10
  run:
    - r-base
    - r-mass
    - r-matrix >=1.2.3
    - r-lme4 >=1.1.10

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

about:
  home: http://people.math.aau.dk/~sorenh/software/pbkrtest/
  license: GPL (>= 2)
  summary: Test in mixed effects models. Attention is on mixed effects models as implemented
    in the 'lme4' package. This package implements a parametric bootstrap test and a
    Kenward Roger modification of F-tests for linear mixed effects models and a parametric
    bootstrap test for generalized linear mixed models.
  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
    - dbast
