{% set version = '0.4.6' %}

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

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

source:
  url:
    - {{ cran_mirror }}/src/contrib/cpp11_{{ version }}.tar.gz
    - {{ cran_mirror }}/src/contrib/Archive/cpp11/cpp11_{{ version }}.tar.gz
  sha256: d1c56954671d3398078ad52aaa4efce0864e8166465c8c5e5e9a1e40599055b3

build:
  merge_build_host: True  # [win]
  # If this is a new build for the same version, increment the build number.
  number: 0
  # no skip
  noarch: generic

  # This is required to make R link correctly on Linux.
  rpaths:
    - lib/R/lib/
    - lib/

# Suggests: bench, brio, callr, cli, covr, decor, desc, ggplot2, glue, knitr, lobstr, mockery, progress, rmarkdown, scales, Rcpp, testthat, tibble, utils, vctrs, withr
requirements:
  build:
    - {{ posix }}zip               # [win]

  host:
    - r-base

  run:
    - r-base

test:
  commands:
    # You can put additional test commands to be run here.
    - $R -e "library('cpp11')"           # [not win]
    - "\"%R%\" -e \"library('cpp11')\""  # [win]

  # You can also put a file called run_test.py, run_test.sh, or run_test.bat
  # in the recipe that will be run at test time.

  # requires:
    # Put any additional test requirements here.

about:
  home: https://cpp11.r-lib.org, https://github.com/r-lib/cpp11
  license: MIT
  summary: Provides a header only, C++11 interface to R's C interface.  Compared to other approaches
    'cpp11' strives to be safe against long jumps from the C API as well as C++ exceptions,
    conform to normal R function semantics and supports interaction with 'ALTREP' vectors.
  license_family: MIT
  license_file:
    - '{{ environ["PREFIX"] }}/lib/R/share/licenses/MIT'
    - LICENSE

# The original CRAN metadata for this package was:

# Package: cpp11
# Title: A C++11 Interface for R's C Interface
# Version: 0.4.6
# Authors@R: c( person("Davis", "Vaughan", email = "davis@posit.co", role = c("aut", "cre"), comment = c(ORCID = "0000-0003-4777-038X")), person("Jim","Hester", role = "aut", comment = c(ORCID = "0000-0002-2739-7082")), person("Romain", "Francois", role = "aut", comment = c(ORCID = "0000-0002-2444-4226")), person("Benjamin", "Kietzman", role = "ctb"), person("Posit Software, PBC", role = c("cph", "fnd")) )
# Description: Provides a header only, C++11 interface to R's C interface.  Compared to other approaches 'cpp11' strives to be safe against long jumps from the C API as well as C++ exceptions, conform to normal R function semantics and supports interaction with 'ALTREP' vectors.
# License: MIT + file LICENSE
# URL: https://cpp11.r-lib.org, https://github.com/r-lib/cpp11
# BugReports: https://github.com/r-lib/cpp11/issues
# Depends: R (>= 3.5.0)
# Suggests: bench, brio, callr, cli, covr, decor, desc, ggplot2, glue, knitr, lobstr, mockery, progress, rmarkdown, scales, Rcpp, testthat, tibble, utils, vctrs, withr
# VignetteBuilder: knitr
# Config/Needs/website: tidyverse/tidytemplate
# Config/testthat/edition: 3
# Config/Needs/cpp11/cpp_register: brio, cli, decor, desc, glue, tibble, vctrs
# Encoding: UTF-8
# RoxygenNote: 7.2.3
# NeedsCompilation: no
# Packaged: 2023-08-08 21:27:43 UTC; davis
# Author: Davis Vaughan [aut, cre] (<https://orcid.org/0000-0003-4777-038X>), Jim Hester [aut] (<https://orcid.org/0000-0002-2739-7082>), Romain Francois [aut] (<https://orcid.org/0000-0002-2444-4226>), Benjamin Kietzman [ctb], Posit Software, PBC [cph, fnd]
# Maintainer: Davis Vaughan <davis@posit.co>
# Repository: CRAN
# Date/Publication: 2023-08-10 06:50:07 UTC

# See
# https://docs.conda.io/projects/conda-build for
# more information about meta.yaml
