gnu: libical: Correct zoneinfo search path.
[jackhill/guix/guix.git] / gnu / packages / graphviz.scm
CommitLineData
b1b07d72 1;;; GNU Guix --- Functional package management for GNU
3246cc91 2;;; Copyright © 2013, 2015 Ludovic Courtès <ludo@gnu.org>
88377435 3;;; Copyright © 2015 Efraim Flashner <efraim@flashner.co.il>
b1b07d72
LC
4;;;
5;;; This file is part of GNU Guix.
6;;;
7;;; GNU Guix is free software; you can redistribute it and/or modify it
8;;; under the terms of the GNU General Public License as published by
9;;; the Free Software Foundation; either version 3 of the License, or (at
10;;; your option) any later version.
11;;;
12;;; GNU Guix is distributed in the hope that it will be useful, but
13;;; WITHOUT ANY WARRANTY; without even the implied warranty of
14;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15;;; GNU General Public License for more details.
16;;;
17;;; You should have received a copy of the GNU General Public License
18;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
19
20(define-module (gnu packages graphviz)
21 #:use-module (guix packages)
22 #:use-module (guix build-system gnu)
23 #:use-module (guix download)
24 #:use-module (gnu packages xorg)
25 #:use-module (gnu packages gtk)
26 #:use-module (gnu packages xml)
27 #:use-module (gnu packages glib)
28 #:use-module (gnu packages bison)
e55354b8 29 #:use-module (gnu packages image)
b1b07d72
LC
30 #:use-module (gnu packages autotools)
31 #:use-module (gnu packages pkg-config)
32 #:use-module (gnu packages fontutils)
33 #:use-module (gnu packages compression)
34 #:use-module (gnu packages gd)
35 #:use-module ((guix licenses) #:select (lgpl2.0+ epl1.0)))
36
37(define-public graphviz
38 (package
39 (name "graphviz")
64cb2de5 40 (version "2.38.0")
b1b07d72
LC
41 (source (origin
42 (method url-fetch)
43 (uri (string-append
44 "http://www.graphviz.org/pub/graphviz/ARCHIVE/graphviz-"
64cb2de5 45 version ".tar.gz"))
b1b07d72
LC
46 (sha256
47 (base32
64cb2de5 48 "17l5czpvv5ilmg17frg0w4qwf89jzh2aglm9fgx0l0aakn6j7al1"))))
b1b07d72
LC
49 (build-system gnu-build-system)
50 (arguments
51 ;; FIXME: rtest/rtest.sh is a ksh script (!). Add ksh as an input.
52 '(#:tests? #f
53
54 #:phases (alist-cons-before
55 'build 'pre-build
56 (lambda _
57 ;; Work around bogus makefile when using an external
58 ;; libltdl. Failing to do so, one hits this error:
59 ;; "No rule to make target `-lltdl', needed by `libgvc.la'."
60 (substitute* "lib/gvc/Makefile"
61 (("am__append_5 *=.*")
62 "am_append_5 =\n")))
88377435
EF
63 (alist-cons-after
64 'install 'move-docs
65 (lambda* (#:key outputs #:allow-other-keys)
66 (let ((out (assoc-ref outputs "out"))
67 (doc (assoc-ref outputs "doc")))
68 (mkdir-p (string-append doc "/share/graphviz"))
69 (rename-file (string-append out "/share/graphviz/doc")
70 (string-append doc "/share/graphviz/doc"))
71 #t))
72 %standard-phases))))
b1b07d72
LC
73 (inputs
74 `(("libXrender" ,libxrender)
75 ("libX11" ,libx11)
76 ("gts" ,gts)
77 ("gd" ,gd) ; FIXME: Our GD is too old
78 ("pango" ,pango)
79 ("fontconfig" ,fontconfig)
80 ("freetype" ,freetype)
3246cc91 81 ("libltdl" ,libltdl)
b1b07d72
LC
82 ("libXaw" ,libxaw)
83 ("expat" ,expat)
84 ("libjpeg" ,libjpeg)
c4c4cc05
JD
85 ("libpng" ,libpng)))
86 (native-inputs
87 `(("bison" ,bison)
b1b07d72 88 ("pkg-config" ,pkg-config)))
88377435 89 (outputs '("out" "doc")) ; 5 MiB of html + pdfs
b1b07d72
LC
90 (home-page "http://www.graphviz.org/")
91 (synopsis "Graph visualization software")
92 (description
30ac136d 93 "Graphviz is a graph visualization tool suite. Graph visualization is a
b1b07d72
LC
94way of representing structural information as diagrams of abstract graphs and
95networks. It has important applications in networking, bioinformatics,
96software engineering, database and web design, machine learning, and in visual
97interfaces for other technical domains.")
98 (license epl1.0)))
99
100(define-public gts
101 (package
102 (name "gts")
103 (version "0.7.6")
104 (source (origin
105 (method url-fetch)
106 (uri (string-append "mirror://sourceforge/gts/gts-"
107 version ".tar.gz"))
108 (sha256
109 (base32
110 "07mqx09jxh8cv9753y2d2jsv7wp8vjmrd7zcfpbrddz3wc9kx705"))))
111 (build-system gnu-build-system)
112 (arguments
113 '(#:phases (alist-cons-before
114 'check 'pre-check
115 (lambda _
116 (chmod "test/boolean/test.sh" #o777))
117 %standard-phases)
118
119 ;; Some data files used by the test suite are missing.
120 ;; See <http://sourceforge.net/p/gts/bugs/41/>.
121 #:tests? #f))
c4c4cc05 122 (native-inputs
b1b07d72
LC
123 `(("pkg-config" ,pkg-config)))
124 (propagated-inputs
125 ;; The gts.pc file has glib-2.0 as required.
126 `(("glib" ,glib)))
127 (home-page "http://gts.sourceforge.net/")
128
129 ;; Note: Despite the name, this is not official GNU software.
130 (synopsis "Triangulated Surface Library")
131 (description
132 "Library intended to provide a set of useful functions to deal with
1333D surfaces meshed with interconnected triangles.")
134 (license lgpl2.0+)))