summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorChristoph Fink2023-03-26 19:00:25 +0300
committerChristoph Fink2023-03-26 19:00:25 +0300
commit3f44bc259da959f0d38e1108255451ec3ad0d57a (patch)
treed3af51dccfef57dc9cdaf04cd925505d8325358e /PKGBUILD
parenteec224c11ba5118b5b9bee0f6d38e0d5c0ea19ee (diff)
downloadaur-3f44bc259da959f0d38e1108255451ec3ad0d57a.tar.gz
upgpkg: r-munsell 0.5.0-4
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD36
1 files changed, 25 insertions, 11 deletions
diff --git a/PKGBUILD b/PKGBUILD
index f8cd7cd8a17e..90fa1476fece 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -9,7 +9,7 @@ pkgdesc="Utilities for Using Munsell Colours"
url="https://cran.r-project.org/package=${_cranname}"
license=("MIT")
pkgver=${_cranver//[:-]/.}
-pkgrel=3
+pkgrel=4
arch=("any")
depends=(
@@ -19,28 +19,42 @@ depends=(
optdepends=(
"r-ggplot2"
)
-checkdepends=(
- "${optdepends[@]}"
- "r-testthat"
-)
+
+# The unittests for `r-munsell` have multiple circular
+# dependency chains.
+
+# As such, the tests can not be run on first build.
+# While R packages from CRAN, generally, are well-tested
+# before they are released, in some situations, you want to
+# have thorough testing on your own end.
+
+# To run the tests, first build this package without `check()`
+# (i.e., as-is) to bootstrap `r-munsell`. Then, on subsequent builds,
+# (assumining you have a local repository that is accessible from
+# the build chroot), uncomment the lines defining `checkdepends`, below,
+# as well as the `check()` function further down
+
+# checkdepends=(
+# "${optdepends[@]}"
+# "r-testthat"
+# )
source=("https://cran.r-project.org/src/contrib/${_cranname}_${_cranver}.tar.gz")
-b2sums=('534463ce90f276b5fb3c874fadd882b1f824cef7b8ba1a7817994a1949d312fc85acf7893df03ca11403e0d20b2b3223e606ee2a92b8d735904b37f41b2706f3')
+b2sums=("534463ce90f276b5fb3c874fadd882b1f824cef7b8ba1a7817994a1949d312fc85acf7893df03ca11403e0d20b2b3223e606ee2a92b8d735904b37f41b2706f3")
build() {
mkdir -p "${srcdir}/build/"
R CMD INSTALL ${_cranname}_${_cranver}.tar.gz -l "${srcdir}/build/"
}
-check() {
- cd "${srcdir}/${_cranname}/tests"
- R_LIBS="${srcdir}/build/" Rscript --vanilla testthat.R
-}
+# check() {
+# export R_LIBS="build/"
+# R CMD check --no-manual "${_cranname}"
+# }
package() {
install -dm0755 "${pkgdir}/usr/lib/R/library"
cp -a --no-preserve=ownership "${srcdir}/build/${_cranname}" "${pkgdir}/usr/lib/R/library"
-
if [[ -f "${_cranname}/LICENSE" ]]; then
install -Dm0644 "${_cranname}/LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
fi