r-*: use metadata checks for several packages

This commit is contained in:
Pekka Ristola 2024-02-20 17:31:54 +02:00
parent b2407fe678
commit fd2772ed94
No known key found for this signature in database
GPG key ID: 2C20BE716E05213E
9 changed files with 63 additions and 54 deletions

View file

@ -3,24 +3,25 @@
_pkgname=BiasedUrn
_pkgver=2.0.11
pkgname=r-${_pkgname,,}
pkgver=2.0.11
pkgver=${_pkgver//-/.}
pkgrel=1
pkgdesc='Biased Urn Model Distributions'
arch=('x86_64')
url="https://cran.r-project.org/package=${_pkgname}"
license=('GPL')
pkgdesc="Biased Urn Model Distributions"
arch=(x86_64)
url="https://cran.r-project.org/package=$_pkgname"
license=('GPL-3.0-only')
depends=(
r
)
source=("https://cran.r-project.org/src/contrib/${_pkgname}_${_pkgver}.tar.gz")
sha256sums=('6295f1a12cd9d425cc03ec05a993fba04f539007c1754f23d7043a585b9e7537')
md5sums=('435d436db9c8359cf99234f9468bfc78')
b2sums=('9351d7487088136a2edf64b54486cfe03d79a27807013c3be391bcaf6e293cc1c6c8e1ac2932a3dc54c8874387423d25c8d522e40f1911a63248c17e8d79b136')
build() {
R CMD INSTALL ${_pkgname}_${_pkgver}.tar.gz -l "${srcdir}"
mkdir build
R CMD INSTALL -l build "$_pkgname"
}
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:

View file

@ -1,12 +1,13 @@
#!/usr/bin/env python3
from lilaclib import *
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}'
print(line)
update_pkgver_and_pkgrel(_G.newver.replace(':', '.').replace('-', '.'))
r_pre_build(_G)
def post_build():
git_pkgbuild_commit()

View file

@ -3,7 +3,8 @@ maintainers:
- github: starsareintherose
email: kuoi@bioarchlinux.org
update_on:
- regex: BiasedUrn_([\d._-]+).tar.gz
source: regex
url: https://cran.r-project.org/package=BiasedUrn
- source: rpkgs
pkgname: BiasedUrn
repo: cran
md5: true
- alias: r

View file

@ -3,12 +3,12 @@
_pkgname=JASPAR2018
_pkgver=1.1.1
pkgname=r-${_pkgname,,}
pkgver=1.1.1
pkgver=${_pkgver//-/.}
pkgrel=6
pkgdesc='Data package for JASPAR 2018'
arch=('any')
url="https://bioconductor.org/packages/${_pkgname}"
license=('GPL')
pkgdesc="Data package for JASPAR 2018"
arch=(any)
url="https://bioconductor.org/packages/$_pkgname"
license=('GPL-2.0-only')
depends=(
r
)
@ -16,14 +16,15 @@ optdepends=(
r-tfbstools
)
source=("https://bioconductor.org/packages/release/data/annotation/src/contrib/${_pkgname}_${_pkgver}.tar.gz")
sha256sums=('87a22b2549eb6cd2f6db8692542fbb2a4aa1dc8bde9bd01b63022a9f435905c7')
md5sums=('d91fce6ea0dc9fa6a3be6ebc05c1af5d')
b2sums=('679990b0931d4e9e76f4dd4bc14fadb183caf8e9da225a86cebfeaf7d85954e3deb9d7d55ff1e8c0a6c21bd0941ebb86aa5f7c12b2a73508f907247e3f4c9eaf')
build() {
R CMD INSTALL ${_pkgname}_${_pkgver}.tar.gz -l "${srcdir}"
mkdir build
R CMD INSTALL -l build "$_pkgname"
}
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:

View file

@ -1,12 +1,13 @@
#!/usr/bin/env python3
from lilaclib import *
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}'
print(line)
update_pkgver_and_pkgrel(_G.newver.replace(':', '.').replace('-', '.'))
r_pre_build(_G)
def post_build():
git_pkgbuild_commit()

View file

@ -3,7 +3,8 @@ maintainers:
- github: starsareintherose
email: kuoi@bioarchlinux.org
update_on:
- regex: JASPAR2018_([\d._-]+).tar.gz
source: regex
url: https://bioconductor.org/packages/JASPAR2018
- source: rpkgs
pkgname: JASPAR2018
repo: bioc-data-annotation
md5: true
- alias: r

View file

@ -3,24 +3,25 @@
_pkgname=survivalROC
_pkgver=1.0.3.1
pkgname=r-${_pkgname,,}
pkgver=1.0.3.1
pkgver=${_pkgver//-/.}
pkgrel=2
pkgdesc='Time-dependent ROC curve estimation from censored survival data'
arch=('any')
url="https://cran.r-project.org/package=${_pkgname}"
license=('GPL')
pkgdesc="Time-Dependent ROC Curve Estimation from Censored Survival Data"
arch=(x86_64)
url="https://cran.r-project.org/package=$_pkgname"
license=('GPL-2.0-or-later')
depends=(
r
)
source=("https://cran.r-project.org/src/contrib/${_pkgname}_${_pkgver}.tar.gz")
sha256sums=('8174afebaf239dfda979c8c7e1e219624576d577c983ae787fbd2785b4ccd15c')
md5sums=('f902d8d1d91cbed98b43ca3cfb9cddaa')
b2sums=('b81a3a9b002fe63c793757bfd2f582c1a24257b0731290334c88751e9d03691f56031c87008c28675bb21ecb93c4775f2dd76c6b83411736e729307e2d13e44a')
build() {
R CMD INSTALL ${_pkgname}_${_pkgver}.tar.gz -l "${srcdir}"
mkdir build
R CMD INSTALL -l build "$_pkgname"
}
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:

View file

@ -1,12 +1,13 @@
#!/usr/bin/env python3
from lilaclib import *
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}'
print(line)
update_pkgver_and_pkgrel(_G.newver.replace(':', '.').replace('-', '.'))
r_pre_build(_G)
def post_build():
git_pkgbuild_commit()

View file

@ -3,7 +3,8 @@ maintainers:
- github: starsareintherose
email: kuoi@bioarchlinux.org
update_on:
- regex: survivalROC_([\d._-]+).tar.gz
source: regex
url: https://cran.r-project.org/package=survivalROC
- source: rpkgs
pkgname: survivalROC
repo: cran
md5: true
- alias: r