check_mdrb()
returns a boolean indicating whether a suitable version of the
metabodecon Rust backend mdrb is
currently installed.
check_mdrb_deps()
returns a list with information about the
installation status of mdrb system dependencies.
Value
check_mdrb()
returns TRUE if a suitable version of mdrb is installed,
else FALSE.
check_mdrb_deps()
returns a data.frame as follows:
check passed comment
r R >= 4.2 TRUE Current: R 4.4.2
rtools Rtools exist TRUE Tested with: pkgbuild::has_build_tools()
cargo cargo >= 1.80 TRUE Current: cargo 1.84.1 (66221abde 2024-11-19)
rustc rustc >= 1.80 TRUE Current: rustc 1.84.1 (e71f9a9a9 2025-01-27)
Column check
is a string describing the performed check.
Column passed
is a boolean indicating whether the check passed.
Column comment
is a string string describing the check result.
The rownames of the dataframe one-word descriptions of the performed checks.
Examples
check_mdrb()
#> [1] TRUE
# \donttest{
# Checking dependencies might take more than 5 seconds, as it
# requires the compilation of a small test program as well as
# running `cargo --version` and `rustc --version`, which,
# depending on your system, might involve updating or installing
# Rust toolchain components.
check_mdrb_deps(verbose = TRUE)
#> 2025-09-14 15:40:43.35 Checking R version...
#> 2025-09-14 15:40:43.35 Checking if buildtools exist...
#> Trying to compile a simple C file
#> Running /opt/R/4.5.1/lib/R/bin/R CMD SHLIB foo.c
#> using C compiler: ‘gcc (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0’
#> gcc -std=gnu2x -I"/opt/R/4.5.1/lib/R/include" -DNDEBUG -I/usr/local/include -fpic -g -O2 -c foo.c -o foo.o
#> gcc -std=gnu2x -shared -L/opt/R/4.5.1/lib/R/lib -L/usr/local/lib -o foo.so foo.o -L/opt/R/4.5.1/lib/R/lib -lR
#>
#> 2025-09-14 15:40:43.52 Checking cargo version...
#> 2025-09-14 15:40:44.64 Checking rustc version...
#> 2025-09-14 15:40:45.94 Done
#> check passed comment
#> r R >= 4.2 TRUE Current: R 4.5.1
#> rtools Rtools exist TRUE Testcall: pkgbuild::has_build_tools()
#> cargo cargo >= 1.80 TRUE Current: cargo 1.89.0 (c24e10642 2025-06-23)
#> rustc rustc >= 1.80 TRUE Current: rustc 1.89.0 (29483883e 2025-08-04)
# }