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

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/gsl_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/gsl/gsl_{{ version }}.tar.gz
  sha256: f5d463239693f146617018987687db31b163653708cbae0b730b9b7bed81995c

build:
  merge_build_host: True  # [win]
  number: 3
  rpaths:
    - lib/R/lib/
    - lib/

requirements:
  build:
    - {{ compiler('c') }}              # [not win]
    - {{ compiler('m2w64_c') }}        # [win]
    - {{ posix }}filesystem        # [win]
    - {{ posix }}sed               # [win]
    - {{ posix }}grep              # [win]
    - {{ posix }}autoconf
    - {{ posix }}automake          # [not win]
    - {{ posix }}automake-wrapper  # [win]
    - {{ posix }}pkg-config
    - {{ posix }}make
    - {{ posix }}coreutils         # [win]
    - {{ posix }}zip               # [win]
  host:
    - r-base
    - {{ native }}gsl             # [win]
    - gsl                       # [not win]
  run:
    - r-base
    - {{ native }}gsl             # [win]
    - gsl                       # [not win]
    - {{ native }}gcc-libs        # [win]

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

about:
  home: https://github.com/RobinHankin/gsl.git
  license: GPL-3
  summary: ' An R wrapper for some of the functionality of the Gnu Scientific Library.'
  license_family: GPL3
  license_file: '{{ environ["PREFIX"] }}/lib/R/share/licenses/GPL-3'

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

# Package: gsl
# Version: 2.1-6
# Depends: R (>= 3.1.0)
# Title: Wrapper for the Gnu Scientific Library
# Authors@R: c(person(given=c("Robin", "K. S."), family="Hankin", role = c("aut","cre"), email="hankin.robin@gmail.com", comment = c(ORCID = "0000-0001-5982-0415")), person(given="Andrew",family="Clausen",role="ctb",comment="multimin functionality"), person(given="Duncan",family="Murdoch",role="ctb",comment="qrng functions"))
# SystemRequirements: Gnu Scientific Library version >= 2.1
# Description:  An R wrapper for some of the functionality of the Gnu Scientific Library.
# Maintainer: Robin K. S. Hankin <hankin.robin@gmail.com>
# License: GPL-3
# URL: https://github.com/RobinHankin/gsl.git
# BugReports: https://github.com/RobinHankin/gsl/issues
# NeedsCompilation: yes
# Packaged: 2019-03-25 00:29:54 UTC; rhankin
# Author: Robin K. S. Hankin [aut, cre] (<https://orcid.org/0000-0001-5982-0415>), Andrew Clausen [ctb] (multimin functionality), Duncan Murdoch [ctb] (qrng functions)
# Repository: CRAN
# Date/Publication: 2019-03-25 09:10:03 UTC
