...
- Produce a module file. It should be sufficient, to copy that of the previous version and to change the version number in the file.
...
Single R-package installation
Before a package is installed, the correct compiler module must be loaded. Otherwise the system compiler is used. Since c++ is used a lot, this may result in an inconsistent package library. It is not needed, to load a R-module file, when the scripts described below are used.
Package installation may be done with the help of Rscript or directly from R or rstudio. We recommend to use our scripts instead, since
- they load the default compiler compatible with R
- contain some fixes and workarounds needed to install some packages
- set the permissions for the installed files, which is often forgotten
- help with bookkeeping of package lists.
The scripts produce a one line script executed immediately by Rscript. It employs mainly the R-libraries install.packages (not to mix with our script with the same name!) or githubinstall.
We support three different repositories:
...
If the installation is successful, the scripts prompt to ask for adding the package into a list of packages that will be installed by default with a new R version. In this case, one of the package lists in /sw/viz/R/package_list is updated, a copy of the previous list is stored in /sw/viz/R/package_list_save. These lists can be edited by hand.
To remove a package, you may use
...
Automatic removal from the list of default packages is not implemented yet.
Default R-packages
To install the bundle of predefined R-packages, use the script install_packages. It
- loads the appropriate compiler module
- employs install_cran, install_github and install_bioc to install the packages
- sets the correct permissions for the installed files and libraries
- documents success or failure of the installation
Codeblock |
---|
$ ./install_packages
|
The lists are located in /sw/viz/R/package_list. They can be maintained with any editor. They are the result of user requests in the past. They are over-complete, since many packages are installed in any case as prerequisite for other packages. Success or failure are reported in packages_success.log and packages_failed.log.
Using install_packages is coffee consuming. The script needs several hours to install the full list of packages. Some prerequisites are installed several times.
Known issues
The installation of some packages fails and is reported in packages_failed.log. Repeating the installation of the single packages helps in all cases, the reason is unknown. Search in /sw/viz/R/package_list, which install source is the appropriate one. Using github instead of cran may result in a long lasting version update of all prerequisites. However, no package failure has been reported anyway.
Rmpi is linked with openmpi. The intel compilers and impi are not tested yet.
Some packages do not set rpath properly, do not accept libraries at non-default places or do not consider the flags configure.vars and configure.args used by the R-package install.packages. In this case, there are limited means to propagate information on include paths or rpath to the package installation process. One way to do this, is to put the appropriate compiler flags in ~/.R/Makevars. The scripts do not overwrite this file, but save a copy fist that is restored in the end of the package installation.