* [bug#32138] [PATCH] gnu: Add inchi.
@ 2018-07-13 13:39 Kei Kebreau
2018-07-13 14:10 ` Jelle Licht
0 siblings, 1 reply; 5+ messages in thread
From: Kei Kebreau @ 2018-07-13 13:39 UTC (permalink / raw)
To: 32138; +Cc: Kei Kebreau
* gnu/packages/chemistry.scm (inchi): New variable.
---
gnu/packages/chemistry.scm | 3 +++
1 file changed, 3 insertions(+)
diff --git a/gnu/packages/chemistry.scm b/gnu/packages/chemistry.scm
index f1359b2cf..df79f252b 100644
--- a/gnu/packages/chemistry.scm
+++ b/gnu/packages/chemistry.scm
@@ -1,5 +1,6 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2018 Konrad Hinsen <konrad.hinsen@fastmail.net>
+;;; Copyright © 2018 Kei Kebreau <kkebreau@posteo.net>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -20,9 +21,11 @@
#:use-module (guix packages)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix download)
+ #:use-module (gnu packages compression)
#:use-module (gnu packages gv)
#:use-module (gnu packages maths)
#:use-module (gnu packages python)
+ #:use-module (guix build-system gnu)
#:use-module (guix build-system python))
(define-public domainfinder
--
2.18.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [bug#32138] [PATCH] gnu: Add inchi.
2018-07-13 13:39 [bug#32138] [PATCH] gnu: Add inchi Kei Kebreau
@ 2018-07-13 14:10 ` Jelle Licht
2018-07-13 19:01 ` Kei Kebreau
0 siblings, 1 reply; 5+ messages in thread
From: Jelle Licht @ 2018-07-13 14:10 UTC (permalink / raw)
To: Kei Kebreau; +Cc: 32138
Kei Kebreau <kkebreau@posteo.net> writes:
> * gnu/packages/chemistry.scm (inchi): New variable.
> ---
> gnu/packages/chemistry.scm | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/gnu/packages/chemistry.scm b/gnu/packages/chemistry.scm
> index f1359b2cf..df79f252b 100644
> --- a/gnu/packages/chemistry.scm
> +++ b/gnu/packages/chemistry.scm
> @@ -1,5 +1,6 @@
> ;;; GNU Guix --- Functional package management for GNU
> ;;; Copyright © 2018 Konrad Hinsen <konrad.hinsen@fastmail.net>
> +;;; Copyright © 2018 Kei Kebreau <kkebreau@posteo.net>
> ;;;
> ;;; This file is part of GNU Guix.
> ;;;
> @@ -20,9 +21,11 @@
> #:use-module (guix packages)
> #:use-module ((guix licenses) #:prefix license:)
> #:use-module (guix download)
> + #:use-module (gnu packages compression)
> #:use-module (gnu packages gv)
> #:use-module (gnu packages maths)
> #:use-module (gnu packages python)
> + #:use-module (guix build-system gnu)
> #:use-module (guix build-system python))
>
> (define-public domainfinder
It seems you forgot to commit the actual package definition :-).
^ permalink raw reply [flat|nested] 5+ messages in thread
* [bug#32138] [PATCH] gnu: Add inchi.
2018-07-13 14:10 ` Jelle Licht
@ 2018-07-13 19:01 ` Kei Kebreau
2018-07-13 21:38 ` Leo Famulari
0 siblings, 1 reply; 5+ messages in thread
From: Kei Kebreau @ 2018-07-13 19:01 UTC (permalink / raw)
To: Jelle Licht; +Cc: 32138
[-- Attachment #1.1: Type: text/plain, Size: 1244 bytes --]
Jelle Licht <jlicht@fsfe.org> writes:
> Kei Kebreau <kkebreau@posteo.net> writes:
>
>> * gnu/packages/chemistry.scm (inchi): New variable.
>> ---
>> gnu/packages/chemistry.scm | 3 +++
>> 1 file changed, 3 insertions(+)
>>
>> diff --git a/gnu/packages/chemistry.scm b/gnu/packages/chemistry.scm
>> index f1359b2cf..df79f252b 100644
>> --- a/gnu/packages/chemistry.scm
>> +++ b/gnu/packages/chemistry.scm
>> @@ -1,5 +1,6 @@
>> ;;; GNU Guix --- Functional package management for GNU
>> ;;; Copyright © 2018 Konrad Hinsen <konrad.hinsen@fastmail.net>
>> +;;; Copyright © 2018 Kei Kebreau <kkebreau@posteo.net>
>> ;;;
>> ;;; This file is part of GNU Guix.
>> ;;;
>> @@ -20,9 +21,11 @@
>> #:use-module (guix packages)
>> #:use-module ((guix licenses) #:prefix license:)
>> #:use-module (guix download)
>> + #:use-module (gnu packages compression)
>> #:use-module (gnu packages gv)
>> #:use-module (gnu packages maths)
>> #:use-module (gnu packages python)
>> + #:use-module (guix build-system gnu)
>> #:use-module (guix build-system python))
>>
>> (define-public domainfinder
>
> It seems you forgot to commit the actual package definition :-).
Whoops! Let's try this again!
[-- Attachment #1.2: 0001-gnu-Add-inchi.patch --]
[-- Type: text/plain, Size: 5226 bytes --]
From d132ab76417f238f914eb681a1c0f81b2375a1f9 Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kkebreau@posteo.net>
Date: Fri, 13 Jul 2018 09:35:27 -0400
Subject: [PATCH] gnu: Add inchi.
* gnu/packages/chemistry.scm (inchi): New variable.
---
gnu/packages/chemistry.scm | 81 ++++++++++++++++++++++++++++++++++++++
1 file changed, 81 insertions(+)
diff --git a/gnu/packages/chemistry.scm b/gnu/packages/chemistry.scm
index f1359b2cf..1a5086d62 100644
--- a/gnu/packages/chemistry.scm
+++ b/gnu/packages/chemistry.scm
@@ -1,5 +1,6 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2018 Konrad Hinsen <konrad.hinsen@fastmail.net>
+;;; Copyright © 2018 Kei Kebreau <kkebreau@posteo.net>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -20,9 +21,11 @@
#:use-module (guix packages)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix download)
+ #:use-module (gnu packages compression)
#:use-module (gnu packages gv)
#:use-module (gnu packages maths)
#:use-module (gnu packages python)
+ #:use-module (guix build-system gnu)
#:use-module (guix build-system python))
(define-public domainfinder
@@ -54,6 +57,84 @@ single structure. The software is currently not actively maintained and works
only with Python 2 and NumPy < 1.9.")
(license license:cecill-c)))
+(define-public inchi
+ (package
+ (name "inchi")
+ (version "1.05")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://www.inchi-trust.org/download/"
+ (string-join (string-split version #\.) "")
+ "/INCHI-1-SRC.zip"))
+ (sha256
+ (base32
+ "081pcjx1z5jm23fs1pl2r3bccia0ww8wfkzcjpb7byhn7b513hsa"))
+ (file-name (string-append name "-" version ".zip"))))
+ (build-system gnu-build-system)
+ (arguments
+ '(#:tests? #f ; no check target
+ #:phases
+ (modify-phases %standard-phases
+ (delete 'configure) ; no configure script
+ (add-before 'build 'chdir-to-build-directory
+ (lambda _ (chdir "INCHI_EXE/inchi-1/gcc") #t))
+ (add-after 'build 'build-library
+ (lambda _
+ (chdir "../../../INCHI_API/libinchi/gcc")
+ (invoke "make")))
+ (replace 'install
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (bin (string-append out "/bin"))
+ (doc (string-append out "/share/doc/inchi"))
+ (include-dir (string-append out "/include/inchi"))
+ (lib (string-append out "/lib/inchi"))
+ (inchi-doc (assoc-ref inputs "inchi-doc"))
+ (unzip (string-append (assoc-ref inputs "unzip")
+ "/bin/unzip")))
+ (chdir "../../..")
+ ;; Install binary.
+ (with-directory-excursion "INCHI_EXE/bin/Linux"
+ (rename-file "inchi-1" "inchi")
+ (install-file "inchi" bin))
+ ;; Install libraries.
+ (with-directory-excursion "INCHI_API/bin/Linux"
+ (for-each (lambda (file)
+ (install-file file lib))
+ (find-files "." "libinchi\\.so\\.1\\.*")))
+ ;; Install header files.
+ (with-directory-excursion "INCHI_BASE/src"
+ (for-each (lambda (file)
+ (install-file file include-dir))
+ (find-files "." "\\.h$")))
+ ;; Install documentation.
+ (mkdir-p doc)
+ (invoke unzip "-j" "-d" doc inchi-doc)
+ #t))))))
+ (native-inputs
+ `(("unzip" ,unzip)
+ ("inchi-doc"
+ ,(origin
+ (method url-fetch)
+ (uri (string-append "http://www.inchi-trust.org/download/"
+ (string-join (string-split version #\.) "")
+ "/INCHI-1-DOC.zip"))
+ (sha256
+ (base32
+ "1id1qb2y4lwsiw91qr2yqpn6kxbwjwhjk0hb2rwk4fxhdqib6da6"))
+ (file-name (string-append name "-" version ".zip"))))))
+ (home-page "https://www.inchi-trust.org")
+ (synopsis "Utility for manipulating machine-readable chemical structures")
+ (description
+ "The @dfn{InChI} (IUPAC International Chemical Identifier) algorithm turns
+chemical structures into machine-readable strings of information. InChIs are
+unique to the compound they describe and can encode absolute stereochemistry
+making chemicals and chemistry machine-readable and discoverable. A simple
+analogy is that InChI is the bar-code for chemistry and chemical structures.")
+ (license (license:non-copyleft
+ "file://LICENCE"
+ "See LICENCE in the distribution."))))
+
(define with-numpy-1.8
(package-input-rewriting `((,python2-numpy . ,python2-numpy-1.8))))
--
2.18.0
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [bug#32138] [PATCH] gnu: Add inchi.
2018-07-13 19:01 ` Kei Kebreau
@ 2018-07-13 21:38 ` Leo Famulari
2018-07-14 2:22 ` bug#32138: " Kei Kebreau
0 siblings, 1 reply; 5+ messages in thread
From: Leo Famulari @ 2018-07-13 21:38 UTC (permalink / raw)
To: Kei Kebreau; +Cc: 32138
[-- Attachment #1: Type: text/plain, Size: 332 bytes --]
On Fri, Jul 13, 2018 at 03:01:47PM -0400, Kei Kebreau wrote:
> From d132ab76417f238f914eb681a1c0f81b2375a1f9 Mon Sep 17 00:00:00 2001
> From: Kei Kebreau <kkebreau@posteo.net>
> Date: Fri, 13 Jul 2018 09:35:27 -0400
> Subject: [PATCH] gnu: Add inchi.
>
> * gnu/packages/chemistry.scm (inchi): New variable.
LGTM, thanks!
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#32138: [PATCH] gnu: Add inchi.
2018-07-13 21:38 ` Leo Famulari
@ 2018-07-14 2:22 ` Kei Kebreau
0 siblings, 0 replies; 5+ messages in thread
From: Kei Kebreau @ 2018-07-14 2:22 UTC (permalink / raw)
To: Leo Famulari; +Cc: 32138-done
[-- Attachment #1: Type: text/plain, Size: 466 bytes --]
Leo Famulari <leo@famulari.name> writes:
> On Fri, Jul 13, 2018 at 03:01:47PM -0400, Kei Kebreau wrote:
>> From d132ab76417f238f914eb681a1c0f81b2375a1f9 Mon Sep 17 00:00:00 2001
>> From: Kei Kebreau <kkebreau@posteo.net>
>> Date: Fri, 13 Jul 2018 09:35:27 -0400
>> Subject: [PATCH] gnu: Add inchi.
>>
>> * gnu/packages/chemistry.scm (inchi): New variable.
>
> LGTM, thanks!
Thanks for reviewing! There are more chemistry-related packages on the way.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2018-07-14 2:24 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-07-13 13:39 [bug#32138] [PATCH] gnu: Add inchi Kei Kebreau
2018-07-13 14:10 ` Jelle Licht
2018-07-13 19:01 ` Kei Kebreau
2018-07-13 21:38 ` Leo Famulari
2018-07-14 2:22 ` bug#32138: " Kei Kebreau
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).