summaryrefslogtreecommitdiff
path: root/gnu/packages/databases.scm
diff options
context:
space:
mode:
authorMarius Bakke <mbakke@fastmail.com>2019-10-23 20:48:55 +0200
committerMarius Bakke <mbakke@fastmail.com>2019-10-23 20:48:55 +0200
commit4c1918db34e09f0da793c607acc161bdf9ec5535 (patch)
treee84431dc161ed3c04c9b94abe8224ec7f759df5f /gnu/packages/databases.scm
parente8062974d5cc598134da4d57ff45970ac431611b (diff)
parent4163b6d855a4e655852029625762fccb077a196d (diff)
downloadpatches-4c1918db34e09f0da793c607acc161bdf9ec5535.tar
patches-4c1918db34e09f0da793c607acc161bdf9ec5535.tar.gz
Merge branch 'master' into staging
Diffstat (limited to 'gnu/packages/databases.scm')
-rw-r--r--gnu/packages/databases.scm73
1 files changed, 72 insertions, 1 deletions
diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm
index f32728b902..9373f7d9a9 100644
--- a/gnu/packages/databases.scm
+++ b/gnu/packages/databases.scm
@@ -216,6 +216,68 @@ standard Go idioms.")
(home-page "http://labix.org/mgo")
(license license:bsd-2)))
+(define-public ephemeralpg
+ (package
+ (name "ephemeralpg")
+ (version "2.8")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append
+ "http://eradman.com/ephemeralpg/code/ephemeralpg-"
+ version ".tar.gz"))
+ (sha256
+ (base32 "1dpfxsd8a52psx3zlfbqkw53m35w28qwyb87a8anz143x6gnkkr4"))))
+ (build-system gnu-build-system)
+ (arguments
+ '(#:make-flags (list "CC=gcc"
+ (string-append "PREFIX=" %output))
+ #:phases
+ (modify-phases %standard-phases
+ (delete 'configure)
+ (replace 'check
+ (lambda* (#:key inputs #:allow-other-keys)
+ ;; The intention for one test is to test without PostgreSQL on
+ ;; the $PATH, so replace the test $PATH with just the util-linux
+ ;; bin, which contains getopt. It will hopefully be possible to
+ ;; remove this for releases after 2.8.
+ (substitute* "test.rb"
+ (("/bin:/usr/bin")
+ (string-append (assoc-ref inputs "util-linux")
+ "/bin")))
+ ;; Set the LC_ALL=C as some tests use sort, and the locale
+ ;; affects the order. It will hopefully be possible to remove
+ ;; this for releases after 2.8.
+ (setenv "LC_ALL" "C")
+ (invoke "ruby" "test.rb")
+ #t))
+ (add-after 'install 'wrap
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out")))
+ (wrap-program (string-append out "/bin/pg_tmp")
+ `("PATH" ":" prefix
+ (,(string-append (assoc-ref inputs "util-linux")
+ "/bin")
+ ,(string-append (assoc-ref inputs "postgresql")
+ "/bin")
+ ;; For getsocket
+ ,(string-append out "/bin")))))
+ #t)))))
+ (inputs
+ `(("postgresql" ,postgresql)
+ ("util-linux" ,util-linux)))
+ (native-inputs
+ `(("ruby" ,ruby)))
+ (home-page "http://eradman.com/ephemeralpg/")
+ (synopsis "Run temporary PostgreSQL databases")
+ (description
+ "@code{pg_tmp} creates temporary PostgreSQL databases, suitable for tasks
+like running software test suites. Temporary databases created with
+@code{pg_tmp} have a limited shared memory footprint and are automatically
+garbage-collected after a configurable number of seconds (the default is
+60).")
+ (license license:isc)))
+
(define-public es-dump-restore
(package
(name "es-dump-restore")
@@ -436,7 +498,7 @@ replacement for the code@{python-memcached} library.")
(search-patch "mongodb-support-unknown-linux-distributions.patch")))))
(build-system scons-build-system)
(inputs
- `(("openssl" ,openssl)
+ `(("openssl" ,openssl-1.0)
("pcre" ,pcre)
,@(match (%current-system)
((or "x86_64-linux" "aarch64-linux" "mips64el-linux")
@@ -476,6 +538,15 @@ replacement for the code@{python-memcached} library.")
,(format #f "--jobs=~a" (parallel-job-count))
"--ssl")))
(modify-phases %standard-phases
+ (add-after 'unpack 'patch
+ (lambda _
+ ;; Remove use of GNU extensions in parse_number_test.cpp, to
+ ;; allow compiling with GCC 7 or later
+ ;; https://jira.mongodb.org/browse/SERVER-28063
+ (substitute* "src/mongo/base/parse_number_test.cpp"
+ (("0xabcab\\.defdefP-10")
+ "687.16784283419838"))
+ #t))
(add-after 'unpack 'scons-propagate-environment
(lambda _
;; Modify the SConstruct file to arrange for