{% set version = '5.0-2' %}

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

package:
  name: r-gamlss.dist
  version: {{ version|replace("-", "_") }}

source:
  fn: gamlss.dist_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/gamlss.dist_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/gamlss.dist/gamlss.dist_{{ version }}.tar.gz
  sha256: f9f927d0e8ca3c595337ddaa79ad5a44ee0e916e8fbaed5f24a97391412a0c33

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

  rpaths:
    - lib/R/lib/
    - lib/
requirements:
  build:
    - r-base
    - r-mass
    - posix                # [win]
    - {{native}}toolchain  # [win]
    - gcc                  # [not win]

  run:
    - r-base
    - r-mass
    - libgcc  # [not win]

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

about:
  home: http://www.gamlss.org/
  license: GPL-2 | GPL-3
  summary: The different distributions used for the response variables in Generalized Additive
    Models for Location Scale and Shape.
  license_family: GPL3

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