gnu: shaderc: Use more standard keys.
[jackhill/guix/guix.git] / gnu / packages / chemistry.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2018 Konrad Hinsen <konrad.hinsen@fastmail.net>
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 chemistry)
20 #:use-module (guix packages)
21 #:use-module ((guix licenses) #:prefix license:)
22 #:use-module (guix download)
23 #:use-module (gnu packages gv)
24 #:use-module (gnu packages maths)
25 #:use-module (gnu packages python)
26 #:use-module (guix build-system python))
27
28 (define-public domainfinder
29 (package
30 (name "domainfinder")
31 (version "2.0.5")
32 (source
33 (origin
34 (method url-fetch)
35 (uri (string-append "https://bitbucket.org/khinsen/"
36 "domainfinder/downloads/DomainFinder-"
37 version ".tar.gz"))
38 (sha256
39 (base32
40 "1z26lsyf7xwnzwjvimmbla7ckipx6p734w7y0jk2a2fzci8fkdcr"))))
41 (build-system python-build-system)
42 (inputs
43 `(("python-mmtk" ,python2-mmtk)))
44 (arguments
45 `(#:python ,python-2
46 ;; No test suite
47 #:tests? #f))
48 (home-page "http://dirac.cnrs-orleans.fr/DomainFinder")
49 (synopsis "Analysis of dynamical domains in proteins")
50 (description "DomainFinder is an interactive program for the determination
51 and characterization of dynamical domains in proteins. It can infer dynamical
52 domains by comparing two protein structures, or from normal mode analysis on a
53 single structure. The software is currently not actively maintained and works
54 only with Python 2 and NumPy < 1.9.")
55 (license license:cecill-c)))
56
57 (define with-numpy-1.8
58 (package-input-rewriting `((,python2-numpy . ,python2-numpy-1.8))))
59
60 (define-public nmoldyn
61 (package
62 (name "nmoldyn")
63 (version "3.0.11")
64 (source
65 (origin
66 (method url-fetch)
67 (uri (string-append "https://bitbucket.org/khinsen/"
68 "nmoldyn3/downloads/nMOLDYN-"
69 version ".tar.gz"))
70 (sha256
71 (base32
72 "1mvmz3lkr217kdrd8cvdr1d82y58wp1403c9rnd943mijgq8xb5a"))))
73 (build-system python-build-system)
74 (inputs
75 `(("python-matplotlib" ,(with-numpy-1.8 python2-matplotlib))
76 ("python-scientific", python2-scientific)
77 ("netcdf", netcdf)
78 ("gv" ,gv)))
79 (propagated-inputs
80 `(("python-mmtk" ,python2-mmtk)))
81 (arguments
82 `(#:python ,python-2
83 #:tests? #f ; No test suite
84 #:phases
85 (modify-phases %standard-phases
86 (add-before 'build 'create-linux2-directory
87 (lambda _
88 (mkdir-p "nMOLDYN/linux2")))
89 (add-before 'build 'change-PDF-viewer
90 (lambda* (#:key inputs #:allow-other-keys)
91 (substitute* "nMOLDYN/Preferences.py"
92 ;; Set the paths for external executables, substituting
93 ;; gv for acroread.
94 ;; There is also vmd_path, but VMD is not free software
95 ;; and Guix contains currently no free molecular viewer that
96 ;; could be substituted.
97 (("PREFERENCES\\['acroread_path'\\] = ''")
98 (format "PREFERENCES['acroread_path'] = '~a'"
99 (which "gv")))
100 (("PREFERENCES\\['ncdump_path'\\] = ''")
101 (format "PREFERENCES['ncdump_path'] = '~a'"
102 (which "ncdump")))
103 (("PREFERENCES\\['ncgen_path'\\] = ''")
104 (format "PREFERENCES['ncgen_path'] = '~a'"
105 (which "ncgen3")))
106 (("PREFERENCES\\['task_manager_path'\\] = ''")
107 (format "PREFERENCES['task_manager_path'] = '~a'"
108 (which "task_manager")))
109 ;; Show documentation as PDF
110 (("PREFERENCES\\['documentation_style'\\] = 'html'")
111 "PREFERENCES['documentation_style'] = 'pdf'") ))))))
112 (home-page "http://dirac.cnrs-orleans.fr/nMOLDYN/")
113 (synopsis "Analysis software for Molecular Dynamics trajectories")
114 (description "nMOLDYN is an interactive analysis program for Molecular Dynamics
115 simulations. It is especially designed for the computation and decomposition of
116 neutron scattering spectra, but also computes other quantities. The software
117 is currently not actively maintained and works only with Python 2 and
118 NumPy < 1.9.")
119 (license license:cecill)))