mirror of
https://github.com/BioArchLinux/Packages.git
synced 2025-03-10 12:02:42 +00:00
r-metabma: fix compilation, use metadata checks
This commit is contained in:
parent
16055089c5
commit
8ce868900a
3 changed files with 58 additions and 43 deletions
|
@ -1,46 +1,57 @@
|
|||
# system requirements: GNU make
|
||||
# Maintainer: sukanka <su975853527@gmail.com>
|
||||
# Maintainer: Pekka Ristola <pekkarr [at] protonmail [dot] com>
|
||||
# Contributor: sukanka <su975853527@gmail.com>
|
||||
|
||||
_pkgname=metaBMA
|
||||
_pkgver=0.6.7
|
||||
_pkgver=0.6.9
|
||||
pkgname=r-${_pkgname,,}
|
||||
pkgver=0.6.7
|
||||
pkgrel=6
|
||||
pkgdesc='Bayesian Model Averaging for Random and Fixed Effects Meta-Analysis'
|
||||
arch=('x86_64')
|
||||
pkgver=${_pkgver//-/.}
|
||||
pkgrel=0
|
||||
pkgdesc="Bayesian Model Averaging for Random and Fixed Effects Meta-Analysis"
|
||||
arch=(x86_64)
|
||||
url="https://cran.r-project.org/package=${_pkgname}"
|
||||
license=('GPL')
|
||||
license=(GPL3)
|
||||
depends=(
|
||||
r
|
||||
r-bh
|
||||
r-bridgesampling
|
||||
r-coda
|
||||
r-laplacesdemon
|
||||
r-logspline
|
||||
r-mvtnorm
|
||||
r-rcpp
|
||||
r-rcppeigen
|
||||
r-rcppparallel
|
||||
r-rstan
|
||||
r-rstantools
|
||||
)
|
||||
makedepends=(
|
||||
r-bh
|
||||
r-rcppeigen
|
||||
r-stanheaders
|
||||
)
|
||||
checkdepends=(
|
||||
r-testthat
|
||||
)
|
||||
optdepends=(
|
||||
r-knitr
|
||||
r-rmarkdown
|
||||
r-spelling
|
||||
r-testthat
|
||||
)
|
||||
makedepends=('make')
|
||||
source=("https://cran.r-project.org/src/contrib/${_pkgname}_${_pkgver}.tar.gz")
|
||||
sha256sums=('330bccb4b2297bc3a8b7291197c5e978b90b002907f762ede40f2d3e383367da')
|
||||
md5sums=('0eb28a09739c53d68ecd1c72101b5746')
|
||||
sha256sums=('c1e43fdc4c866a065c11bfa65b9f895256d0a11a19861c5212fbd4f82a6205f8')
|
||||
|
||||
build() {
|
||||
R CMD INSTALL ${_pkgname}_${_pkgver}.tar.gz -l "${srcdir}"
|
||||
mkdir -p build
|
||||
# compilation needs a lot of memory
|
||||
MAKEFLAGS+=" -j1"
|
||||
R CMD INSTALL "$_pkgname" -l build
|
||||
}
|
||||
|
||||
check() {
|
||||
cd "$_pkgname/tests"
|
||||
R_LIBS="$srcdir/build" NOT_CRAN=true Rscript --vanilla testthat.R
|
||||
}
|
||||
|
||||
package() {
|
||||
install -dm0755 "${pkgdir}/usr/lib/R/library"
|
||||
cp -a --no-preserve=ownership "${_pkgname}" "${pkgdir}/usr/lib/R/library"
|
||||
install -d "$pkgdir/usr/lib/R/library"
|
||||
cp -a --no-preserve=ownership "build/$_pkgname" "$pkgdir/usr/lib/R/library"
|
||||
}
|
||||
# vim:set ts=2 sw=2 et:
|
||||
|
|
|
@ -1,17 +1,17 @@
|
|||
#!/usr/bin/env python3
|
||||
from lilaclib import *
|
||||
|
||||
# we use 5 threads in BioArchLinux, but it should not be pushed to aur.
|
||||
import os
|
||||
import sys
|
||||
sys.path.append(os.path.normpath(f'{__file__}/../../../lilac-extensions'))
|
||||
from lilac_r_utils import r_pre_build
|
||||
|
||||
def pre_build():
|
||||
for line in edit_file('PKGBUILD'):
|
||||
if line.startswith('_pkgver='):
|
||||
line = f'_pkgver={_G.newver}'
|
||||
elif line.startswith('build()'):
|
||||
line += '\n' + 'export MAKE="make -j5"'
|
||||
print(line)
|
||||
update_pkgver_and_pkgrel(_G.newver.replace(':', '.').replace('-', '.'))
|
||||
r_pre_build(
|
||||
_G,
|
||||
expect_systemrequirements = "GNU make",
|
||||
)
|
||||
|
||||
def post_build():
|
||||
run_cmd(['sh', '-c', "sed -i '/export MAKE/d' PKGBUILD"])
|
||||
git_pkgbuild_commit()
|
||||
update_aur_repo()
|
||||
|
|
|
@ -1,21 +1,25 @@
|
|||
build_prefix: extra-x86_64
|
||||
maintainers:
|
||||
- github: sukanka
|
||||
- github: pekkarr
|
||||
email: pekkarr@protonmail.com
|
||||
repo_depends:
|
||||
- r-bh
|
||||
- r-bridgesampling
|
||||
- r-coda
|
||||
- r-laplacesdemon
|
||||
- r-logspline
|
||||
- r-mvtnorm
|
||||
- r-rcpp
|
||||
- r-rcppeigen
|
||||
- r-rcppparallel
|
||||
- r-rstan
|
||||
- r-rstantools
|
||||
- r-stanheaders
|
||||
- r-bridgesampling
|
||||
- r-coda
|
||||
- r-laplacesdemon
|
||||
- r-logspline
|
||||
- r-mvtnorm
|
||||
- r-rcpp
|
||||
- r-rcppparallel
|
||||
- r-rstan
|
||||
- r-rstantools
|
||||
repo_makedepends:
|
||||
- r-bh
|
||||
- r-rcppeigen
|
||||
- r-stanheaders
|
||||
- r-testthat
|
||||
update_on:
|
||||
- regex: metaBMA_([\d._-]+).tar.gz
|
||||
source: regex
|
||||
url: https://cran.r-project.org/package=metaBMA
|
||||
- alias: r
|
||||
- source: rpkgs
|
||||
pkgname: metaBMA
|
||||
repo: cran
|
||||
md5: true
|
||||
- alias: r
|
||||
|
|
Loading…
Add table
Reference in a new issue