add fftw to all images

This commit is contained in:
Patrick Schratz 2024-09-15 23:32:59 +02:00
commit 833fa910d4
Signed by: pat-s
GPG key ID: 3C6318841EF78925
5 changed files with 24 additions and 10 deletions

View file

@ -28,13 +28,15 @@ RUN apk del lapack lapack-dev
# libxml2-dev: xml2
# libgit2-dev: gert
# libpq-dev: RPostgres
RUN apk add -q --no-cache R-dev curl ca-certificates bash g++ tzdata openjdk17 tar sed patch openblas-dev pkgconfig linux-headers ccache libxml2-dev libgit2-dev libpq-dev pkgconfig
# libfftw3-dev: ravetools -> actually auto-detect but somehow doesn't work in container?
RUN apk add -q --no-cache R-dev curl ca-certificates bash g++ tzdata openjdk17 tar sed patch openblas-dev pkgconfig linux-headers ccache libxml2-dev libgit2-dev libpq-dev pkgconfig fftw-dev
# 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)
# 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=gcc -E\nCXXCPP=gcc -e\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'
# can't set ccache for gfortran because of https://gitlab.com/roigrp/solver/highs/-/issues/4
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=gcc -E\nCXXCPP=gcc -e\nCXX=ccache g++\nCXX11=ccache g++\nCXX14=ccache g++\nCXX17=ccache g++\nF77=gfortran\nFC=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'

View file

@ -18,7 +18,9 @@ RUN subscription-manager register --username mail@devxy.io --password "$RED_HAT_
RUN dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm && dnf install -y epel-release
# xvfb: for graphical pkgs requiring tcl, like gWidgets2tcltk
# ImageMagick-c++-devel ImageMagick-devel: boths are not auto-installed via pak sysreqs
RUN dnf install -y -q make lapack-devel git gcc gcc-c++ fontconfig-devel fribidi-devel libjpeg-turbo-devel libtiff-devel postgresql-devel htop libgit2-devel libxml2-devel hiredis ccache cmake xorg-x11-server-Xvfb ImageMagick-c++-devel ImageMagick-devel xz pkg-config
# mecab-devel: RcppMeCab -> no autodetection yet
# libfftw3-dev: ravetools -> actually auto-detect but somehow doesn't work in container?
RUN dnf install -y -q make lapack-devel git gcc gcc-c++ fontconfig-devel fribidi-devel libjpeg-turbo-devel libtiff-devel postgresql-devel htop libgit2-devel libxml2-devel hiredis ccache cmake xorg-x11-server-Xvfb ImageMagick-c++-devel ImageMagick-devel xz pkg-config mecab-devel fftw-devel
### CUSTOM DEPENDENCIES
# These usually are not packaged in OS repositories and need to be installed from source
@ -32,7 +34,8 @@ RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/
### Makevars
# 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\nCC=ccache gcc\nCPP=gcc -E\nCXXCPP=gcc -e\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'
# can't set ccache for gfortran because of https://gitlab.com/roigrp/solver/highs/-/issues/4
RUN mkdir -p /root/.R && bash -c 'echo -e "CXX_STD = CXX14\nCFLAGS += -flax-vector-conversions\nCC=ccache gcc\nCPP=gcc -E\nCXXCPP=gcc -e\nCXX=ccache g++\nCXX11=ccache g++\nCXX14=ccache g++\nCXX17=ccache g++\nF77=gfortran\nFC=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'

View file

@ -18,7 +18,9 @@ RUN subscription-manager register --username mail@devxy.io --password "$RED_HAT_
RUN dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm && dnf install -y epel-release
# xvfb: for graphical pkgs requiring tcl, like gWidgets2tcltk
# ImageMagick-c++-devel ImageMagick-devel: boths are not auto-installed via pak sysreqs
RUN dnf install -y -q make lapack-devel git gcc gcc-c++ fontconfig-devel fribidi-devel libjpeg-turbo-devel libtiff-devel postgresql-devel htop libgit2-devel libxml2-devel hiredis ccache cmake xorg-x11-server-Xvfb tk-devel ImageMagick-c++-devel ImageMagick-devel xz pkg-config
# mecab-devel: RcppMeCab -> no autodetection yet
# libfftw3-dev: ravetools -> actually auto-detect but somehow doesn't work in container?
RUN dnf install -y -q make lapack-devel git gcc gcc-c++ fontconfig-devel fribidi-devel libjpeg-turbo-devel libtiff-devel postgresql-devel htop libgit2-devel libxml2-devel hiredis ccache cmake xorg-x11-server-Xvfb tk-devel ImageMagick-c++-devel ImageMagick-devel xz pkg-config mecab-devel fftw-devel
### CUSTOM DEPENDENCIES
# These usually are not packaged in OS repositories and need to be installed from source
@ -32,7 +34,8 @@ RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/
### Makevars
# 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\nCC=ccache gcc\nCPP=gcc -E\nCXXCPP=gcc -e\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'
# can't set ccache for gfortran because of https://gitlab.com/roigrp/solver/highs/-/issues/4
RUN mkdir -p /root/.R && bash -c 'echo -e "CXX_STD = CXX14\nCFLAGS += -flax-vector-conversions\nCC=ccache gcc\nCPP=gcc -E\nCXXCPP=gcc -e\nCXX=ccache g++\nCXX11=ccache g++\nCXX14=ccache g++\nCXX17=ccache g++\nF77=gfortran\nFC=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'

