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

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/distrEx_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/distrEx/distrEx_{{ version }}.tar.gz
  sha256: b064cde7d63ce93ec9969c8c4463c1e327758b6f8ea7765217d77f9ba9d590bf

build:
  merge_build_host: True  # [win]
  number: 2
  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - {{ compiler('c') }}        # [not win]
    - {{ compiler('m2w64_c') }}        # [win]
    - {{ posix }}filesystem        # [win]
    - {{ posix }}make
    - {{ posix }}sed               # [win]
    - {{ posix }}coreutils         # [win]
    - {{ posix }}zip               # [win]
  host:
    - r-base
    - r-distr >=2.8.0
    - r-startupmsg
  run:
    - r-base
    - {{ native }}gcc-libs         # [win]
    - r-distr >=2.8.0
    - r-startupmsg

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

about:
  home: http://distr.r-forge.r-project.org/
  license: LGPL-3
  summary: Extends package 'distr' by functionals, distances, and conditional distributions.
  license_family: LGPL
  license_file: '{{ environ["PREFIX"] }}/lib/R/share/licenses/LGPL-3'

extra:
  recipe-maintainers:
    - conda-forge/r

# Package: distrEx
# Version: 2.8.0
# Date: 2019-03-29
# Title: Extensions of Package 'distr'
# Description: Extends package 'distr' by functionals, distances, and conditional distributions.
# Depends: R(>= 3.4), methods, distr(>= 2.8.0)
# Imports: startupmsg, utils, stats
# Suggests: tcltk
# Authors@R: c(person("Matthias", "Kohl", role=c("cre", "cph"), email="Matthias.Kohl@stamats.de"), person("Peter", "Ruckdeschel", role=c("aut", "cph")))
# ByteCompile: yes
# License: LGPL-3
# Encoding: latin1
# URL: http://distr.r-forge.r-project.org/
# LastChangedDate: {$LastChangedDate: 2019-03-29 11:46:27 +0100 (Fr, 29 Mrz 2019) $}
# LastChangedRevision: {$LastChangedRevision: 1333 $}
# VCS/SVNRevision: 1332
# NeedsCompilation: yes
# Packaged: 2019-03-29 10:47:31 UTC; ruckdesc
# Author: Matthias Kohl [cre, cph], Peter Ruckdeschel [aut, cph]
# Maintainer: Matthias Kohl <Matthias.Kohl@stamats.de>
# Repository: CRAN
# Date/Publication: 2019-03-29 17:50:08 UTC
