2015-02-12 11:58:11 +00:00
|
|
|
;;; GNU Guix --- Functional package management for GNU
|
|
|
|
;;; Copyright © 2015 Ricardo Wurmus <rekado@elephly.net>
|
|
|
|
;;;
|
|
|
|
;;; This file is part of GNU Guix.
|
|
|
|
;;;
|
|
|
|
;;; GNU Guix is free software; you can redistribute it and/or modify it
|
|
|
|
;;; under the terms of the GNU General Public License as published by
|
|
|
|
;;; the Free Software Foundation; either version 3 of the License, or (at
|
|
|
|
;;; your option) any later version.
|
|
|
|
;;;
|
|
|
|
;;; GNU Guix is distributed in the hope that it will be useful, but
|
|
|
|
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
;;; GNU General Public License for more details.
|
|
|
|
;;;
|
|
|
|
;;; You should have received a copy of the GNU General Public License
|
|
|
|
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
|
|
|
|
(define-module (gnu packages statistics)
|
|
|
|
#:use-module ((guix licenses) #:prefix license:)
|
|
|
|
#:use-module (guix packages)
|
|
|
|
#:use-module (guix download)
|
|
|
|
#:use-module (guix utils)
|
|
|
|
#:use-module (guix build-system gnu)
|
|
|
|
#:use-module (gnu packages)
|
|
|
|
#:use-module (gnu packages compression)
|
|
|
|
#:use-module (gnu packages gcc)
|
|
|
|
#:use-module (gnu packages gtk)
|
|
|
|
#:use-module (gnu packages icu4c)
|
|
|
|
#:use-module (gnu packages image)
|
|
|
|
#:use-module (gnu packages java)
|
|
|
|
#:use-module (gnu packages maths)
|
|
|
|
#:use-module (gnu packages pcre)
|
|
|
|
#:use-module (gnu packages perl)
|
|
|
|
#:use-module (gnu packages pkg-config)
|
|
|
|
#:use-module (gnu packages readline)
|
|
|
|
#:use-module (gnu packages texlive)
|
|
|
|
#:use-module (gnu packages texinfo)
|
gnu: Move 'which' to (gnu packages base).
* gnu/packages/which.scm: Remove.
* gnu-system.am (GNU_SYSTEM_MODULES): Remove it.
* gnu/packages/base.scm (which): New variable.
* gnu/packages/aspell.scm, gnu/packages/audio.scm,
gnu/packages/autogen.scm, gnu/packages/cdrom.scm,
gnu/packages/compression.scm, gnu/packages/datamash.scm,
gnu/packages/games.scm, gnu/packages/glib.scm,
gnu/packages/gnu-pw-mgr.scm, gnu/packages/gnutls.scm,
gnu/packages/gps.scm, gnu/packages/guile.scm,
gnu/packages/java.scm, gnu/packages/libevent.scm,
gnu/packages/linux.scm, gnu/packages/lisp.scm,
gnu/packages/node.scm, gnu/packages/ntp.scm,
gnu/packages/orpheus.scm, gnu/packages/pciutils.scm,
gnu/packages/python.scm, gnu/packages/qt.scm,
gnu/packages/rsync.scm, gnu/packages/sawfish.scm,
gnu/packages/scheme.scm, gnu/packages/ssh.scm,
gnu/packages/statistics.scm, gnu/packages/texlive.scm,
gnu/packages/wdiff.scm: Adjust accordingly.
2015-03-04 16:21:21 +00:00
|
|
|
#:use-module (gnu packages base)
|
2015-02-12 11:58:11 +00:00
|
|
|
#:use-module (gnu packages xorg))
|
|
|
|
|
|
|
|
(define-public r
|
|
|
|
(package
|
|
|
|
(name "r")
|
2015-08-17 08:33:22 +00:00
|
|
|
(version "3.2.2")
|
2015-02-12 11:58:11 +00:00
|
|
|
(source (origin
|
|
|
|
(method url-fetch)
|
|
|
|
(uri (string-append "mirror://cran/src/base/R-"
|
|
|
|
(version-prefix version 1) "/R-"
|
|
|
|
version ".tar.gz"))
|
|
|
|
(sha256
|
|
|
|
(base32
|
2015-08-17 08:33:22 +00:00
|
|
|
"07a6s865bjnh7w0fqsrkv1pva76w99v86w0w787qpdil87km54cw"))))
|
2015-02-12 11:58:11 +00:00
|
|
|
(build-system gnu-build-system)
|
|
|
|
(arguments
|
2015-04-22 09:58:44 +00:00
|
|
|
`(#:make-flags
|
|
|
|
(list (string-append "LDFLAGS=-Wl,-rpath="
|
|
|
|
(assoc-ref %outputs "out")
|
|
|
|
"/lib/R/lib"))
|
|
|
|
#:phases
|
2015-07-02 08:49:17 +00:00
|
|
|
(modify-phases %standard-phases
|
|
|
|
(add-before
|
|
|
|
'configure 'set-default-pager
|
|
|
|
;; Set default pager to "cat", because otherwise it is "false",
|
|
|
|
;; making "help()" print nothing at all.
|
|
|
|
(lambda _ (setenv "PAGER" "cat") #t))
|
|
|
|
(add-before
|
|
|
|
'check 'set-timezone
|
|
|
|
;; Some tests require the timezone to be set.
|
|
|
|
(lambda _ (setenv "TZ" "UTC") #t)))
|
2015-02-12 11:58:11 +00:00
|
|
|
#:configure-flags
|
2015-07-03 16:42:58 +00:00
|
|
|
'("--with-blas=openblas"
|
2015-02-12 11:58:11 +00:00
|
|
|
"--with-lapack"
|
|
|
|
"--with-cairo"
|
|
|
|
"--with-libpng"
|
|
|
|
"--with-jpeglib"
|
|
|
|
"--with-libtiff"
|
|
|
|
"--with-ICU"
|
|
|
|
"--enable-R-shlib"
|
|
|
|
"--enable-BLAS-shlib"
|
|
|
|
"--with-system-zlib"
|
|
|
|
"--with-system-bzlib"
|
|
|
|
"--with-system-pcre"
|
|
|
|
"--with-system-tre"
|
|
|
|
"--with-system-xz")))
|
|
|
|
(native-inputs
|
|
|
|
`(("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)))
|
|
|
|
(inputs
|
2015-07-03 16:42:58 +00:00
|
|
|
`(("openblas" ,openblas)
|
2015-02-12 11:58:11 +00:00
|
|
|
("cairo" ,cairo)
|
2015-06-25 15:56:07 +00:00
|
|
|
("gfortran" ,gfortran)
|
2015-02-12 11:58:11 +00:00
|
|
|
("icu4c" ,icu4c)
|
2015-03-04 09:25:54 +00:00
|
|
|
("icedtea6" ,icedtea6 "jdk")
|
2015-02-12 11:58:11 +00:00
|
|
|
("lapack" ,lapack)
|
|
|
|
("libjpeg" ,libjpeg)
|
|
|
|
("libpng" ,libpng)
|
|
|
|
("libtiff" ,libtiff)
|
|
|
|
("libxt" ,libxt)
|
|
|
|
("pcre" ,pcre)
|
|
|
|
("readline" ,readline)
|
|
|
|
("zlib" ,zlib)))
|
2015-08-17 08:33:52 +00:00
|
|
|
(native-search-paths
|
|
|
|
(list (search-path-specification
|
|
|
|
(variable "R_LIBS_SITE")
|
|
|
|
(files (list "site-library/")))))
|
2015-02-12 11:58:11 +00:00
|
|
|
(home-page "http://www.r-project.org/")
|
|
|
|
(synopsis "Environment for statistical computing and graphics")
|
|
|
|
(description
|
|
|
|
"R is a language and environment for statistical computing and graphics.
|
|
|
|
It provides a variety of statistical techniques, such as linear and nonlinear
|
|
|
|
modeling, classical statistical tests, time-series analysis, classification
|
|
|
|
and clustering. It also provides robust support for producing
|
|
|
|
publication-quality data plots. A large amount of 3rd-party packages are
|
|
|
|
available, greatly increasing its breadth and scope.")
|
|
|
|
(license license:gpl3+)))
|