[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug#30214] [PATCH 06/10] gnu: Add go-gopkg.in-mgo.v2.
From: |
Christopher Baines |
Subject: |
[bug#30214] [PATCH 06/10] gnu: Add go-gopkg.in-mgo.v2. |
Date: |
Sat, 27 Jan 2018 15:00:23 +0000 |
* gnu/packages/databases.scm (go-gopkg.in-mgo.v2): New variable.
---
gnu/packages/databases.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 44 insertions(+)
diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm
index 4b2bdb6d3..fabfbfe5b 100644
--- a/gnu/packages/databases.scm
+++ b/gnu/packages/databases.scm
@@ -49,6 +49,7 @@
(define-module (gnu packages databases)
#:use-module (gnu packages)
+ #:use-module (gnu packages admin)
#:use-module (gnu packages algebra)
#:use-module (gnu packages autotools)
#:use-module (gnu packages avahi)
@@ -94,6 +95,7 @@
#:use-module (guix download)
#:use-module (guix git-download)
#:use-module (guix build-system gnu)
+ #:use-module (guix build-system go)
#:use-module (guix build-system perl)
#:use-module (guix build-system python)
#:use-module (guix build-system ruby)
@@ -173,6 +175,48 @@ store key/value pairs in a file in a manner similar to the
Unix dbm library
and provides interfaces to the traditional file format.")
(license license:gpl3+)))
+(define-public go-gopkg.in-mgo.v2
+ (package
+ (name "go-gopkg.in-mgo.v2")
+ (version "2016.08.01")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/go-mgo/mgo")
+ (commit (string-append "r" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0rwbi1z63w43b0z9srm8m7iz1fdwx7bq7n2mz862d6liiaqa59jd"))))
+ (build-system go-build-system)
+ (arguments
+ `(#:import-path "gopkg.in/mgo.v2"
+ #:tests? #f
+ #:phases
+ (modify-phases %standard-phases
+ (delete 'reset-gzip-timestamps)
+ (add-before 'check 'start-mongodb
+ (lambda* (#:key tests? #:allow-other-keys)
+ (or (not tests?)
+ (with-directory-excursion "src/gopkg.in/mgo.v2"
+ (invoke "make" "startdb")))))
+ (add-after 'check 'stop'mongodb
+ (lambda* (#:key tests? #:allow-other-keys)
+ (or (not tests?)
+ (with-directory-excursion "src/gopkg.in/mgo.v2"
+ (invoke "make" "stopdb"))))))))
+ (native-inputs
+ `(("go-gopkg.in-check.v1" ,go-gopkg.in-check.v1)
+ ("mongodb" ,mongodb)
+ ("daemontools" ,daemontools)))
+ (synopsis "@code{mgo} offers a rich MongoDB driver for Go.")
+ (description
+ "@code{mgo} (pronounced as mango) is a MongoDB driver for the Go language.
+It implements a rich selection of features under a simple API following
+standard Go idioms.")
+ (home-page "http://labix.org/mgo")
+ (license license:bsd-2)))
+
(define-public bdb
(package
(name "bdb")
--
2.15.1
- [bug#30214] [PATCH 10/10] gnu: Add mongo-tools., (continued)
- [bug#30214] [PATCH 01/10] gnu: Add go-golang.org-x-crypto-ssh-terminal., Christopher Baines, 2018/01/27
- [bug#30214] [PATCH 08/10] gnu: Add go-github.com-mattn-go-runewidth., Christopher Baines, 2018/01/27
- [bug#30214] [PATCH 05/10] gnu: Add daemontools., Christopher Baines, 2018/01/27
- [bug#30214] [PATCH 03/10] gnu: Add go-github.com-jessevdk-go-flags., Christopher Baines, 2018/01/27
- [bug#30214] [PATCH 02/10] gnu: Add go-github.com-howeyc-gopass., Christopher Baines, 2018/01/27
- [bug#30214] [PATCH 07/10] gnu: Add go-gopkg.in-tomb.v2., Christopher Baines, 2018/01/27
- [bug#30214] [PATCH 10/10] gnu: Add mongo-tools., Christopher Baines, 2018/01/27
- [bug#30214] [PATCH 06/10] gnu: Add go-gopkg.in-mgo.v2.,
Christopher Baines <=
- [bug#30214] [PATCH 09/10] gnu: Add go-github.com-nsf-termbox-go., Christopher Baines, 2018/01/27
- [bug#30214] [PATCH 04/10] gnu: Add go-gopkg.in-check.v1., Christopher Baines, 2018/01/27
- [bug#30214] [PATCH 01/10] gnu: Add go-golang.org-x-crypto-ssh-terminal., Leo Famulari, 2018/01/29