{% set version = '0.2-4' %}

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

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

source:
  fn: CircStats_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/CircStats_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/CircStats/CircStats_{{ version }}.tar.gz
  sha256: 7a00032dee1e9f06e825eca353e2fd6633da47ed58688194ca83a07b6f7057b8

build:
  number: 0
  script: R CMD INSTALL --build .
  skip: True  # [win32]
  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - r-base
    - r-mass
    - r-boot

  run:
    - r-base
    - r-mass
    - r-boot

test:
  commands:
    - $R -e "library('CircStats')"  # [not win]
    - "\"%R%\" -e \"library('CircStats')\""  # [win]
    - conda inspect linkages -p $PREFIX r-circstats  # [not win]
    - conda inspect objects -p $PREFIX r-circstats  # [osx]

about:
  home: S-plus original at http://statweb.calpoly.edu/lund/
  license: GPL-2
  summary: Circular Statistics, from "Topics in circular Statistics" (2001) S. Rao Jammalamadaka
    and A. SenGupta, World Scientific.
  license_family: GPL2

extra:
  recipe-maintainers:
    - jsignell
