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

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/forestFloor_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/forestFloor/forestFloor_{{ version }}.tar.gz
  sha256: 87dbc3646c38c8f3051f9eeed08f3b54f02429fa0b0074326cb5564c08ee54eb

build:
  skip: True              # [osx]
  merge_build_host: True  # [win]
  number: 2
  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - {{ compiler('c') }}              # [not win]
    - {{ compiler('m2w64_c') }}        # [win]
    - {{ compiler('cxx') }}            # [not win]
    - {{ compiler('m2w64_cxx') }}      # [win]
    - {{ posix }}filesystem              # [win]
    - {{ posix }}make
    - {{ posix }}sed                     # [win]
    - {{ posix }}coreutils               # [win]
    - {{ posix }}zip                     # [win]
    - {{ cdt('mesa-libgl-devel') }}    # [linux]
    - {{ cdt('mesa-dri-drivers') }}    # [linux]
    - {{ cdt('libxdamage') }}          # [linux]
    - {{ cdt('libxfixes') }}           # [linux]
    - {{ cdt('libxxf86vm') }}          # [linux]
  host:
    - r-base
    - r-rcpp >=0.11.3
    - r-kknn
    - r-randomforest
    - r-rgl

  run:
    - r-base
    - {{ native }}gcc-libs         # [win]
    - r-rcpp >=0.11.3
    - r-kknn
    - r-randomforest
    - r-rgl

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

about:
  home: http://forestFloor.dk
  license: GPL-2
  summary: Form visualizations of high dimensional mapping structures of random forests and feature
    contributions.
  license_family: GPL2
  license_file: '{{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-2'

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

# Package: forestFloor
# Type: Package
# Title: Visualizes Random Forests with Feature Contributions
# Version: 1.11.1
# Date: 2017-05-30
# Author: Soeren Havelund Welling
# Maintainer: Soeren Havelund Welling <SORHAWELL@GMAIL.COM>
# Depends:
# Suggests: caret, e1071
# Description: Form visualizations of high dimensional mapping structures of random forests and feature contributions.
# SystemRequirements: OpenGL, GLU Library, zlib
# License: GPL-2
# URL: http://forestFloor.dk
# Imports: Rcpp (>= 0.11.3), rgl, kknn, randomForest
# LinkingTo: Rcpp
# NeedsCompilation: yes
# Packaged: 2017-05-30 10:38:49 UTC; sowe
# Repository: CRAN
# Date/Publication: 2017-05-30 12:17:27 UTC
