From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ricardo Wurmus Subject: [PATCH] R dependencies Date: Thu, 3 Sep 2015 12:12:13 +0200 Message-ID: References: <87613v43kv.fsf@gnu.org> <87a8t64ph1.fsf@elephly.net> <871teh9ddz.fsf_-_@gnu.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:39932) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZXRVO-00027w-K9 for guix-devel@gnu.org; Thu, 03 Sep 2015 06:12:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZXRVI-0006KO-4l for guix-devel@gnu.org; Thu, 03 Sep 2015 06:12:30 -0400 In-Reply-To: <871teh9ddz.fsf_-_@gnu.org> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: Ludovic =?utf-8?Q?Court=C3=A8s?= Cc: guix-devel@gnu.org, Vicente Vera --=-=-= Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Ludovic Court=C3=A8s writes: > Speaking of which: should we get rid of icedtea6:jdk in the default R > package (closure size: 1GiB), and maybe of TeX Live (4GiB)? Or should > we provide, say, =E2=80=98r-light=E2=80=99 with the definition above? > > I=E2=80=99m afraid having these two dependencies by default makes it > prohibitively expensive. I investigated this a bit and found that the JDK is not really needed at build time. The first patch includes a comment explaining why we dropped the JDK from the inputs. The second patch adds build phases to install the info documentation. Removing texlive is possible as well, but it results in the loss of the following files: ./lib/R/library/grid /doc displaylist.R displaylist.Rnw frame.R frame.Rnw grid.R grid.Rnw grobs.R grobs.Rnw index.html interactive.R interactive.Rnw locndimn.R locndimn.Rnw moveline.R moveline.Rnw nonfinite.R nonfinite.Rnw plotexample.R plotexample.Rnw rotated.R rotated.Rnw saveload.R saveload.Rnw sharing.R sharing.Rnw viewports.R viewports.Rnw /Meta vignette.rds ./lib/R/library/parallel /doc index.html parallel.R parallel.Rnw /Meta vignette.rds ./lib/R/library/utils /doc index.html Sweave.R Sweave.Rnw /Meta vignette.rds Note that these Rnw files are all literate programming sources containing the sources that are untangled to .R files and the PDF documentation. Interestingly, the source tarball already contains the PDF files (e.g. the one installed to =E2=80=9Clib/R/library/grid/doc/viewports.pdf=E2=80=9D), so we don=E2=80=99= t need texlive to generate them. Attached are the three patches. ~~ Ricardo --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename="0001-gnu-r-Drop-IcedTea-from-inputs.patch" >From 11e8a484733b492ff5ecd6119b9bdef238be6e67 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 3 Sep 2015 11:41:07 +0200 Subject: [PATCH 1/3] gnu: r: Drop IcedTea from inputs. * gnu/packages/statistics.scm (r)[inputs]: Remove "icedtea6". --- gnu/packages/statistics.scm | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index b84c48d..b1cc5cf 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -84,6 +84,16 @@ "--with-system-pcre" "--with-system-tre" "--with-system-xz"))) + ;; R has some support for Java. When the JDK is available at configure + ;; time environment variables pointing to the JDK will be recorded under + ;; $R_HOME/etc and ./tools/getsp.java will be compiled which is used by "R + ;; CMD javareconf". "R CMD javareconf" appears to only be used to update + ;; the recorded environment variables in $R_HOME/etc. Refer to + ;; https://cran.r-project.org/doc/manuals/r-release/R-admin.html#Java-support + ;; for additional information. + + ;; As the JDK is a rather large input with only very limited effects on R, + ;; we decided to drop it. (native-inputs `(("bzip2" ,bzip2) ("perl" ,perl) @@ -97,7 +107,6 @@ ("cairo" ,cairo) ("gfortran" ,gfortran) ("icu4c" ,icu4c) - ("icedtea6" ,icedtea6 "jdk") ("lapack" ,lapack) ("libjpeg" ,libjpeg) ("libpng" ,libpng) -- 2.1.0 --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename="0002-gnu-r-Install-info-documentation.patch" >From 17f4d01ce2b7bb4b41e565ac43463425e79b6c30 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 3 Sep 2015 11:41:36 +0200 Subject: [PATCH 2/3] gnu: r: Install info documentation. * gnu/packages/statistics.scm (r)[arguments]: Add phases "make-info" and "install-info" to build and install info documentation. --- gnu/packages/statistics.scm | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index b1cc5cf..ec705c2 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -68,7 +68,11 @@ (add-before 'check 'set-timezone ;; Some tests require the timezone to be set. - (lambda _ (setenv "TZ" "UTC") #t))) + (lambda _ (setenv "TZ" "UTC") #t)) + (add-after 'build 'make-info + (lambda _ (zero? (system* "make" "info")))) + (add-after 'build 'install-info + (lambda _ (zero? (system* "make" "install-info"))))) #:configure-flags '("--with-blas=openblas" "--with-lapack" -- 2.1.0 --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename="0003-gnu-r-Drop-texlive-from-native-inputs.patch" >From d4982f4574579fe60e005807aace966279824f01 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Thu, 3 Sep 2015 12:09:47 +0200 Subject: [PATCH 3/3] gnu: r: Drop texlive from native-inputs. * gnu/packages/statistics.scm (r)[native-inputs]: Remove "texlive". --- gnu/packages/statistics.scm | 1 - 1 file changed, 1 deletion(-) diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm index ec705c2..7cb61c9 100644 --- a/gnu/packages/statistics.scm +++ b/gnu/packages/statistics.scm @@ -102,7 +102,6 @@ `(("bzip2" ,bzip2) ("perl" ,perl) ("pkg-config" ,pkg-config) - ("texlive" ,texlive) ; needed to make vignettes ("texinfo" ,texinfo) ; for building HTML manuals ("which" ,which) ; for tests/Examples/base-Ex.R ("xz" ,xz))) -- 2.1.0 --=-=-=--