summaryrefslogtreecommitdiff
path: root/gnu/packages/perl.scm
diff options
context:
space:
mode:
authorRoel Janssen <roel@gnu.org>2020-03-23 11:42:36 +0100
committerRoel Janssen <roel@gnu.org>2020-03-23 11:42:36 +0100
commit7ff639510096ff762b9cced5fba6db254a961af9 (patch)
treedc8782041161da6271bddc41719c1c89edeb6c0b /gnu/packages/perl.scm
parent591faabd8c93bfb6879910d8a424f0db835066c2 (diff)
downloadguix-patches-7ff639510096ff762b9cced5fba6db254a961af9.tar
guix-patches-7ff639510096ff762b9cced5fba6db254a961af9.tar.gz
gnu: Add circos.
* gnu/local.mk: Register circos-remove-findbin.patch. * gnu/packages/patches/circos-remove-findbin.patch: New file. * gnu/packages/perl.scm: New variable.
Diffstat (limited to 'gnu/packages/perl.scm')
-rw-r--r--gnu/packages/perl.scm96
1 files changed, 96 insertions, 0 deletions
diff --git a/gnu/packages/perl.scm b/gnu/packages/perl.scm
index 7e27ea01e7..0d4dcd6fe0 100644
--- a/gnu/packages/perl.scm
+++ b/gnu/packages/perl.scm
@@ -52,6 +52,7 @@
#:use-module (gnu packages base)
#:use-module (gnu packages compression)
#:use-module (gnu packages freedesktop)
+ #:use-module (gnu packages gd)
#:use-module (gnu packages less)
#:use-module (gnu packages ncurses)
#:use-module (gnu packages perl-check)
@@ -870,6 +871,101 @@ the Carp.pm module doesn't help.")
;; Either GPLv2 or the "Artistic" license.
(license (list gpl2 artistic2.0))))
+(define-public circos
+ (package
+ (name "circos")
+ (version "0.69-9")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append
+ "http://circos.ca/distribution/circos-" version ".tgz"))
+ (sha256
+ (base32 "1ll9yxbk0v64813np0qz6h8bc53qlnhg9y1053b57xgkxgmxgn1l"))
+ (patches (list (search-patch "circos-remove-findbin.patch")))))
+ (build-system gnu-build-system)
+ (arguments
+ `(#:tests? #f ; There are no tests.
+ #:phases
+ (modify-phases %standard-phases
+ (delete 'configure)
+ (delete 'build)
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (bin (string-append out "/bin"))
+ (datapath (string-append out "/share/Circos"))
+ (error (string-append out "/share/Circos/error"))
+ (fonts (string-append out "/share/Circos/fonts"))
+ (data (string-append out "/share/Circos/data"))
+ (tiles (string-append out "/share/Circos/tiles"))
+ (etc (string-append out "/share/Circos/etc"))
+ (lib (string-append out "/lib/perl5/site_perl/"
+ ,(package-version perl)))
+ (install-directory (lambda (source target)
+ (mkdir-p target)
+ (copy-recursively source target))))
+ ;; Circos looks into a relative path for its configuration
+ ;; files. We need to provide an absolute path towards the
+ ;; corresponding paths in the store.
+ (substitute* '("bin/circos" "etc/colors_fonts_patterns.conf"
+ "etc/gddiag.conf" "etc/brewer.conf" "README")
+ (("<<include etc") (string-append "<<include " etc)))
+ (substitute* '("etc/colors.conf" "etc/image.black.conf"
+ "etc/patterns.conf" "etc/image.conf")
+ (("<<include ") (string-append "<<include " etc "/")))
+ (substitute* '("etc/fonts.conf" "fonts/README.fonts")
+ (("= fonts") (string-append "= " fonts)))
+ (substitute* "etc/patterns.conf"
+ (("= tiles") (string-append "= " tiles)))
+ (substitute* "lib/Circos/Error.pm"
+ (("error/configuration.missing.txt")
+ (string-append error "/configuration.missing.txt")))
+ (substitute* "etc/housekeeping.conf"
+ (("# data_path = /home/martink/circos-tutorials ")
+ (string-append "data_path = " datapath)))
+ (substitute* "lib/Circos/Configuration.pm"
+ (("my @possibilities = \\(")
+ (string-append "my @possibilities = ("
+ "catfile( \"" datapath "\", $arg ), "
+ "catfile( \"" etc "\", $arg ), "
+ "catfile( \"" etc "/tracks\", $arg ), ")))
+ (for-each install-directory
+ (list "error" "fonts" "data" "tiles" "etc" "lib")
+ (list error fonts data tiles etc lib))
+ (install-file "bin/circos" bin)
+ #t))))))
+ (propagated-inputs
+ `(("perl" ,perl)
+ ("perl-carp" ,perl-carp)
+ ("perl-clone" ,perl-clone)
+ ("perl-config-general" ,perl-config-general)
+ ("perl-digest-md5" ,perl-digest-md5)
+ ("perl-file-temp" ,perl-file-temp)
+ ("perl-font-ttf" ,perl-font-ttf)
+ ("perl-gd" ,perl-gd)
+ ("perl-getopt-long" ,perl-getopt-long)
+ ("perl-list-allutils" ,perl-list-allutils)
+ ("perl-math-bezier" ,perl-math-bezier)
+ ("perl-math-round" ,perl-math-round)
+ ("perl-math-vecstat" ,perl-math-vecstat)
+ ("perl-memoize" ,perl-memoize)
+ ("perl-number-format" ,perl-number-format)
+ ("perl-params-validate" ,perl-params-validate)
+ ("perl-readonly" ,perl-readonly)
+ ("perl-regexp-common" ,perl-regexp-common)
+ ("perl-set-intspan" ,perl-set-intspan)
+ ("perl-statistics-basic" ,perl-statistics-basic)
+ ("perl-svg" ,perl-svg)
+ ("perl-text-balanced" ,perl-text-balanced)
+ ("perl-text-format" ,perl-text-format)
+ ("perl-time-hires" ,perl-time-hires)))
+ (home-page "http://circos.ca/")
+ (synopsis "Generation of circularly composited renditions")
+ (description
+ "Circos is a program for the generation of publication-quality, circularly
+composited renditions of genomic data and related annotations.")
+ (license gpl2+)))
+
(define-public perl-class-accessor
(package
(name "perl-class-accessor")