Set up R system like python system
Update: the R_cran_icu on codeberg is a more complete commit than this one: https://codeberg.org/boud/maneage_dev/commit/1ea9d6db9fab5fd2d88fb51d149777a8090b038f _So better merge 1ea9d6db rather than this merge.
This commit sets up the 'R' system of separate software source package downloading and configuring/compiling/installing in a similar way to the 'python' system. The direct use of the R 'install.packages' function to manage downloads, dependencies, and configuring/compiling/installing does not satisfy the purposes of long-term reproducibility and archivability in Maneage. Here, the downloads are managed (including sha512sum verification) in the usual Maneage way. The R 'install.packages' function is used to configure/compile/install the checksummed local .tar.gz files.
Similarly to the Debian distribution approach, the difficulty in grepping for a one-letter package name is solved by calling the base package 'r-cran' and the library packages 'r-cran-[LIBRARYNAME]'. The name of the binary is not changed, it remains 'R'.
modified: reproduce/software/config/TARGETS.conf modified: reproduce/software/config/checksums.conf modified: reproduce/software/config/urls.conf modified: reproduce/software/config/versions.conf modified: reproduce/software/make/build-rules.mk modified: reproduce/software/make/high-level.mk new file: reproduce/software/make/r-cran.mk
-
r-cran.mk: This commit adds a dependence of each R library on the main R package, even though the corresponding python.mk file does not have the corresponding explicit dependence. It seems that the current policy is to install python and R by default, but it can't hurt to write in these prerequisites explicitly, for better modularity.
-
The rule '
(ibidir)/R-
(R-version):' is shifted from 'high-level.mk' to 'r-cran.mk' and renamed '(ibidir)/r-cran-
(r-cran-version):' -
build.mk: This commit adds optional third and fourth parameters: 3 = explicit upstream name of tarball if not automatic; 4 = alternative upstream base URL.
The third parameter is not explicitly needed for R, but has been useful for some packages where the upstream tarball name was not standard.
The fourth parameter is especially useful for R, since the most recent version of each library is provided at one base URL, and the archived version of each not-most-recent library is provided at another base URL.
-
Some outdated comments about hash strings in .mk files are updated in this commit.
Example test of the 'R-CRAN' system:
- add 'r-cran-cowplot' to 'top-level-r-cran' in 'TARGETS.conf'
- ./project configure --existing-conf
- PATH=.local/bin R library(cowplot) help(cowplot) q help(ggplot2) q quit() n