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

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/doParallel_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/doParallel/doParallel_{{ version }}.tar.gz
  sha256: b96a25ad105a654d70c7b4ca27290dc9967bc47f4668b2763927a886b178abd7

build:
  merge_build_host: true  # [win]
  number: 2
  noarch: generic
  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - {{ posix }}zip               # [win]
  host:
    - r-base
    - r-foreach >=1.2.0
    - r-iterators >=1.0.0
  run:
    - r-base
    - r-foreach >=1.2.0
    - r-iterators >=1.0.0

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

about:
  home: https://CRAN.R-project.org/package=doParallel
  license: GPL-2.0-only
  summary: Provides a parallel backend for the %dopar% function using the parallel package.
  license_family: GPL2
  license_file: {{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-2

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

# Package: doParallel
# Type: Package
# Title: Foreach Parallel Adaptor for the 'parallel' Package
# Version: 1.0.15
# Authors@R: c(person("Hong", "Ooi", role="cre", email="hongooi@microsoft.com"), person("Microsoft", "Corporation", role=c("aut", "cph")), person("Steve", "Weston", role="aut"), person("Dan", "Tenenbaum", role="ctb"))
# Description: Provides a parallel backend for the %dopar% function using the parallel package.
# Depends: R (>= 2.14.0), foreach(>= 1.2.0), iterators(>= 1.0.0), parallel, utils
# Suggests: caret, mlbench, rpart, RUnit
# Enhances: compiler
# License: GPL-2
# NeedsCompilation: no
# Packaged: 2019-07-16 22:51:14 UTC; richcala
# Author: Hong Ooi [cre], Microsoft Corporation [aut, cph], Steve Weston [aut], Dan Tenenbaum [ctb]
# Maintainer: Hong Ooi <hongooi@microsoft.com>
# Repository: CRAN
# Date/Publication: 2019-08-02 04:40:02 UTC