View file

@ -16,7 +16,9 @@ ARG GITHUB_PAT
# xvfb: for graphical pkgs requiring tcl, like gWidgets2tcltk
# tcl tk tk-dev tk-table: must be available before running xvfb-run (i.e. starting the graphical session)
RUN apt update && apt install -y --no-install-recommends gdebi-core g++ gfortran libbz2-dev libblas-dev libicu-dev liblapack-dev liblzma-dev libpaper-utils libpcre2-dev libtcl8.6 libtk8.6 libxt6 unzip zip zlib1g-dev libpcre3-dev libopenblas-dev curl ca-certificates make ccache htop libgit2-dev git libpq-dev libxml2-dev libgit2-dev cmake xvfb libcurl4-openssl-dev xz-utils tcl tk tk-dev tk-table pkg-config
# libmecab-dev: RcppMeCab -> no autodetection yet
# libfftw3-dev: ravetools -> actually auto-detect but somehow doesn't work in container?
RUN apt update && apt install -y --no-install-recommends gdebi-core g++ gfortran libbz2-dev libblas-dev libicu-dev liblapack-dev liblzma-dev libpaper-utils libpcre2-dev libtcl8.6 libtk8.6 libxt6 unzip zip zlib1g-dev libpcre3-dev libopenblas-dev curl ca-certificates make ccache htop libgit2-dev git libpq-dev libxml2-dev libgit2-dev cmake xvfb libcurl4-openssl-dev xz-utils tcl tk tk-dev tk-table pkg-config libmecab-dev libfftw3-dev
### CUSTOM DEPENDENCIES
# These usually are not packaged in OS repositories and need to be installed from source
@ -30,7 +32,8 @@ RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/
### Makevars
# 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\nCC=ccache gcc\nCPP=gcc -E\nCXXCPP=gcc -e\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'
# can't set ccache for gfortran because of https://gitlab.com/roigrp/solver/highs/-/issues/4
RUN mkdir -p /root/.R && bash -c 'echo -e "CXX_STD = CXX14\nCFLAGS += -flax-vector-conversions\nCC=ccache gcc\nCPP=gcc -E\nCXXCPP=gcc -e\nCXX=ccache g++\nCXX11=ccache g++\nCXX14=ccache g++\nCXX17=ccache g++\nF77=gfortran\nFC=gfortran" >> /root/.R/Makevars'
# R repos
RUN bash -c 'echo -e "options(pkg.sysreqs_verbose = TRUE, 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\")))" > ~/.Rprofile'

View file

@ -16,7 +16,9 @@ ARG GITHUB_PAT
# xvfb: for graphical pkgs requiring tcl, like gWidgets2tcltk
# tcl tk tk-dev tk-table: must be available before running xvfb-run (i.e. starting the graphical session)
RUN apt update && apt install -y --no-install-recommends gdebi-core g++ gfortran libbz2-dev libblas-dev libicu-dev liblapack-dev liblzma-dev libpaper-utils libpcre2-dev libtcl8.6 libtk8.6 libxt6 unzip zip zlib1g-dev libpcre3-dev libopenblas-dev curl ca-certificates make ccache htop libgit2-dev git libpq-dev libxml2-dev libgit2-dev cmake xvfb libcurl4-openssl-dev xz-utils tcl tk tk-dev tk-table pkg-config
# libmecab-dev: RcppMeCab -> no autodetection yet
# libfftw3-dev: ravetools -> actually auto-detect but somehow doesn't work in container?
RUN apt update && apt install -y --no-install-recommends gdebi-core g++ gfortran libbz2-dev libblas-dev libicu-dev liblapack-dev liblzma-dev libpaper-utils libpcre2-dev libtcl8.6 libtk8.6 libxt6 unzip zip zlib1g-dev libpcre3-dev libopenblas-dev curl ca-certificates make ccache htop libgit2-dev git libpq-dev libxml2-dev libgit2-dev cmake xvfb libcurl4-openssl-dev xz-utils tcl tk tk-dev tk-table pkg-config libmecab-dev libfftw3-dev
### CUSTOM DEPENDENCIES
# These usually are not packaged in OS repositories and need to be installed from source
@ -30,7 +32,8 @@ RUN R -q -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/
### Makevars
# 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\nCC=ccache gcc\nCPP=gcc -E\nCXXCPP=gcc -e\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'
# can't set ccache for gfortran because of https://gitlab.com/roigrp/solver/highs/-/issues/4
RUN mkdir -p /root/.R && bash -c 'echo -e "CXX_STD = CXX14\nCFLAGS += -flax-vector-conversions\nCC=ccache gcc\nCPP=gcc -E\nCXXCPP=gcc -e\nCXX=ccache g++\nCXX11=ccache g++\nCXX14=ccache g++\nCXX17=ccache g++\nF77=gfortran\nFC=gfortran" >> /root/.R/Makevars'
# R repos
RUN bash -c 'echo -e "options(pkg.sysreqs_verbose = TRUE, 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\")))" > ~/.Rprofile'