linux-initrd: Add USB kernel modules to the default initrd.
[jackhill/guix/guix.git] / gnu / packages / imagemagick.scm
CommitLineData
7fa37abc 1;;; GNU Guix --- Functional package management for GNU
0f4139e9 2;;; Copyright © 2013, 2014 Ludovic Courtès <ludo@gnu.org>
7fa37abc
LC
3;;;
4;;; This file is part of GNU Guix.
5;;;
6;;; GNU Guix is free software; you can redistribute it and/or modify it
7;;; under the terms of the GNU General Public License as published by
8;;; the Free Software Foundation; either version 3 of the License, or (at
9;;; your option) any later version.
10;;;
11;;; GNU Guix is distributed in the hope that it will be useful, but
12;;; WITHOUT ANY WARRANTY; without even the implied warranty of
13;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14;;; GNU General Public License for more details.
15;;;
16;;; You should have received a copy of the GNU General Public License
17;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
18
19(define-module (gnu packages imagemagick)
20 #:use-module (guix packages)
21 #:use-module (guix build-system gnu)
22 #:use-module (guix download)
23 #:use-module ((guix licenses) #:select (fsf-free))
9b937137 24 #:use-module (gnu packages algebra)
7fa37abc 25 #:use-module (gnu packages compression)
9b937137
AE
26 #:use-module (gnu packages fontutils)
27 #:use-module (gnu packages ghostscript)
7fa37abc 28 #:use-module (gnu packages graphviz)
7fa37abc 29 #:use-module (gnu packages gtk)
e55354b8 30 #:use-module (gnu packages image)
9b937137
AE
31 #:use-module (gnu packages pkg-config)
32 #:use-module (gnu packages xml)
33 #:use-module (gnu packages xorg))
7fa37abc
LC
34
35(define-public imagemagick
36 (package
37 (name "imagemagick")
ca143f13 38 (version "6.8.9-0")
7fa37abc
LC
39 (source (origin
40 (method url-fetch)
41 (uri (string-append "mirror://imagemagick/ImageMagick-"
42 version ".tar.xz"))
43 (sha256
44 (base32
ca143f13 45 "1lapn2798fkc2wn81slpms5p21kq4dsyg45khsk7n8p69cvrmw2b"))))
7fa37abc
LC
46 (build-system gnu-build-system)
47 (arguments
48 `(#:phases (alist-cons-before
49 'build 'pre-build
50 (lambda* (#:key outputs #:allow-other-keys)
51 (substitute* "Makefile"
52 ;; Clear the `LIBRARY_PATH' setting, which otherwise
53 ;; interferes with our own use.
54 (("^LIBRARY_PATH[[:blank:]]*=.*$")
55 "")
56
57 ;; Since the Makefile overrides $docdir, modify it to
58 ;; refer to what we want.
59 (("^DOCUMENTATION_PATH[[:blank:]]*=.*$")
60 (let ((doc (assoc-ref outputs "doc")))
61 (string-append "DOCUMENTATION_PATH = "
62 doc "/share/doc/"
63 ,name "-" ,version "\n")))))
64 %standard-phases)))
9b937137
AE
65 ;; TODO: Add Jasper etc.
66 (inputs `(("fftw" ,fftw)
67 ("graphviz" ,graphviz)
7fa37abc 68 ("ghostscript" ,ghostscript)
9b937137 69 ("lcms" ,lcms)
7fa37abc
LC
70 ("libx11" ,libx11)
71 ("zlib" ,zlib)
72 ("libxml2" ,libxml2)
73 ("libtiff" ,libtiff)
74 ("libpng" ,libpng)
75 ("libjpeg" ,libjpeg-8)
76 ("pango" ,pango)
77 ("freetype" ,freetype)
78 ("bzip2" ,bzip2)
c4c4cc05
JD
79 ("xz" ,xz)))
80 (native-inputs `(("pkg-config" ,pkg-config)))
7fa37abc
LC
81 (outputs '("out"
82 "doc")) ; 26 MiB of HTML documentation
83 (home-page "http://www.imagemagick.org/")
84 (synopsis "Create, edit, compose, or convert bitmap images")
85 (description
86 "ImageMagick® is a software suite to create, edit, compose, or convert
35b9e423 87bitmap images. It can read and write images in a variety of formats (over 100)
7fa37abc 88including DPX, EXR, GIF, JPEG, JPEG-2000, PDF, PhotoCD, PNG, Postscript, SVG,
35b9e423 89and TIFF. Use ImageMagick to resize, flip, mirror, rotate, distort, shear and
7fa37abc
LC
90transform images, adjust image colors, apply various special effects, or draw
91text, lines, polygons, ellipses and Bézier curves.")
92 (license (fsf-free "http://www.imagemagick.org/script/license.php"))))