gnu: python-rpy2: Update to 2.9.0.
* gnu/packages/python.scm (python-rpy2): Update to 2.9.0. [arguments]: Run tests before install phase; add build phase "fix-tests". [propagated-inputs]: Add python-jinja2 and python-pytz. [inputs]: Add r-ggplot2, r-rsqlite, r-dplyr, r-dbplyr, and python-numpy.
This commit is contained in:
parent
c92483bd63
commit
deee5ddaf4
|
@ -4396,33 +4396,56 @@ operators such as union, intersection, and difference.")
|
||||||
(define-public python-rpy2
|
(define-public python-rpy2
|
||||||
(package
|
(package
|
||||||
(name "python-rpy2")
|
(name "python-rpy2")
|
||||||
(version "2.7.6")
|
(version "2.9.0")
|
||||||
(source
|
(source
|
||||||
(origin
|
(origin
|
||||||
(method url-fetch)
|
(method url-fetch)
|
||||||
(uri (pypi-uri "rpy2" version))
|
(uri (pypi-uri "rpy2" version))
|
||||||
(sha256
|
(sha256
|
||||||
(base32
|
(base32
|
||||||
"0nhan2qvrw7b7gg5zddwa22kybdv3x1g26vkd7q8lvnkgzrs4dga"))))
|
"0bqihjrdqwj5r1h86shvfb1p5hfr4a6klv1v54bzfr9r144w3rni"))))
|
||||||
(build-system python-build-system)
|
(build-system python-build-system)
|
||||||
(arguments
|
(arguments
|
||||||
'(#:phases
|
'(#:modules ((ice-9 ftw)
|
||||||
|
(srfi srfi-1)
|
||||||
|
(srfi srfi-26)
|
||||||
|
(guix build utils)
|
||||||
|
(guix build python-build-system))
|
||||||
|
#:phases
|
||||||
(modify-phases %standard-phases
|
(modify-phases %standard-phases
|
||||||
(delete 'check)
|
;; Without this phase the test loader cannot find the directories, in
|
||||||
(add-after 'install 'check
|
;; which it is supposed to look for test files.
|
||||||
|
(add-after 'unpack 'fix-tests
|
||||||
|
(lambda* (#:key outputs #:allow-other-keys)
|
||||||
|
(substitute* "rpy/tests.py"
|
||||||
|
(("loader.discover\\(")
|
||||||
|
"loader.discover(rpy_root + '/' +"))
|
||||||
|
#t))
|
||||||
|
(replace 'check
|
||||||
(lambda* (#:key outputs inputs #:allow-other-keys)
|
(lambda* (#:key outputs inputs #:allow-other-keys)
|
||||||
;; It's easier to run tests after install.
|
(let ((cwd (getcwd)))
|
||||||
;; Make installed package available for running the tests
|
(setenv "PYTHONPATH"
|
||||||
(add-installed-pythonpath inputs outputs)
|
(string-append cwd "/build/"
|
||||||
|
(find (cut string-prefix? "lib" <>)
|
||||||
|
(scandir (string-append cwd "/build")))
|
||||||
|
":"
|
||||||
|
(getenv "PYTHONPATH"))))
|
||||||
(zero? (system* "python" "-m" "rpy2.tests" "-v")))))))
|
(zero? (system* "python" "-m" "rpy2.tests" "-v")))))))
|
||||||
(propagated-inputs
|
(propagated-inputs
|
||||||
`(("python-six" ,python-six)))
|
`(("python-six" ,python-six)
|
||||||
|
("python-jinja2" ,python-jinja2)
|
||||||
|
("python-pytz" ,python-pytz)))
|
||||||
(inputs
|
(inputs
|
||||||
`(("readline" ,readline)
|
`(("readline" ,readline)
|
||||||
("icu4c" ,icu4c)
|
("icu4c" ,icu4c)
|
||||||
("pcre" ,pcre)
|
("pcre" ,pcre)
|
||||||
("r-minimal" ,r-minimal)
|
("r-minimal" ,r-minimal)
|
||||||
("r-survival" ,r-survival)))
|
("r-survival" ,r-survival)
|
||||||
|
("r-ggplot2" ,r-ggplot2)
|
||||||
|
("r-rsqlite" ,r-rsqlite)
|
||||||
|
("r-dplyr" ,r-dplyr)
|
||||||
|
("r-dbplyr" ,r-dbplyr)
|
||||||
|
("python-numpy" ,python-numpy)))
|
||||||
(native-inputs
|
(native-inputs
|
||||||
`(("zlib" ,zlib)))
|
`(("zlib" ,zlib)))
|
||||||
(home-page "http://rpy.sourceforge.net/")
|
(home-page "http://rpy.sourceforge.net/")
|
||||||
|
|
Loading…
Reference in New Issue