[Rd] Downsized R configuration for flat deployment
Simon Urbanek
@|mon@urb@nek @end|ng |rom R-project@org
Mon Dec 23 05:57:11 CET 2019
DM,
can you clarify somewhat what you are exactly concerned about? The standard build of R on Linux is relocatable without any special flags needed since R doesn't use absolute paths but manages library path to its components itself so it's very flexible (e.g., I use this feature to run R jobs on Hadoop clusters that don't have R installed as the directory where the job components are unpacked is dynamic). You can always disable whatever features you don't need. In your question I don't understand what you mean by "flat" - on Linux all binaries are flat by default so please clarify what you mean. It's easy to create completely dynamic R deployment - and easy to install packages - both binary and from sources.
Cheers,
Simon
> On Dec 21, 2019, at 8:39 AM, dmedri using gmail.com wrote:
>
> Dear folks,
>
> I'm testing a downsized R build - in features and obviously sizes -
> for a "modern" flat deployment (eg. like python virtualenv, just to
> name one).
>
> Questions:
>
> 1) Is flat style possible?
> 2) With this setup, R and packages can be installed/updated?
> 3) The directory can be easy renamed or moved?
>
> -------------------------------------------------------------------
>
> I didn't find any official git repo, so I downloaded latest stable
> R release (3.6.2), exploring different setups of configure options.
>
> # tested in debian 10
> # $ sudo apt-get build-dep r-base
>
> $ mkdir ~/r-virtual
> $ cd R-3.6.2/
> $ ./configure --prefix=/home/dmedri/r-virtual/ \
> --exec-prefix=/home/dmedri/r-virtual/ \
> --without-recommended-packages \
> --without-cairo \
> --without-libtiff \
> --without-jpeglib \
> --without-x \
> --without-aqua \
> --without-tcltk \
> --disable-rpath
>
> $ make && make install
>
> This minimal R could run inside a container, no desktop just cli,
> with just one graphical formats in output (png). Java support was
> leaved in. I didn't find options to disable html docs. Recommended
> packages were leaved out, for a 2nd stage.
>
> $ cd r-virtual/
> $ ./bin/R
>
> The environment was there, "yes" to question 1).
>
> I can install/update packages, obviously with required includes
> installed in the system, not fetched online -- a limit, looking at
> python pip, partially by design/choice. BTW answer to question 2)
> is "yes" for packages, "no" for the core.
>
> Without the "--disable-rpath" option, abs paths break everything
> with the easy case of "renaming r-virtual directory". IMHO this option
> should be a general default, and another "yes" to question 3).
>
> While I'm still investigating, tips are welcome...
>
> HTH
>
> Best Regards,
>
> DM
>
> ______________________________________________
> R-devel using r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel
>
More information about the R-devel
mailing list