{% set version = '1.1.14' %}

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

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

source:
  fn: biganalytics_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/biganalytics_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/biganalytics/biganalytics_{{ version }}.tar.gz
  sha256: 463184c23b68d469db2f780c97b9d4f37e28002e05d8cd6ffa46c309cb6b58c3

build:
  merge_build_host: True  # [win]
  number: 2
  skip: true  # [win32]

  rpaths:
    - lib/R/lib/
    - lib/
requirements:
  build:
    - posix                # [win]
    - {{ compiler('c') }}        # [unix]
    - {{ compiler('m2w64_c') }}  # [win]
    - {{ compiler('cxx') }}        # [unix]
    - {{ compiler('m2w64_cxx') }}  # [win]
  host:
    - r-base
    - r-bh
    - r-rcpp
    - r-biglm
    - r-bigmemory >=4.0.0
    - r-foreach

  run:
    - r-base
    - r-bh
    - r-rcpp
    - r-biglm
    - r-bigmemory >=4.0.0
    - r-foreach

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

about:
  home: http://www.bigmemory.org
  license: LGPL-3 | Apache 2.0
  summary: Extend the 'bigmemory' package with various analytics. Functions 'bigkmeans' and 'binit'
    may also be used with native R objects. For 'tapply'-like functions, the bigtabulate
    package may also be helpful. For linear algebra support, see 'bigalgebra'.  For
    mutex (locking) support for advanced shared-memory usage, see 'synchronicity'.
  license_family: LGPL

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