{% set version = "2018.05.22" %}

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

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

source:
  fn: directlabels_{{ version }}.tar.gz
  url:
    - https://cran.r-project.org/src/contrib/directlabels_{{ version }}.tar.gz
    - https://cran.r-project.org/src/contrib/Archive/directlabels/directlabels_{{ version }}.tar.gz
  sha256: 9b2e780410bc7812fe155afba9181653293ca657b0b10e1618242dad4d619775

build:
  number: 1
  skip: true  # [win32]

  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - r-base
    - r-quadprog

  run:
    - r-base
    - r-quadprog

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

about:
  home: http://directlabels.r-forge.r-project.org/
  license: GPL-3
  license_family: GPL3
  license_file: '{{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-3'  # [unix]
  license_file: '{{ environ["PREFIX"] }}\R\share\licenses\GPL-3'  # [win]
  summary: An extensible framework for automatically placing direct labels onto multicolor 'lattice'
    or 'ggplot2' plots. Label positions are described using Positioning Methods which
    can be re-used across several different plots. There are heuristics for examining
    "trellis" and "ggplot" objects and inferring an appropriate Positioning Method.

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