rocker-org / rocker-versioned

Run current & prior versions of R using docker
https://hub.docker.com/r/rocker/r-ver
GNU General Public License v2.0
297 stars 169 forks source link

`rocker/verse` does not run `tcltk` #262

Closed isaactpetersen closed 3 years ago

isaactpetersen commented 3 years ago

I am running the latest Docker image of rocker/verse on Ubuntu 20.04.2 LTS using a GitLab runner. When I try to load the package predictABEL in R 4.1.1, I receive the following error:

> library("PredictABEL")
Error: package or namespace load failed for 'PredictABEL':
.onLoad failed in loadNamespace() for 'tcltk', details:
call: dyn.load(file, DLLpath = DLLpath, ...)
error: unable to load shared object '/usr/local/lib/R/library/tcltk/libs/tcltk.so':
libtcl8.6.so: cannot open shared object file: No such file or directory

I verified that I am able to load other packages in R. I also verified that the predictABEL package is installed. The issue appears to be similar to Issue https://github.com/rocker-org/rocker-versioned/issues/141. In that issue, @cboettig noted that:

you just need the dev libraries for tcltk to work

I'm a bit new to Docker and rocker, so I'm not sure how to get the dev libraries for tcltk on the rocker image. Your help would be greatly appreciated.

cboettig commented 3 years ago

Correct, there are a few ways to install the required dev libraries depending on your use case.

eddelbuettel commented 3 years ago

Actually, in this case we just need the Tk runtime package. For apt: tcl, tk pulling in tcl8.6 and tk8.6.

isaactpetersen commented 3 years ago

Using rocker/geospatial worked well. Thanks!