-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding installation instructions for Linux #65
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lgtm.
|
||
### How to download the R sources directly or from the svn repository? | ||
|
||
- To download the R sources on Windows, you can use `tar` from the RStudio terminal. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What could I do w/o RStudio? Couldn't I just dl using a browser? Or maybe using something like wget via Win cmd? Maybe also mention an URL like https://cloud.r-project.org/src/base-prerelease/R-devel.tar.gz? "Untaring" would then be the next step.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As explained in the PR, I didn't touch this section.
I don't assume the guide is only for RStudio users and I will likely modify this section.
|
||
- If you want to checkout the sources from svn, it is probably best to install an SVN client. | ||
Either TortoiseSVN (<https://tortoisesvn.net/>, command line tool, and Windows Explorer integration) or SlikSVN (<https://sliksvn.com/download/>, just the command line tool) is recommended. | ||
They have simple Windows installers and you can use svn straight-away from Windows cmd or RStudio terminal. | ||
|
||
## See also |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@hturner Do we want to let this grow a bit (wait until there's something on macOS as well) before broadening reviewer scope? Or should I add a couple review requests? |
Co-authored-by: nbenn <[email protected]>
Co-authored-by: nbenn <[email protected]>
Co-authored-by: nbenn <[email protected]>
Many thanks for the review @nbenn, I will check the remaining comments and update the PR. I think it is better to merge soon and if there is something more to tweak we can check the whole chapter at the end. I don't think using installing binaries is enough to contribute from Windows (although it can be useful to check if a given patch fixed an issue), for that I'm trying to build from source(Currently stuck with finding the right compiler within RTools42 & MSYG). |
02-getting_started.Rmd
Outdated
|
||
1. [RTools](https://github.com/r-windows/docs/blob/master/faq.md#what-is-rtools) is the toolchain bundle that you can use to build R base and R packages containing compiled code, on Windows. | ||
If you need to install svn you can use your distribution's package manager to install it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would put this in introductory comments, otherwise, newbies might try running the code straight away and get frustrated.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I placed them here because it has the installation instructions specific of Ubuntu and I wanted to provide the same for Windows and macOS. Should I move it to the R source code?
Perhaps I am missing something because the Github UI highlights the "Retrieve R source code via into TOP_SRCDIR
, note that we retrieve the r-devel source code:
svn checkout https://svn.r-project.org/R/trunk/ TOP_SRCDIR"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, sorry for not being clear. I was referring to the part beginning "If you need to install svn you can use your distribution's package manager to install it." (I forgot I could highlight multiple lines!).
I mean that you should say earlier that the instructions get the sources from the svn repo and the reader will need Subversion installed, then give the command for this on Linux. So you might make this part a "Step 0" in the instructions, or have a short "Prerequisites" sub-section before a "Building R" section.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will do it. I like more the Prerequisites subsection as it might be a good place to name the R dependencies: ubuntu packages, macos packages and windows programs.
02-getting_started.Rmd
Outdated
|
||
For development and testing, you need only the quick development build. The quick build avoids building the manuals, which are generally not needed for development and testing. | ||
cd BUILDDIR | ||
TOP_SRCDIR/configure |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These two are not equivalent. With the first, when we run make
, R will be built in whatever directory we are in - we would need to then run make install
to install into BUILDDIR
. With the second (if we had created BUILDDIR
first) running make
would build R inside BUILDDIR
(allowing us to run R without installation via BUILDDIR/bin/R) and if we then ran make install
it would install in the default location of /usr/local/bin
, possibly overwriting an existing R installation!
So there are potentially three locations to consider:
- source directory (created from tarball/SVN/github) TOP_SRCDIR: say ~/R-svn
- build directory BUILDDIR: say ~/R-devel-build
- this is where we run
TOP_SRCDIR/configure
andmake
, to keep our source directory clean
- this is where we run
- install directory INSTALLDIR: say ~/R-devel or /usr/local/lib/R-devel or /opt/R/${R_VERSION}.
- an advantage of using something in the home directory is that you don't need sudo privileges to install, i.e. can just run
make install
- an advantage of using something in the home directory is that you don't need sudo privileges to install, i.e. can just run
However, installation is optional, we can just run R from where it is built. This makes sense for a "temporary" version of R, like R-patched or R-devel. So here - as you have done - we can skip the make install
. This means we don't have to set the prefix
option, but we do need to create a build directory.
I suggest we help readers by getting them to set BUILDDIR and TOP_SRCDIR explicitly, e.g.
export TOP_SRCDIR=$HOME/R-devel-svn
export BUILDDIR=$HOME/R-devel
This means we can make all the instructions ready to copy-paste:
mkdir $BUILDDIR
cd $BUILDDIR
$TOP_SRCDIR/configure
make
make check
It would also be helpful to add instructions for how to build R after you have done it once (not tested):
cd $TOP_SRCDIR
svn update
tools/rsync-recommended
cd $BUILDDIR
$TOP_SRCDIR/configure
make
make check
The problem here is that $TOP_SRCDIR and $BUILDDIR will need to be defined again, or manually edited. Maybe it is better to substitute the recommended values as $HOME is always defined?
I think we should also add instructions for RStudio users, they will need
$TOP_SRCDIR/configure --enable-R-shlib
e.g. "If you plan to use this version of R with RStudio: ... Otherwise:". Note that --
had been turned into an en dash in your code above so make sure it is double dash in the R markdown file.
If users have used the recommended values they can then run R-devel from terminal as follows
$HOME/R-devel/bin/R
or from RStudio (if configured correctly)
export RSTUDIO_WHICH_R=R-devel/bin/R
rstudio
I think it's important to add this so people know how to use the installed R-devel and to make it clear this is separate from their existing R installation, which they can use as normal.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The guide says that " To build in BUILDDIR, run" and just the instructions I have in the guide (but I didn't test without building in the same directory as the source code.
Good point about the three directories (it wasn't really clear to me). Some more comments about it.
Linux users are usually recommended to install optional packages in /opt
or $HOME/bin
(although I have the TOP_SRCDIR in $HOME/R
). As you mention the permission, I think it would be better to just use the later if we use the INSTALLDIR in the guide.
Maybe we can set the source code in TOP_SRCDIR=$HOME/Downloads/R
. It might help to think as svn up
as a download and the need up upate/"download again".
I am a bit uncomfortable with the BUILDDIR
being $HOME/R-devel
as it is dangerous close to $HOME/R-dev
that devtools::dev_mode()
uses as a library directory. I am not sure if we could use $HOME/bin
directory for that?
I don't know about the differences between building and installing 😅
Could we use R without installing it for RStudio and other IDEs? If
I tried configuring from $BUILDDIR and building it and I got an error (despite successful $TOP_SRCDIR/configure):
make[1]: Nothing to be done for 'front-matter'.
make[1]: Nothing to be done for 'html-non-svn'.
SVN-REVISION is unchanged
make[1]: Nothing to be done for 'R'.
make[1]: Nothing to be done for 'R'.
make[2]: Nothing to be done for 'R'.
Rmath.h is unchanged
make[3]: Nothing to be done for 'R'.
make[4]: '/home/lluis/Documents/Projects/R/trunk/src/extra/blas/libRblas.so' is up to date.
cp: cannot stat 'libRblas.so': No such file or directory
make[4]: *** [Makefile:56: Rblas_install] Error 1
make[3]: *** [Makefile:39: R] Error 2
make[2]: *** [Makefile:35: make.blas] Error 2
make[1]: *** [Makefile:28: R] Error 1
make: *** [Makefile:61: R] Error 1
Not sure if a bug but it seems that libRblas is assumed to already be in the BUILDDIR and not ported over from TOP_SRCDIR. in the BUILDDIR/src/extras there is a Makefile that doesn't use the BUILDDIR:
# ${R_HOME}/src/extra/blas/Makefile
VPATH = /home/lluis/Documents/Projects/R/trunk/src/extra/blas
srcdir = /home/lluis/Documents/Projects/R/trunk/src/extra/blas
top_srcdir = /home/lluis/Documents/Projects/R/trunk
top_builddir = ../../..
subdir = src/extra/blas
R_HOME = $(top_builddir)
...
For completeness:
TOP_SRCDIR=/home/lluis/Documents/Projects/R/trunk
BUILDDIR=/home/lluis/bin/R-build
# The one liner of configure and building:
cd $TOP_SRCDIR; svn update; tools/rsync-recommended; cd $BUILDDIR; $TOP_SRCDIR/configure; make; make check
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree that it is important to show how to use the installed from source version it will help for checking packages as well as contributing to R itself. But is this the right place to mention RStudio and the special configuration it needs? I thought to write a separate section for IDEs as many people might not need to use an IDE after a successful make check
after modifying the code.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will correct and look for -- and not a em-dash
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like the idea of using TOP_SRCDIR=$HOME/Downloads/R since contributors will only ever be "downloading" from the repository.
I agree using BUILDDIR=$HOME/bin/R-devel should be safer than making an R-devel
directory in the users home directory.
This discussion supports the idea of using variables though, as people might want to adjust these locations to their preference and if we define them up front that should be clear and simple.
It is not necessary to install R to use it with RStudio. I doubt this is an issue for Emacs either, not sure about other IDEs.
I think since we are writing these instructions for individual contributors (not sys admins) and we don't want to interfere with any existing installation, then we don't need to run make install
. If we did then /opt/R/R-devel would be a good place to install I think, but I can't see any advantage in doing this (we can check about this).
I think we should add to the instructions to delete all files in BUILDDIR before rebuilding as I think not doing this might cause problems like you had.
I think this is the right place to mention configuration options like the one for RStudio as it is annoying if people follow the instructions then find they have to do it all again (or most of it) to use with RStudio.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also as we are not necessarily installing R, perhaps this section should be called "Building R on Linux".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, I will change and add the variables and add the RStudio required option for the users
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I updated part of the PR according to the comments (and resolve& comment them) and some other comments as it might be better to discuss a bit further. Thanks for the review Heather.
For me the best way to see which comments I'm replying is going to the review
02-getting_started.Rmd
Outdated
|
||
1. [RTools](https://github.com/r-windows/docs/blob/master/faq.md#what-is-rtools) is the toolchain bundle that you can use to build R base and R packages containing compiled code, on Windows. | ||
If you need to install svn you can use your distribution's package manager to install it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I placed them here because it has the installation instructions specific of Ubuntu and I wanted to provide the same for Windows and macOS. Should I move it to the R source code?
Perhaps I am missing something because the Github UI highlights the "Retrieve R source code via into TOP_SRCDIR
, note that we retrieve the r-devel source code:
svn checkout https://svn.r-project.org/R/trunk/ TOP_SRCDIR"
02-getting_started.Rmd
Outdated
|
||
For development and testing, you need only the quick development build. The quick build avoids building the manuals, which are generally not needed for development and testing. | ||
cd BUILDDIR | ||
TOP_SRCDIR/configure |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The guide says that " To build in BUILDDIR, run" and just the instructions I have in the guide (but I didn't test without building in the same directory as the source code.
Good point about the three directories (it wasn't really clear to me). Some more comments about it.
Linux users are usually recommended to install optional packages in /opt
or $HOME/bin
(although I have the TOP_SRCDIR in $HOME/R
). As you mention the permission, I think it would be better to just use the later if we use the INSTALLDIR in the guide.
Maybe we can set the source code in TOP_SRCDIR=$HOME/Downloads/R
. It might help to think as svn up
as a download and the need up upate/"download again".
I am a bit uncomfortable with the BUILDDIR
being $HOME/R-devel
as it is dangerous close to $HOME/R-dev
that devtools::dev_mode()
uses as a library directory. I am not sure if we could use $HOME/bin
directory for that?
I don't know about the differences between building and installing 😅
Could we use R without installing it for RStudio and other IDEs? If
I tried configuring from $BUILDDIR and building it and I got an error (despite successful $TOP_SRCDIR/configure):
make[1]: Nothing to be done for 'front-matter'.
make[1]: Nothing to be done for 'html-non-svn'.
SVN-REVISION is unchanged
make[1]: Nothing to be done for 'R'.
make[1]: Nothing to be done for 'R'.
make[2]: Nothing to be done for 'R'.
Rmath.h is unchanged
make[3]: Nothing to be done for 'R'.
make[4]: '/home/lluis/Documents/Projects/R/trunk/src/extra/blas/libRblas.so' is up to date.
cp: cannot stat 'libRblas.so': No such file or directory
make[4]: *** [Makefile:56: Rblas_install] Error 1
make[3]: *** [Makefile:39: R] Error 2
make[2]: *** [Makefile:35: make.blas] Error 2
make[1]: *** [Makefile:28: R] Error 1
make: *** [Makefile:61: R] Error 1
Not sure if a bug but it seems that libRblas is assumed to already be in the BUILDDIR and not ported over from TOP_SRCDIR. in the BUILDDIR/src/extras there is a Makefile that doesn't use the BUILDDIR:
# ${R_HOME}/src/extra/blas/Makefile
VPATH = /home/lluis/Documents/Projects/R/trunk/src/extra/blas
srcdir = /home/lluis/Documents/Projects/R/trunk/src/extra/blas
top_srcdir = /home/lluis/Documents/Projects/R/trunk
top_builddir = ../../..
subdir = src/extra/blas
R_HOME = $(top_builddir)
...
For completeness:
TOP_SRCDIR=/home/lluis/Documents/Projects/R/trunk
BUILDDIR=/home/lluis/bin/R-build
# The one liner of configure and building:
cd $TOP_SRCDIR; svn update; tools/rsync-recommended; cd $BUILDDIR; $TOP_SRCDIR/configure; make; make check
02-getting_started.Rmd
Outdated
|
||
For development and testing, you need only the quick development build. The quick build avoids building the manuals, which are generally not needed for development and testing. | ||
cd BUILDDIR | ||
TOP_SRCDIR/configure |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree that it is important to show how to use the installed from source version it will help for checking packages as well as contributing to R itself. But is this the right place to mention RStudio and the special configuration it needs? I thought to write a separate section for IDEs as many people might not need to use an IDE after a successful make check
after modifying the code.
02-getting_started.Rmd
Outdated
|
||
For development and testing, you need only the quick development build. The quick build avoids building the manuals, which are generally not needed for development and testing. | ||
cd BUILDDIR | ||
TOP_SRCDIR/configure |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will correct and look for -- and not a em-dash
02-getting_started.Rmd
Outdated
sudo apt-get install -y \ | ||
subversion \ | ||
autoconf \ | ||
automake \ | ||
autopoint \ | ||
bash \ | ||
bison \ | ||
bzip2 \ | ||
flex \ | ||
g++ \ | ||
g++-multilib \ | ||
gettext \ | ||
git \ | ||
gperf \ | ||
intltool \ | ||
libc6-dev-i386 \ | ||
libgdk-pixbuf2.0-dev \ | ||
libltdl-dev \ | ||
libssl-dev \ | ||
libtool-bin \ | ||
libxml-parser-perl \ | ||
lzip \ | ||
make \ | ||
openssl \ | ||
p7zip-full \ | ||
patch \ | ||
perl \ | ||
python3 \ | ||
python3-mako \ | ||
python3-setuptools \ | ||
python \ | ||
ruby \ | ||
sed \ | ||
unzip \ | ||
wget \ | ||
xz-utils \ | ||
texinfo \ | ||
sqlite3 \ | ||
zstd |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where did this list come from? Can we not just do sudo apt-get build-dep r-base
? (plus subversion). You can see what would be installed this way via e.g. https://launchpad.net/ubuntu/kinetic/+source/r-base
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't find now where I took the list from. I think it was from a list of packages needed to build most of CRAN's packages in macOS + a de. I should document the source better and provide a more limited list of dependencies.
sudo apt-get build-dep r-base
didn't return the packages, but following this answer and using this command (apt-cache depends --recurse --no-recommends --no-suggests --no-conflicts --no-breaks --no-replaces --no-enhances r-base | grep "^\w" | sort -u | grep -v ":"
I found the list (note that I have installed R via r2u):
ca-certificates
cdebconf
coreutils
debconf
dpkg
fontconfig
fontconfig-config
fonts-croscore
fonts-dejavu-core
fonts-freefont-otf
fonts-freefont-ttf
fonts-liberation
fonts-liberation2
fonts-texgyre
fonts-urw-base35
gcc-12-base
install-info
libacl1
libatlas3-base
libattr1
libblas3
libblis3-openmp
libblis3-pthread
libblis3-serial
libblkid1
libbrotli1
libbsd0
libbz2-1.0
libc6
libcairo2
libcom-err2
libcrypt1
libcurl4
libdatrie1
libdb5.3
libdebian-installer4
libdeflate0
libexpat1
libffi8
libfontconfig1
libfreetype6
libfribidi0
libgcc-s1
libgfortran5
libglib2.0-0
libgmp10
libgnutls30
libgomp1
libgraphite2-3
libgssapi-krb5-2
libharfbuzz0b
libhogweed6
libice6
libicu66
libidn2-0
libjbig0
libjpeg8
libjpeg-turbo8
libk5crypto3
libkeyutils1
libkrb5-3
libkrb5support0
liblapack3
libldap-2.5-0
liblzma5
libmd0
libmount1
libnettle8
libnewt0.52
libnghttp2-14
libopenblas0-openmp
libopenblas0-pthread
libopenblas0-serial
libp11-kit0
libpango-1.0-0
libpangocairo-1.0-0
libpangoft2-1.0-0
libpaper1
libpaper-utils
libpcre2-8-0
libpcre3
libpixman-1-0
libpng16-16
libpsl5
libquadmath0
libreadline8
librtmp1
libsasl2-2
libsasl2-modules-db
libselinux1
libslang2
libsm6
libssh-4
libssl3
libstdc++6
libtasn1-6
libtcl8.6
libtextwrap1
libthai0
libthai-data
libtiff5
libtinfo6
libtk8.6
libunistring2
libuuid1
libwebp7
libx11-6
libx11-data
libxau6
libxcb1
libxcb-render0
libxcb-shm0
libxdmcp6
libxext6
libxft2
libxrender1
libxss1
libxt6
libzstd1
lsb-base
openssl
perl-base
r-base
r-base-core
r-cran-boot
r-cran-class
r-cran-cluster
r-cran-codetools
r-cran-foreign
r-cran-kernsmooth
r-cran-lattice
r-cran-mass
r-cran-matrix
r-cran-mgcv
r-cran-nlme
r-cran-nnet
r-cran-rpart
r-cran-spatial
r-cran-survival
readline-common
r-recommended
sensible-utils
tar
ttf-bitstream-vera
tzdata
ucf
unzip
x11-common
xdg-utils
zip
zlib1g
However, when I tried to install these packages, it found out I don't have several of those packages, so they are not all hard dependencies
cdebconf libatlas3-base libblis3-openmp libblis3-pthread libblis3-serial libdebian-installer4 libopenblas0-openmp libopenblas0-serial libtextwrap1
So, this list is not accurate and might be further reduced.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe also check the output of apt-rdepends --build-depends --follow=DEPENDS r-base
as suggested here: https://askubuntu.com/a/21394. But I guess the advantage of simply using sudo apt-get build-dep r-base
(assuming it is sufficient) is that we do not need to keep such a list up to date in the guide.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will test it tonight, but I think rdepends provides the list of reverse dependencies not direct dependencies (all cran packages installed via cran2u), but I will try it and compare the output.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
General comment, and sorry if this has already been discussed elsewhere:
I can imagine you also want to write installation instructions for non-Debian Linux distributions, especially Fedora-based distributions such as RedHat, CentOS, and now Rocky. These distros are very common in academia, especially on HPC cluster.
Unfortunately, Debian package names are not identical to Fedora ones. For example, libpng-dev
on Debian is libpng-devel
on Fedora. So, one cannot come up with a list that works for all Linux distributions. At best, one needs to keep them up-to-date manually, e.g. by making one of them the core reference.
But I guess the advantage of simply using
sudo apt-get build-dep r-base
(assuming it is sufficient) is that we do not need to keep such a list up to date in the guide.
If r-base
existed in Fedora, that would be a neat solution. Unfortunately, it doesn't exist, at least not in the most common RedHat/RHEL and CentOS repositories, i.e. RHEL/CentOS core, RHEL/CentOS Extras, and the RHEL/CentOS EPEL. Those repositories are considered the stable core repositories (think CRAN).
Personally, I'm in favor of explicitly listing all system packages needed. That'll make it explicit what it takes to install R, and it won't depend on a third-party person maintaining r-base
. It will also allow you to specify which systems packages are required and which are optional (depending on which ./configure
options are used). This would be a good go-to resource for anyone who wish to customize their R installation, e.g. set up a minimal Linux container.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@HenrikBengtsson It has not been discussed, you mentioned it in the r-devel slack some time ago that RStudio had a list of dependencies.
Ideally it would be nice to have this list for other distributions but I don't have any non-Debian machine at hand. I might ask Iñaki Úcar, who maintains the fedora distribution of R, if he could help providing such a list.
apt-rdepends returns (apt-rdepends --build-depends --follow=DEPENDS r-base | grep " B" | sed -e "s/ Build-Depends: //" | sort
):
bash-completion
bison
debhelper-compat (= 11)
default-jdk
g++ (>= 4:4.9.2-2)
gcc (>= 4:4.9.2-2)
gfortran (>= 4:4.9.2-2)
groff-base
libblas-dev
libbz2-dev
libcairo2-dev
libcurl4-dev
libcurl4-openssl-dev
libjpeg-dev
liblapack-dev
liblzma-dev
libncurses5-dev
libpango1.0-dev
libpcre2-dev
libpcre3-dev
libpng-dev
libreadline-dev
libtiff5-dev
libx11-dev
libxt-dev
mpack
tcl8.6-dev
texinfo (>= 4.1-2)
texlive-base
texlive-extra-utils
texlive-fonts-extra
texlive-fonts-recommended
texlive-latex-base
texlive-latex-extra
texlive-latex-recommended
texlive-plain-generic
tk8.6-dev
x11proto-core-dev
xauth
xdg-utils
xfonts-base
xvfb
zlib1g-dev
This is much shorter (43 vs 14X) and realistic imho, but perhaps users that have MiKTeX use it instead of TeX Live.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@HenrikBengtsson we should bear in mind who this guide is for: it is intended for individual contributors to get up and running, especially those with little experience building from source. That is why we focused initially on Windows, as the most common user OS (even among developers: https://survey.stackoverflow.co/2022/#operating-system) and also where users typically install binaries. System admins or advanced users that want to customize their R installation can always refer to R-admin.
So I would prefer to keep it simple if possible, perhaps with a separate section on advanced customization that could be added later. I am quite happy to rely on a third party for maintaining the list as they are the ones expert in the respective distribution.
It would be good to cover Fedora based distros too though. From the link that @llrs shared, it seems that sudo yum-builddep R
works after enabling the EPEL repository? We may have to separate this out into a new issue if we need to find a collaborator with a Fedora-based distro to test. In the meantime we can make it clear that instructions are for Debian-based distros.
@all-contributors please add @llrs for content, question, research, doc, example |
I've put up a pull request to add @llrs! 🎉 |
I'll merge this PR as the issue with the Ubuntu system packages is "solved". It could be that with miktex installed all the 8 texlive-* would be replaced by a single miktex dependency too. |
This PR is part of the GSOD-2022 adding a brief instructions how to install R for linux (Ubuntu) from source.
I expanded a bit the introduction of the different types of R versions available and the versioning system used.
Maybe a simple graph explaining the relationships between different R versions would help,
something like:
Following the python quick reference I organized the instructions as a list. But I left the windows and macOS bits out (I haven't checked yet if these instructions would work there).
In the python book they also have on the list how to create patches and submit them.
I mention it at the end of the installation instructions.
I assumed users have all the third party requirements of R. From the discussions in the slack, it seems that how to install those third-party dependencies (or at least a list of them) might help R sysadmins. I'm not sure how to collect those besides looking to dependencies in r-base for Ubuntu or the list of the SUSE Linux instruction @HenrikBengtsson mentioned.
The rest of the chapter is left as it was (but with minor changes: whitespaces and having each sentence in a new line).