use pak devel, test platform auto-detection
This commit is contained in:
parent
e0395b5509
commit
df583bcf37
7 changed files with 13 additions and 12 deletions
|
|
@ -30,7 +30,7 @@ steps:
|
|||
image: busybox:latest
|
||||
failure: ignore
|
||||
commands:
|
||||
- sleep 200
|
||||
- sleep 10
|
||||
- echo "Warmed Up"
|
||||
|
||||
backend_options:
|
||||
|
|
|
|||
|
|
@ -22,15 +22,15 @@ install_package_system_dependencies <- function(package_name,
|
|||
}
|
||||
|
||||
cli::cli_alert("{.fun install_package_system_dependencies}: Installing R package dependencies for {.pkg {package_name[1]}} with tag {.field {tail(tag, 1)}}.")
|
||||
Sys.setenv(PKG_SYSREQS_PLATFORM = platform)
|
||||
# Sys.setenv(PKG_SYSREQS_PLATFORM = platform)
|
||||
Sys.setenv(PKG_SYSREQS = TRUE)
|
||||
Sys.setenv(PKG_SYSREQS_VERBOSE = TRUE)
|
||||
# FIXME: https://github.com/r-lib/pak/issues/610
|
||||
if (grepl("rhel-9", pak::system_r_platform())) {
|
||||
Sys.setenv(PKG_SYSREQS_PLATFORM = "redhat-9")
|
||||
} else if (grepl("rhel-9", pak::system_r_platform())) {
|
||||
Sys.setenv(PKG_SYSREQS_PLATFORM = "redhat-8")
|
||||
}
|
||||
# if (grepl("rhel-9", pak::system_r_platform())) {
|
||||
# Sys.setenv(PKG_SYSREQS_PLATFORM = "redhat-9")
|
||||
# } else if (grepl("rhel-9", pak::system_r_platform())) {
|
||||
# Sys.setenv(PKG_SYSREQS_PLATFORM = "redhat-8")
|
||||
# }
|
||||
if (deps_verbose) {
|
||||
pak::local_install_deps(sprintf("%s", local_clone_dir_single))
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -33,7 +33,8 @@ RUN apk add -q --no-cache R-dev curl ca-certificates bash g++ tzdata openjdk17 t
|
|||
# https://github.com/RcppCore/Rcpp/issues/448#issuecomment-220148774
|
||||
# LDFLAGS+=-fPIC -> arrow (https://github.com/r-hub/r-minimal/blob/main/examples/arrow/Dockerfile)
|
||||
# dbarts: CFLAGS += -flax-vector-conversions (https://github.com/vdorie/dbarts/issues/66)
|
||||
RUN mkdir -p /root/.R && bash -c 'echo -e "CXX_STD = CXX14\nCFLAGS += -flax-vector-conversions\nLDFLAGS+=-fPIC\nCC=ccache gcc\nCPP=ccache gcc\nCXX=ccache g++\nCXX11=ccache g++\nCXX14=ccache g++\nCXX17=ccache g++\nF77=ccache /usr/bin/gfortran\nFC=ccache /usr/bin/gfortran" >> /root/.R/Makevars'
|
||||
# CXXFLAGS: -> Rcpp
|
||||
RUN mkdir -p /root/.R && bash -c 'echo -e "CXX_STD = CXX14\nCXXFLAGS=-D__MUSL__\nCPPFLAGS=-D__MUSL__\nCFLAGS += -flax-vector-conversions\nLDFLAGS+=-fPIC\nCC=ccache gcc\nCPP=ccache gcc\nCXX=ccache g++\nCXX11=ccache g++\nCXX14=ccache g++\nCXX17=ccache g++\nF77=ccache /usr/bin/gfortran\nFC=ccache /usr/bin/gfortran" > /root/.R/Makevars'
|
||||
|
||||
# R repos
|
||||
RUN bash -c 'echo -e "options(crayon.enabled = TRUE, Ncpus = ${NCPUS}, future.globals.onReference = NULL, repos = structure(c(CRAN = \"https://cloud.r-project.org\", INLA = \"https://inla.r-inla-download.org/R/stable\")))" > /root/.Rprofile'
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ RUN curl -q -L -O https://sourceforge.net/projects/mcmc-jags/files/JAGS/4.x/Sour
|
|||
### INSTALL R
|
||||
RUN curl -O "https://devxy-r-builds.s3.eu-central-2.amazonaws.com/el8/R-${R_VERSION}-1-1.$(arch).rpm"
|
||||
RUN dnf install -q -y "R-${R_VERSION}-1-1.$(arch).rpm" && rm "R-${R_VERSION}-1-1.$(arch).rpm"
|
||||
RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/pak/stable/%s/%s/%s", .Platform$pkgType, R.Version()$os, R.Version()$arch))'
|
||||
RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/pak/devel/%s/%s/%s", .Platform$pkgType, R.Version()$os, R.Version()$arch))'
|
||||
|
||||
### Makevars
|
||||
# dbarts: CFLAGS += -flax-vector-conversions (https://github.com/vdorie/dbarts/issues/66)
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ RUN curl -q -L -O https://sourceforge.net/projects/mcmc-jags/files/JAGS/4.x/Sour
|
|||
### INSTALL R
|
||||
RUN curl -O "https://devxy-r-builds.s3.eu-central-2.amazonaws.com/el9/R-${R_VERSION}-1-1.$(arch).rpm"
|
||||
RUN dnf install -q -y "R-${R_VERSION}-1-1.$(arch).rpm" && rm "R-${R_VERSION}-1-1.$(arch).rpm"
|
||||
RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/pak/stable/%s/%s/%s", .Platform$pkgType, R.Version()$os, R.Version()$arch))'
|
||||
RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/pak/devel/%s/%s/%s", .Platform$pkgType, R.Version()$os, R.Version()$arch))'
|
||||
|
||||
### Makevars
|
||||
# dbarts: CFLAGS += -flax-vector-conversions (https://github.com/vdorie/dbarts/issues/66)
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ RUN curl -q -L -O https://sourceforge.net/projects/mcmc-jags/files/JAGS/4.x/Sour
|
|||
### INSTALL R
|
||||
RUN curl -O "https://devxy-r-builds.s3.eu-central-2.amazonaws.com/2204/r-${R_VERSION}_1_$(dpkg --print-architecture).deb"
|
||||
RUN gdebi -n -qq "r-${R_VERSION}_1_$(dpkg --print-architecture).deb" && rm "r-${R_VERSION}_1_$(dpkg --print-architecture).deb"
|
||||
RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/pak/stable/%s/%s/%s", .Platform$pkgType, R.Version()$os, R.Version()$arch))'
|
||||
RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/pak/devel/%s/%s/%s", .Platform$pkgType, R.Version()$os, R.Version()$arch))'
|
||||
|
||||
### Makevars
|
||||
# dbarts: CFLAGS += -flax-vector-conversions (https://github.com/vdorie/dbarts/issues/66)
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ RUN curl -q -L -O https://sourceforge.net/projects/mcmc-jags/files/JAGS/4.x/Sour
|
|||
### INSTALL R
|
||||
RUN curl -O "https://devxy-r-builds.s3.eu-central-2.amazonaws.com/2404/r-${R_VERSION}_1_$(dpkg --print-architecture).deb"
|
||||
RUN gdebi -n -qq "r-${R_VERSION}_1_$(dpkg --print-architecture).deb" && rm "r-${R_VERSION}_1_$(dpkg --print-architecture).deb"
|
||||
RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/pak/stable/%s/%s/%s", .Platform$pkgType, R.Version()$os, R.Version()$arch))'
|
||||
RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/pak/devel/%s/%s/%s", .Platform$pkgType, R.Version()$os, R.Version()$arch))'
|
||||
|
||||
### Makevars
|
||||
# dbarts: CFLAGS += -flax-vector-conversions (https://github.com/vdorie/dbarts/issues/66)
|
||||
|
|
|
|||
Loading…
Reference in a new issue