{% set version = '2014.11-1' %}

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

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

source:
  fn: GPArotation_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/GPArotation_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/GPArotation/GPArotation_{{ version }}.tar.gz
  sha256: 351bc15fc8dc6c8ea5045fbba22180d1e68314fc34d267545687748e312e5096

build:
  number: 0
  skip: true  # [win32]
  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - r-base

  run:
    - r-base

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

about:
  home: http://www.stat.ucla.edu/research/gpa
  license: GPL (>= 2)
  summary: Gradient Projection Algorithm Rotation for Factor Analysis. See ?GPArotation.Intro
    for more details.
  license_family: GPL3
  license_file: '{{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-3'  # [unix]
  license_file: '{{ environ["PREFIX"] }}\R\share\licenses\GPL-3'  # [win]

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