gnu: liblog: Build library correctly.
[jackhill/guix/guix.git] / gnu / packages / image-processing.scm
CommitLineData
504c285d
JD
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2017 John Darrington <jmd@gnu.org>
3;;; Copyright © 2017 Ricardo Wurmus <rekado@elephly.net>
fb226b43
JD
4;;; Copyright © 2014 Ludovic Courtès <ludo@gnu.org>
5;;; Copyright © 2014 Mark H Weaver <mhw@netris.org>
6;;; Copyright © 2016 Eric Bavier <bavier@member.fsf.org>
11861d2b 7;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
504c285d
JD
8;;;
9;;; This file is part of GNU Guix.
10;;;
11;;; GNU Guix is free software; you can redistribute it and/or modify it
12;;; under the terms of the GNU General Public License as published by
13;;; the Free Software Foundation; either version 3 of the License, or (at
14;;; your option) any later version.
15;;;
16;;; GNU Guix is distributed in the hope that it will be useful, but
17;;; WITHOUT ANY WARRANTY; without even the implied warranty of
18;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19;;; GNU General Public License for more details.
20;;;
21;;; You should have received a copy of the GNU General Public License
22;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
23
24(define-module (gnu packages image-processing)
25 #:use-module ((guix licenses) #:prefix license:)
26 #:use-module (guix packages)
27 #:use-module (guix utils)
28 #:use-module (guix download)
cdb2a211 29 #:use-module (guix build-system cmake)
504c285d
JD
30 #:use-module (guix build-system gnu)
31 #:use-module (gnu packages)
cdb2a211
JD
32 #:use-module (gnu packages algebra)
33 #:use-module (gnu packages boost)
504c285d
JD
34 #:use-module (gnu packages compression)
35 #:use-module (gnu packages documentation)
fb226b43
JD
36 #:use-module (gnu packages fontutils)
37 #:use-module (gnu packages gl)
cdb2a211
JD
38 #:use-module (gnu packages gnome)
39 #:use-module (gnu packages graphics)
40 #:use-module (gnu packages graphviz)
504c285d 41 #:use-module (gnu packages image)
cdb2a211
JD
42 #:use-module (gnu packages maths)
43 #:use-module (gnu packages perl)
44 #:use-module (gnu packages pkg-config)
45 #:use-module (gnu packages python)
fb226b43
JD
46 #:use-module (gnu packages serialization)
47 #:use-module (gnu packages xiph)
cdb2a211 48 #:use-module (gnu packages xml)
98d6cdda 49 #:use-module (gnu packages xorg))
504c285d
JD
50
51;; We use the latest snapshot of this package because the latest release is
52;; from 2011 and has known vulnerabilities that cannot easily be fixed by
53;; applying patches.
54(define-public dcmtk
55 (package
56 (name "dcmtk")
57 (version "3.6.1_20170228")
58 (source (origin
59 (method url-fetch)
60 (uri (string-append "ftp://dicom.offis.de/pub/dicom/offis/"
61 "software/dcmtk/snapshot/dcmtk-"
62 version ".tar.gz"))
63 (sha256
64 (base32
65 "04cwfx8yrscqcd59mxk2fh6314ckayi9cp68iql5a57pf2pg5qld"))))
66 (build-system gnu-build-system)
67 (inputs
68 `(("libtiff" ,libtiff)
69 ("libpng" ,libpng)
70 ("doxygen" ,doxygen)
71 ("zlib" ,zlib)))
72 (native-inputs
73 `(("perl" ,perl)))
74 (home-page "http://dcmtk.org")
75 (synopsis "Libraries and programs implementing parts of the DICOM standard")
76 (description "DCMTK is a collection of libraries and applications
77implementing large parts the DICOM standard. It includes software for
78examining, constructing and converting DICOM image files, handling offline
79media, sending and receiving images over a network connection, as well as
80demonstrative image storage and worklist servers.")
81 (license (license:fsf-free
82 "file://COPYRIGHT"
83 "A union of the Apache 2.0 licence and various non-copyleft
84licences similar to the Modified BSD licence."))))
cdb2a211
JD
85
86(define-public mia
87 (package
88 (name "mia")
11861d2b 89 (version "2.4.6")
cdb2a211
JD
90 (source (origin
91 (method url-fetch)
92 (uri (string-append "mirror://sourceforge/mia/mia/"
93 (version-major+minor version)
94 "/mia-" version ".tar.xz"))
95 (sha256
96 (base32
11861d2b 97 "0j4nd5z7i3v199jh7hqqhwd4g7snchizkc7rhzanpvngqg91m1pb"))))
cdb2a211
JD
98 (build-system cmake-build-system)
99 (arguments
100 `(#:configure-flags
101 (list "-DMIA_CREATE_NIPYPE_INTERFACES=0"
cdb2a211
JD
102 "-DCMAKE_CXX_FLAGS=-fpermissive")))
103 (inputs
104 `(("boost" ,boost)
105 ("dcmtk" ,dcmtk)
106 ("doxygen" ,doxygen)
107 ("eigen" ,eigen)
108 ("fftw" ,fftw)
109 ("fftwf" ,fftwf)
110 ("gsl" ,gsl)
111 ("gts" ,gts)
112 ("hdf5" ,hdf5)
113 ("itpp" ,itpp)
114 ("libjpeg" ,libjpeg)
115 ("libpng" ,libpng)
116 ("libtiff" ,libtiff)
117 ("libxml" ,libxml2)
118 ("libxml++" ,libxml++)
119 ("maxflow" ,maxflow)
120 ("niftilib" ,niftilib)
121 ("nlopt" ,nlopt)
122 ("openexr" ,openexr)
123 ("python-lxml" ,python2-lxml)
124 ("vtk" ,vtk)))
125 (native-inputs
126 `(("pkg-config" ,pkg-config)
127 ("python" ,python-2)))
128 (home-page "http://mia.sourceforge.net")
129 (synopsis "Toolkit for gray scale medical image analysis")
130 (description "MIA provides a combination of command line tools, plug-ins,
131and libraries that make it possible run image processing tasks interactively
132in a command shell and to prototype using the shell's scripting language. It
133is built around a plug-in structure that makes it easy to add functionality
134without compromising the original code base and it makes use of a wide variety
135of external libraries that provide additional functionality.")
136 (license license:gpl3+)))
fb226b43
JD
137
138(define-public vtk
139 (package
140 (name "vtk")
141 (version "7.1.0")
142 (source (origin
143 (method url-fetch)
144 (uri (string-append "http://www.vtk.org/files/release/"
145 (version-major+minor version)
146 "/VTK-" version ".tar.gz"))
147 (sha256
148 (base32
149 "0yj96z58haan77gzilnqp7xpf8hg5jk11a3jx55p2ksd400s0gjz"))))
150 (build-system cmake-build-system)
151 (arguments
152 '(#:build-type "Release" ;Build without '-g' to save space.
153 ;; -DVTK_USE_SYSTEM_NETCDF:BOOL=TRUE requires netcdf_cxx
154 #:configure-flags '("-DVTK_USE_SYSTEM_EXPAT:BOOL=TRUE"
155 "-DVTK_USE_SYSTEM_FREETYPE:BOOL=TRUE"
156 "-DVTK_USE_SYSTEM_HDF5:BOOL=TRUE"
157 "-DVTK_USE_SYSTEM_JPEG:BOOL=TRUE"
158 "-DVTK_USE_SYSTEM_JSONCPP:BOOL=TRUE"
159 "-DVTK_USE_SYSTEM_LIBXML2:BOOL=TRUE"
160 "-DVTK_USE_SYSTEM_OGGTHEORA:BOOL=TRUE"
161 "-DVTK_USE_SYSTEM_PNG:BOOL=TRUE"
162 "-DVTK_USE_SYSTEM_TIFF:BOOL=TRUE"
163 "-DVTK_USE_SYSTEM_ZLIB:BOOL=TRUE")
164 #:tests? #f)) ;XXX: no "test" target
165 (inputs
166 `(("libXt" ,libxt)
167 ("xproto" ,xproto)
168 ("libX11" ,libx11)
169 ("libxml2" ,libxml2)
170 ("mesa" ,mesa)
171 ("glu" ,glu)
172 ("expat" ,expat)
173 ("freetype" ,freetype)
174 ("hdf5" ,hdf5)
175 ("jpeg" ,libjpeg)
176 ("jsoncpp" ,jsoncpp)
177 ("libogg" ,libogg)
178 ("libtheora" ,libtheora)
179 ("png" ,libpng)
180 ("tiff" ,libtiff)
181 ("zlib" ,zlib)))
182 (home-page "http://www.vtk.org/")
183 (synopsis "Libraries for 3D computer graphics")
184 (description
185 "The Visualization Toolkit (VTK) is a C++ library for 3D computer graphics,
186image processing and visualization. It supports a wide variety of
187visualization algorithms including: scalar, vector, tensor, texture, and
188volumetric methods; and advanced modeling techniques such as: implicit
189modeling, polygon reduction, mesh smoothing, cutting, contouring, and Delaunay
190triangulation. VTK has an extensive information visualization framework, has
191a suite of 3D interaction widgets, supports parallel processing, and
192integrates with various databases on GUI toolkits such as Qt and Tk.")
193 (license license:bsd-3)))