https://github.com/HenrikBengtsson/git-r
A Git Extension Making it Easier to Build R from Source
https://github.com/HenrikBengtsson/git-r
Last synced: 5 months ago
JSON representation
A Git Extension Making it Easier to Build R from Source
- Host: GitHub
- URL: https://github.com/HenrikBengtsson/git-r
- Owner: HenrikBengtsson
- Created: 2020-10-26T19:39:58.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2024-02-01T05:03:25.000Z (over 1 year ago)
- Last Synced: 2024-08-13T07:16:09.476Z (9 months ago)
- Language: Shell
- Size: 17.6 KB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- jimsghstars - HenrikBengtsson/git-r - A Git Extension Making it Easier to Build R from Source (Shell)
README
# A Git Extension Making it Easier to Build R from Source
## Installation
The `git-r` script is distributed under GPL (>= 2.1) and the source code is
available at https://github.com/HenrikBengtsson/git-r/. To "install" it,
just do:```sh
$ curl -O https://raw.githubusercontent.com/HenrikBengtsson/git-r/master/bin/git-r
$ chmod ugo+x git-r
```If you add it to the `PATH`, then the `git` command will automatically find it and you can call it as:
```sh
$ git r ...
```## Full command-line help
```
Git R: Build R From GitHub SourceUsage:
git-r [options]*Commands:
configure Configure
svn-revision Update and display SVN-VERSION
pull-recommended Download (rsync) recommended packages
build Update SVN-REVISION and runs 'make'
build-recommended Build recommended packages
install
svn-diff Generate a SVN-compatible patch
svn-patch Apply svn-diff patch to SVN repos
prefix Output installation pathOptions:
--prefix-root Installation directory.
(default: '$HOME/software/R-devel')
--verbose/--no-verbose Control output of extra information
--version Display versionExample:
git clone https://github.com/wch/r-source.git
cd r-source
git checkout tags/R-4-0-3
git r svn-revisiongit checkout R-4-0-branch
git-r pull-recommended
git-r configure --enable-R-shlib --enable-memory-profiling
git-r build
git-r build-recommended
git-r installgit checkout trunk
git-r configure --enable-R-shlib --enable-memory-profiling --without-recommended-packages
git-r build
git-r install --protectgit-r svn-diff
git-r svn-patch
svn diffRequired System Libraries:
* Ubuntu 18.04:
sudo apt install xorg-dev libpcre2-dev libcurl4-openssl-dev
sudo apt install libreadline-dev libbz2-dev liblzma-dev
sudo apt install libjpeg-dev libtiff-dev libcairo2-dev
sudo apt install openjdk-11-jdkReferences:
* https://bookdown.org/lionel/contributing/building-r.htmlVersion: 0.0.1-9006
Copyright: Henrik Bengtsson (2017-2020)
License: GPL (>= 2.1) [https://www.gnu.org/licenses/gpl.html]
```## Required software
* Git
* Bash
* Everything else required to build R from source, e.g. configure, make, and compilers### Ubuntu 22.04
_(Last updated: 2022-12-19)_
If you're on a fresh Ubuntu 22.04 system, here's what needs to be able to get started with `git-r`:
```sh
sudo apt install -y git curl
```Then, to be able to configure and build R with its default, you need at a minimum:
```r
sudo apt install -y make
sudo apt install -y gcc gfortran g++
sudo apt install -y zlib1g-dev libbz2-dev liblzma-dev
sudo apt install -y libcurl4-gnutls-devsudo apt install -y libreadline-dev ## --with-readline=yes (default)
sudo apt install -y libxt-dev ## --with-x=yes (default)
sudo apt install -y libpcre2-dev ## unless --with-pcre1
```For R to be able to produce PNG image files and also support internationalization (i18n), you need to install:
```sh
sudo apt install -y libpng-dev
sudo apt install -y libicu-dev
```