1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2015, 2016 Andreas Enge <andreas@enge.fr>
3 ;;; Copyright © 2016, 2017, 2018 Efraim Flashner <efraim@flashner.co.il>
4 ;;; Copyright © 2016 Alex Griffin <a@ajgrf.com>
5 ;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com>
6 ;;; Copyright © 2017 Carlo Zancanaro <carlo@zancanaro.id.au>
7 ;;; Copyright © 2017 Theodoros Foradis <theodoros@foradis.org>
8 ;;; Copyright © 2017 Vasile Dumitrascu <va511e@yahoo.com>
9 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
10 ;;; Copyright © 2018 Eric Bavier <bavier@member.fsf.org>
11 ;;; Copyright © 2018 Adriano Peluso <catonano@gmail.com>
12 ;;; Copyright © 2018, 2019, 2020 Nicolas Goaziou <mail@nicolasgoaziou.fr>
13 ;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
14 ;;; Copyright © 2019, 2020 Guillaume Le Vaillant <glv@posteo.net>
15 ;;; Copyright © 2019 Tanguy Le Carrour <tanguy@bioneland.org>
16 ;;; Copyright © 2019, 2020 Martin Becze <mjbecze@riseup.net>
17 ;;; Copyright © 2019 Sebastian Schott <sschott@mailbox.org>
18 ;;; Copyright © 2020 Kei Kebreau <kkebreau@posteo.net>
19 ;;; Copyright © 2020 Christopher Lemmer Webber <cwebber@dustycloud.org>
20 ;;; Copyright © 2020 Tom Zander <tomz@freedommail.ch>
21 ;;; Copyright © 2020 Marius Bakke <mbakke@fastmail.com>
22 ;;; Copyright © 2020 Vinicius Monego <monego@posteo.net>
24 ;;; This file is part of GNU Guix.
26 ;;; GNU Guix is free software; you can redistribute it and/or modify it
27 ;;; under the terms of the GNU General Public License as published by
28 ;;; the Free Software Foundation; either version 3 of the License, or (at
29 ;;; your option) any later version.
31 ;;; GNU Guix is distributed in the hope that it will be useful, but
32 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
33 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
34 ;;; GNU General Public License for more details.
36 ;;; You should have received a copy of the GNU General Public License
37 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
39 (define-module (gnu packages finance)
40 #:use-module ((guix licenses) #:prefix license:)
41 #:use-module (guix packages)
42 #:use-module (guix download)
43 #:use-module (guix git-download)
44 #:use-module (guix build-system gnu)
45 #:use-module (guix build-system cmake)
46 #:use-module (guix build-system copy)
47 #:use-module (guix build-system emacs)
48 #:use-module (guix build-system python)
49 #:use-module (guix build-system glib-or-gtk)
50 #:use-module (guix build-system go)
51 #:use-module (guix build-system qt)
52 #:use-module (guix utils)
53 #:use-module (gnu packages)
54 #:use-module (gnu packages aidc)
55 #:use-module (gnu packages autotools)
56 #:use-module (gnu packages base)
57 #:use-module (gnu packages boost)
58 #:use-module (gnu packages check)
59 #:use-module (gnu packages compression)
60 #:use-module (gnu packages crypto)
61 #:use-module (gnu packages curl)
62 #:use-module (gnu packages databases)
63 #:use-module (gnu packages docbook)
64 #:use-module (gnu packages documentation)
65 #:use-module (gnu packages dns)
66 #:use-module (gnu packages emacs)
67 #:use-module (gnu packages dbm)
68 #:use-module (gnu packages gettext)
69 #:use-module (gnu packages gnome)
70 #:use-module (gnu packages glib)
71 #:use-module (gnu packages gnupg)
72 #:use-module (gnu packages graphviz)
73 #:use-module (gnu packages groff)
74 #:use-module (gnu packages gtk)
75 #:use-module (gnu packages jemalloc)
76 #:use-module (gnu packages libedit)
77 #:use-module (gnu packages libevent)
78 #:use-module (gnu packages libunwind)
79 #:use-module (gnu packages libusb)
80 #:use-module (gnu packages linux)
81 #:use-module (gnu packages man)
82 #:use-module (gnu packages multiprecision)
83 #:use-module (gnu packages networking)
84 #:use-module (gnu packages pkg-config)
85 #:use-module (gnu packages popt)
86 #:use-module (gnu packages protobuf)
87 #:use-module (gnu packages python)
88 #:use-module (gnu packages python-crypto)
89 #:use-module (gnu packages python-web)
90 #:use-module (gnu packages python-xyz)
91 #:use-module (gnu packages qt)
92 #:use-module (gnu packages readline)
93 #:use-module (gnu packages sphinx)
94 #:use-module (gnu packages texinfo)
95 #:use-module (gnu packages textutils)
96 #:use-module (gnu packages time)
97 #:use-module (gnu packages tls)
98 #:use-module (gnu packages upnp)
99 #:use-module (gnu packages web)
100 #:use-module (gnu packages xml)
101 #:use-module (gnu packages gnuzilla))
103 (define-public bitcoin-core
105 (name "bitcoin-core")
110 (string-append "https://bitcoincore.org/bin/bitcoin-core-"
111 version "/bitcoin-" version ".tar.gz"))
114 "1h3w7brc18145np920vy7j5ms5hym59hvr40swdjx34fbdaisngj"))
115 (patches (search-patches "bitcoin-core-python-compat.patch"))))
116 (build-system gnu-build-system)
118 `(("pkg-config" ,pkg-config)
119 ("python" ,python) ; for the tests
120 ("util-linux" ,util-linux) ; provides the hexdump command for tests
121 ("qttools" ,qttools)))
123 `(("bdb" ,bdb-4.8) ; 4.8 required for compatibility
125 ("libevent" ,libevent)
126 ("miniupnpc" ,miniupnpc)
128 ("protobuf" ,protobuf)
133 ;; Boost is not found unless specified manually.
134 (string-append "--with-boost="
135 (assoc-ref %build-inputs "boost"))
136 ;; XXX: The configure script looks up Qt paths by
137 ;; `pkg-config --variable=host_bins Qt5Core`, which fails to pick
138 ;; up executables residing in 'qttools', so we specify them here.
139 (string-append "ac_cv_path_LRELEASE="
140 (assoc-ref %build-inputs "qttools")
142 (string-append "ac_cv_path_LUPDATE="
143 (assoc-ref %build-inputs "qttools")
146 (modify-phases %standard-phases
147 (add-before 'configure 'make-qt-deterministic
149 ;; Make Qt deterministic.
150 (setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1")
152 (add-before 'check 'set-home
154 (setenv "HOME" (getenv "TMPDIR")) ; tests write to $HOME
156 (add-after 'check 'check-functional
159 "python3" "./test/functional/test_runner.py"
160 (string-append "--jobs=" (number->string (parallel-job-count))))
162 (home-page "https://bitcoin.org/en/")
163 (synopsis "Bitcoin peer-to-peer client")
165 "Bitcoin is a digital currency that enables instant payments to anyone
166 anywhere in the world. It uses peer-to-peer technology to operate without
167 central authority: managing transactions and issuing money are carried out
168 collectively by the network. Bitcoin Core is the reference implementation
169 of the bitcoin protocol. This package provides the Bitcoin Core command
170 line client and a client based on Qt.")
171 (license license:expat)))
173 (define-public homebank
179 (uri (string-append "http://homebank.free.fr/public/homebank-"
183 "0bkjvd819kw9cwmr3macggbg8yil3yc8v2za8pjrl6g746s89kn6"))))
184 (build-system glib-or-gtk-build-system)
186 `(("pkg-config" ,pkg-config)
187 ("intltool" ,intltool)))
191 ("libsoup" ,libsoup)))
192 (home-page "http://homebank.free.fr/")
193 (synopsis "Graphical personal accounting application")
194 (description "HomeBank allows you to manage your personal accounts at
195 home. The seeks to be lightweight, simple and easy to use. It brings
196 features that allow you to analyze your finances in a detailed way instantly
197 and dynamically with report tools based on filtering and graphical charts.")
198 (license license:gpl2+)))
200 (define-public ledger
208 (url "https://github.com/ledger/ledger")
209 (commit (string-append "v" version))))
210 (file-name (git-file-name name version))
212 (base32 "0x6jxwss3wwzbzlwmnwb8yzjk8f9wfawif4f1b74z2qg6hc4r7f6"))))
213 (build-system cmake-build-system)
215 `(#:modules (,@%cmake-build-system-modules
216 ((guix build python-build-system) #:select (python-version)))
217 #:imported-modules (,@%cmake-build-system-modules
218 (guix build python-build-system))
220 `("-DBUILD_DOCS:BOOL=ON"
221 "-DBUILD_WEB_DOCS:BOOL=ON"
222 "-DUSE_PYTHON:BOOL=ON"
223 "-DCMAKE_INSTALL_LIBDIR:PATH=lib")
225 (modify-phases (@ (guix build cmake-build-system) %standard-phases)
226 (add-after 'unpack 'fix-python-installation-directory
227 (lambda* (#:key inputs outputs #:allow-other-keys)
228 ;; By default the package attempts to install its Python bindings
229 ;; to the Python store directory, which obviously does not work.
230 ;; Passing -DPython_SITEARCH in #:configure-flags has no effect.
231 (let ((python-version (python-version (assoc-ref inputs "python")))
232 (out (assoc-ref outputs "out")))
233 (substitute* "src/CMakeLists.txt"
234 (("DESTINATION \\$\\{Python_SITEARCH\\}")
235 (string-append "DESTINATION " out "/lib/python"
236 python-version "/site-packages")))
238 (add-before 'configure 'install-examples
239 (lambda* (#:key outputs #:allow-other-keys)
240 (let ((examples (string-append (assoc-ref outputs "out")
241 "/share/doc/ledger/examples")))
242 (install-file "test/input/sample.dat" examples)
243 (install-file "test/input/demo.ledger" examples))
245 (add-after 'build 'build-doc
246 (lambda _ (invoke "make" "doc")))
247 (add-before 'check 'check-setup
248 ;; One test fails if it can't set the timezone.
249 (lambda* (#:key inputs #:allow-other-keys)
251 (string-append (assoc-ref inputs "tzdata")
253 ;; Skip failing test BaselineTest_cmd-org.
254 ;; This is a known upstream issue. See
255 ;; https://github.com/ledger/ledger/issues/550
256 (setenv "ARGS" "-E BaselineTest_cmd-org")
268 ("tzdata" ,tzdata-for-tests)))
269 (home-page "https://ledger-cli.org/")
270 (synopsis "Command-line double-entry accounting program")
272 "Ledger is a powerful, double-entry accounting system that is
273 accessed from the UNIX command-line. This may put off some users, since
274 there is no flashy UI, but for those who want unparalleled reporting
275 access to their data there are few alternatives.
277 Ledger uses text files for input. It reads the files and generates
278 reports; there is no other database or stored state. To use Ledger,
279 you create a file of your account names and transactions, run from the
280 command line with some options to specify input and requested reports, and
281 get output. The output is generally plain text, though you could generate
282 a graph or html instead. Ledger is simple in concept, surprisingly rich
283 in ability, and easy to use.")
284 ;; There are some extra licenses in files which do not presently get
285 ;; installed when you build this package. Different versions of the GPL
286 ;; are used in the contrib and python subdirectories. The bundled version
287 ;; of utfcpp is under the Boost 1.0 license. Also the file
288 ;; `tools/update_copyright_year` has an Expat license.
289 (license (list license:bsd-3
290 license:asl2.0 ; src/strptime.cc
291 (license:non-copyleft
292 "file://src/wcwidth.cc"
293 "See src/wcwidth.cc in the distribution.")))))
295 (define-public emacs-ledger-mode
296 ;; There have been no new releases since 2016.
297 (let ((commit "253a20dc62e137ed0ed8e1dd8614ecba116610ea")
300 (name "emacs-ledger-mode")
301 (version (git-version "3.1.1" revision commit))
306 (url "https://github.com/ledger/ledger-mode")
308 (file-name (git-file-name name version))
310 (base32 "06wrgkqpgvk17vibrk2qikdlqn8y63jg86marp1wgmram92mb3jk"))))
311 (build-system cmake-build-system)
313 `(#:modules ((guix build cmake-build-system)
315 (guix build emacs-utils))
316 #:imported-modules (,@%cmake-build-system-modules
317 (guix build emacs-utils))
318 #:tests? #f ; there are none
320 (modify-phases %standard-phases
321 (add-after 'unpack 'patch-site-dir
323 (substitute* "CMakeLists.txt"
324 (("DESTINATION share/emacs/site-lisp/ledger-mode")
325 "DESTINATION share/emacs/site-lisp"))
327 (add-before 'build 'patch-path
328 (lambda* (#:key inputs #:allow-other-keys)
329 (let ((ledger (assoc-ref inputs "ledger")))
330 (make-file-writable "ledger-exec.el")
331 (emacs-substitute-variables "ledger-exec.el"
332 ("ledger-binary-path" (string-append ledger "/bin/ledger"))))
334 (add-after 'build 'build-doc
335 (lambda* (#:key outputs #:allow-other-keys)
336 (let ((target (string-append (assoc-ref outputs "out")
339 (invoke "makeinfo" "-o" target
340 "../source/doc/ledger-mode.texi"))
342 (add-after 'install 'generate-autoload
343 (lambda* (#:key outputs #:allow-other-keys)
344 (let* ((site-dir (string-append (assoc-ref outputs "out")
345 "/share/emacs/site-lisp")))
346 (emacs-generate-autoloads ,name site-dir))
349 `(("ledger" ,ledger)))
351 `(("emacs-minimal" ,emacs-minimal)
352 ("texinfo" ,texinfo)))
353 (home-page "https://ledger-cli.org/")
354 (synopsis "Command-line double-entry accounting program")
356 "Ledger is a powerful, double-entry accounting system that is
357 accessed from the UNIX command-line. This may put off some users, since
358 there is no flashy UI, but for those who want unparalleled reporting
359 access to their data there are few alternatives.
361 Ledger uses text files for input. It reads the files and generates
362 reports; there is no other database or stored state. To use Ledger,
363 you create a file of your account names and transactions, run from the
364 command line with some options to specify input and requested reports, and
365 get output. The output is generally plain text, though you could generate
366 a graph or html instead. Ledger is simple in concept, surprisingly rich
367 in ability, and easy to use.
369 This package provides the Emacs mode.")
370 (license license:gpl2+))))
372 (define-public geierlein
380 (url "https://github.com/stesie/geierlein")
381 (commit (string-append "V" version))))
382 (file-name (git-file-name name version))
384 (base32 "00zpwr3lk2vdmd60fgdwdk0xxs52wvnm19ln2m75yfphydvkglic"))))
385 (build-system gnu-build-system)
387 `(#:tests? #f ; would require npm, python and a lot more
389 (modify-phases %standard-phases
390 (delete 'configure) ; no configure script
391 (add-after 'unpack 'override-target-directory-and-tool-paths
392 (lambda* (#:key inputs outputs #:allow-other-keys)
393 (substitute* "Makefile"
395 (string-append "prefix := " (assoc-ref outputs "out") "\n"))
396 ;; Required for tests, unused for now:
398 ;; (string-append (which "python") "\n")))
400 (string-append "INSTALL := " (which "install") "\n")))
401 (substitute* "bin/xgeierlein.in"
402 ;; Use icecat as XULRUNNER
404 (string-append "XULRUNNER=" (which "icecat") "\n"
408 `(("icecat" ,icecat)))
409 (home-page "https://stesie.github.io/geierlein/")
410 (synopsis "Free Elster client, for sending Germany VAT declarations")
412 "Geierlein is a free Elster client, i.e. an application that
413 sends VAT declarations to Germany's fiscal authorities.
415 Currently it is *not* possible to send returns that are due annually
416 (especially the income tax return) since the fiscal authority doesn't
417 allow doing that off the ERiC library (which is proprietary however).
418 It's not clear at the moment whether one day it will be possible to
420 (license license:agpl3+)))
422 (define-public electrum
429 (uri (string-append "https://download.electrum.org/"
433 (base32 "1g00cj1pmckd4xis8r032wmraiv3vd3zc803hnyxa2bnhj8z3bg2"))
434 (modules '((guix build utils)))
437 ;; Delete the bundled dependencies.
438 (delete-file-recursively "packages")
440 (build-system python-build-system)
442 `(("python-pyaes" ,python-pyaes)
443 ("python-pysocks" ,python-pysocks)
444 ("python-sip" ,python-sip)
445 ("python-pyqt" ,python-pyqt)
446 ("python-ecdsa" ,python-ecdsa)
447 ("python-pbkdf2" ,python-pbkdf2)
448 ("python-requests" ,python-requests)
449 ("python-qrcode" ,python-qrcode)
450 ("python-protobuf" ,python-protobuf)
451 ("python-aiohttp" ,python-aiohttp)
452 ("python-aiohttp-socks" ,python-aiohttp-socks)
453 ("python-aiorpcx" ,python-aiorpcx)
454 ("python-certifi" ,python-certifi)
455 ("python-dnspython" ,python-dnspython)
456 ("python-jsonrpclib-pelix" ,python-jsonrpclib-pelix)))
458 `(#:tests? #f ; no tests
460 (modify-phases %standard-phases
461 (add-after 'unpack 'fix-prefix
462 (lambda* (#:key outputs #:allow-other-keys)
463 (let ((out (assoc-ref outputs "out")))
464 ;; setup.py installs to ~/.local/share if sys.prefix/share isn't
465 ;; writable. sys.prefix points to Python's, not our, --prefix.
466 (mkdir-p (string-append out "/share"))
467 (substitute* "setup.py"
469 (format #f "\"~a\"" out)))
471 (home-page "https://electrum.org/")
472 (synopsis "Bitcoin wallet")
474 "Electrum is a lightweight Bitcoin client, based on a client-server
475 protocol. It supports Simple Payment Verification (SPV) and deterministic key
476 generation from a seed. Your secret keys are encrypted and are never sent to
477 other machines/servers. Electrum does not download the Bitcoin blockchain.")
478 (license license:expat)))
480 (define-public electron-cash
482 (name "electron-cash")
488 (url "https://github.com/Electron-Cash/Electron-Cash")
490 (file-name (git-file-name name version))
492 (base32 "1ccfm6kkmbkvykfdzrisxvr0lx9kgq4l43ixk6v3xnvhnbfwz4s2"))))
493 (build-system python-build-system)
495 `(("libevent" ,libevent)
496 ("libsecp256k1", libsecp256k1-bitcoin-cash)
498 ("python-cython" ,python-cython)
499 ("python-dateutil", python-dateutil)
500 ("python-dnspython" ,python-dnspython)
501 ("python-ecdsa" ,python-ecdsa)
502 ("python-hidapi" ,python-hidapi)
503 ("python-jsonrpclib-pelix" ,python-jsonrpclib-pelix)
504 ("python-keepkey" ,python-keepkey)
505 ("python-protobuf" ,python-protobuf)
506 ("python-pyaes" ,python-pyaes)
507 ("python-pyqt" ,python-pyqt)
508 ("python-pysocks" ,python-pysocks)
509 ("python-qrcode" ,python-qrcode)
510 ("python-requests" ,python-requests)
511 ("python-stem" ,python-stem)
512 ("python-trezor" ,python-trezor)
516 `(#:tests? #f ; no tests
517 #:modules ((guix build python-build-system)
518 (guix build qt-utils)
520 #:imported-modules (,@%python-build-system-modules
521 (guix build qt-utils))
523 (modify-phases %standard-phases
524 (add-after 'unpack 'create-output-directories
525 (lambda* (#:key outputs #:allow-other-keys)
526 ;; setup.py installs to ~/.local/share if this doesn't exist.
527 (mkdir-p (string-append (assoc-ref outputs "out") "/share"))
529 (add-after 'unpack 'use-libsecp256k1-input
530 (lambda* (#:key inputs #:allow-other-keys)
531 (substitute* "lib/secp256k1.py"
532 (("library_paths = .* 'libsecp256k1.so.0'.")
533 (string-append "library_paths = ('"
534 (assoc-ref inputs "libsecp256k1")
535 "/lib/libsecp256k1.so.0'")))
537 (add-after 'install 'wrap-qt
538 (lambda* (#:key outputs #:allow-other-keys)
539 (wrap-qt-program (assoc-ref outputs "out") "electron-cash")
541 (home-page "https://electroncash.org/")
542 (synopsis "Bitcoin Cash wallet")
544 "Electroncash is a lightweight Bitcoin Cash client, based on a client-server
545 protocol. It supports Simple Payment Verification (SPV) and deterministic key
546 generation from a seed. Your secret keys are encrypted and are never sent to
547 other machines/servers. Electroncash does not download the Bitcoin Cash blockchain.")
548 (license license:expat)))
550 (define-public monero
551 ;; This package bundles easylogging++ and lmdb.
552 ;; The bundled easylogging++ is modified, and the changes will not be
554 ;; The devs deem the lmdb driver too critical a consenus component, to use
555 ;; the system's dynamically linked library.
563 (url "https://github.com/monero-project/monero")
564 (commit (string-append "v" version))
566 (file-name (git-file-name name version))
567 (patches (search-patches "monero-use-system-miniupnpc.patch"))
568 (modules '((guix build utils)))
571 ;; Delete bundled dependencies.
573 delete-file-recursively
574 '("external/miniupnp" "external/rapidjson"
578 (base32 "1r9x3712vhb24dxxirfiwj5f9x0h4m7x0ngiiavf5983dfdlgz33"))))
579 (build-system cmake-build-system)
581 `(("doxygen" ,doxygen)
582 ("graphviz" ,graphviz)
583 ("pkg-config" ,pkg-config)
584 ("protobuf" ,protobuf)
586 ("qttools" ,qttools)))
592 ("libsodium" ,libsodium)
593 ("libunwind" ,libunwind)
595 ("miniupnpc" ,miniupnpc)
597 ("protobuf" ,protobuf)
598 ("rapidjson" ,rapidjson)
599 ("readline" ,readline)
604 `(#:out-of-source? #t
606 (list "-DARCH=default"
608 "-DBUILD_GUI_DEPS=ON"
609 (string-append "-DReadline_ROOT_DIR="
610 (assoc-ref %build-inputs "readline")))
612 (modify-phases %standard-phases
613 ;; tests/core_tests need a valid HOME
614 (add-before 'configure 'set-home
616 (setenv "HOME" (getcwd))
618 (add-after 'set-home 'change-log-path
620 (substitute* "contrib/epee/src/mlog.cpp"
621 (("epee::string_tools::get_current_module_folder\\(\\)")
624 "return ((std::string(getenv(\"HOME\"))) / "))
626 (add-after 'change-log-path 'fix-file-permissions-for-tests
628 (for-each make-file-writable
629 (find-files "tests/data/" "wallet_9svHk1.*"))
631 ;; Only try tests that don't need access to network or system
634 ;; Core tests sometimes fail, at least on i686-linux.
635 ;; Let's disable them for now and just try hash tests
637 ;; (invoke "make" "ARGS=-R 'hash|core_tests' --verbose" "test")))
638 (invoke "make" "ARGS=-R 'hash' --verbose" "test")))
639 (add-after 'check 'unit-tests
641 (let ((excluded-unit-tests
643 '("AddressFromURL.Success"
644 "AddressFromURL.Failure"
645 "DNSResolver.IPv4Success"
646 "DNSResolver.DNSSECSuccess"
647 "DNSResolver.DNSSECFailure"
648 "DNSResolver.GetTXTRecord"
649 "is_hdd.linux_os_root")
651 (invoke "tests/unit_tests/unit_tests"
652 (string-append "--gtest_filter=-"
653 excluded-unit-tests)))))
654 (add-after 'install 'install-librandomx
655 (lambda* (#:key outputs #:allow-other-keys)
656 (let ((lib (string-append (assoc-ref outputs "out") "/lib")))
657 (install-file "external/randomx/librandomx.a" lib)
659 (add-after 'install 'delete-dead-links
660 (lambda* (#:key outputs #:allow-other-keys)
661 (let ((out (assoc-ref outputs "out")))
662 (delete-file (string-append out "/lib/libprotobuf.so"))
663 (delete-file (string-append out "/lib/libusb-1.0.so"))
665 (home-page "https://web.getmonero.org/")
666 (synopsis "Command-line interface to the Monero currency")
668 "Monero is a secure, private, untraceable currency. This package provides
669 the Monero command line client and daemon.")
670 (license license:bsd-3)))
672 (define-public monero-gui
680 (url "https://github.com/monero-project/monero-gui")
681 (commit (string-append "v" version))))
682 (file-name (git-file-name name version))
684 (base32 "0iwjp8x5swy8i8pzrlm5v55awhm54cf48pm1vz98lcq361lhfzk6"))))
685 (build-system qt-build-system)
687 `(("monero-source" ,(package-source monero))
688 ("pkg-config" ,pkg-config)
689 ("qttools" ,qttools)))
693 ("libgcrypt" ,libgcrypt)
694 ("libsodium" ,libsodium)
695 ("libunwind" ,libunwind)
698 ("protobuf" ,protobuf)
700 ("qtdeclarative" ,qtdeclarative)
701 ("qtgraphicaleffects" ,qtgraphicaleffects)
702 ("qtlocation" ,qtlocation)
703 ("qtmultimedia" ,qtmultimedia)
704 ("qtquickcontrols" ,qtquickcontrols)
705 ("qtquickcontrols2",qtquickcontrols2)
707 ("qtxmlpatterns" ,qtxmlpatterns)
708 ("unbound" ,unbound)))
710 `(("monero" ,monero)))
712 `(#:tests? #f ; No tests
714 (modify-phases %standard-phases
715 (add-after 'unpack 'get-monero-extra-files
716 ;; Some headers and GnuPG public keys of the monero package source
717 ;; code are required to build the GUI.
718 (lambda* (#:key inputs #:allow-other-keys)
719 (invoke "tar" "-xv" "--wildcards" "--strip-components=1"
721 "-f" (assoc-ref inputs "monero-source")
724 (add-after 'get-monero-extra-files 'fix-makefile-vars
726 (substitute* "src/zxcvbn-c/makefile"
729 (add-after 'fix-makefile-vars 'fix-paths
730 (lambda* (#:key inputs outputs #:allow-other-keys)
731 (let ((boost (assoc-ref inputs "boost"))
732 (monero (assoc-ref inputs "monero"))
733 (openssl (assoc-ref inputs "openssl"))
734 (qttools (assoc-ref inputs "qttools"))
735 (out (assoc-ref outputs "out")))
736 (substitute* "monero-wallet-gui.pro"
737 (("-L/usr/local/lib")
739 (("-L/usr/local/opt/openssl/lib")
740 (string-append "-L" openssl "/lib"))
741 (("-L/usr/local/opt/boost/lib")
742 (string-append "-L" boost "/lib"))
743 (("\\$\\$\\[QT_INSTALL_BINS\\]/lrelease")
744 (string-append qttools "/bin/lrelease"))
745 (("\\$\\$\\[QT_INSTALL_BINS\\]/lupdate")
746 (string-append qttools "/bin/lupdate")))
747 (substitute* "deployment.pri"
748 (("/opt/\\$\\$\\{TARGET\\}/bin")
749 (string-append out "/bin")))
750 (substitute* "src/daemon/DaemonManager.cpp"
751 (("QApplication::applicationDirPath\\(\\) \\+ \"/monerod")
752 (string-append "\"" monero "/bin/monerod")))
754 (add-after 'fix-paths 'make-qt-deterministic
756 (setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1")
758 (add-after 'make-qt-deterministic 'fix-version
760 (substitute* "build.sh"
761 (("echo .*> version.js")
763 (with-output-to-file "version.js"
766 "var GUI_VERSION = \"~a\"~@
767 var GUI_MONERO_VERSION = \"~a\"~%"
769 ,(package-version monero))))
775 (invoke "qmake" "../monero-wallet-gui.pro" "CONFIG+=release")))
776 (add-before 'build 'build-zxcvbn-c
778 (invoke "make" "-C" "../src/zxcvbn-c"))))))
779 (home-page "https://web.getmonero.org/")
780 (synopsis "Graphical user interface for the Monero currency")
782 "Monero is a secure, private, untraceable currency. This package provides
783 the Monero GUI client.")
784 (license license:bsd-3)))
786 (define-public python-trezor-agent
788 (name "python-trezor-agent")
794 (url "https://github.com/romanz/trezor-agent")
795 (commit (string-append "v" version))))
796 (file-name (git-file-name name version))
798 (base32 "0q99vbfd3h85s8rnjipnmldixabqmmlk5w9karv6f0rhyi54f4zv"))))
799 (build-system python-build-system)
802 (modify-phases %standard-phases
803 (add-after 'unpack 'remove-requires-backports-shutil-which
804 ;; Remove requires on backport of shutil_which, as python 3.4+ has
805 ;; a built-in implementation supported in python-trezor-agent.
807 (substitute* "setup.py"
808 (("'backports.shutil_which>=3.5.1',") ""))
811 (add-after 'install 'check
812 (lambda* (#:key outputs inputs #:allow-other-keys)
813 ;; Make installed package available for running the tests.
814 (add-installed-pythonpath inputs outputs)
815 (invoke "py.test"))))))
817 `(("python-configargparse" ,python-configargparse)
818 ("python-daemon" ,python-daemon)
819 ("python-docutils" ,python-docutils)
820 ("python-ecdsa" ,python-ecdsa)
821 ("python-ed25519" ,python-ed25519)
822 ("python-mnemonic" ,python-mnemonic)
823 ("python-pymsgbox" ,python-pymsgbox)
824 ("python-semver" ,python-semver)
825 ("python-unidecode" ,python-unidecode)
826 ("python-wheel" ,python-wheel)))
829 ("python-mock" ,python-mock)
830 ("python-pytest" ,python-pytest)))
831 (home-page "https://github.com/romanz/trezor-agent")
832 (synopsis "Use hardware wallets as SSH and GPG agent")
834 "@code{libagent} is a library that allows using TREZOR, Keepkey and
835 Ledger Nano as a hardware SSH/GPG agent.")
836 (license license:lgpl3)))
838 (define-public python-mnemonic
840 (name "python-mnemonic")
845 (uri (pypi-uri "mnemonic" version))
847 (base32 "0cd9prmdj8wzdmc7lxbf9lz0xrlkvak5ignag406mmfbn81fndsf"))))
848 (build-system python-build-system)
850 `(("python-pbkdf2" ,python-pbkdf2)))
851 (home-page "https://github.com/trezor/python-mnemonic")
852 (synopsis "Implementation of Bitcoin BIP-0039")
853 (description "@code{mnemonic} is a library that provides an implementation
854 of Bitcoin BIP-0039.")
855 (license license:expat)))
857 (define-public python2-mnemonic
858 (package-with-python2 python-mnemonic))
860 (define-public python-ledgerblue
862 (name "python-ledgerblue")
867 (uri (pypi-uri "ledgerblue" version))
870 "010mghaqh1cmz3a0ifc3f40mmyplilwlw7kpha2mzyrrff46p9gb"))))
871 (build-system python-build-system)
873 `(("python-ecpy" ,python-ecpy)
874 ("python-future" ,python-future)
875 ("python-hidapi" ,python-hidapi)
876 ("python-pillow" ,python-pillow)
877 ("python-protobuf" ,python-protobuf)
878 ("python-pycrypto" ,python-pycrypto)))
879 (home-page "https://github.com/LedgerHQ/blue-loader-python")
880 (synopsis "Python library to communicate with Ledger Blue/Nano S")
881 (description "@code{ledgerblue} is a Python library to communicate with
882 Ledger Blue/Nano S.")
883 (license license:asl2.0)))
885 (define-public python2-ledgerblue
886 (package-with-python2 python-ledgerblue))
888 (define-public python-trezor
890 (name "python-trezor")
895 (uri (pypi-uri "trezor" version))
897 (base32 "1w19m9lws55k9sjhras47hpfpqwq1jm5vy135nj65yhkblygqg19"))))
898 (build-system python-build-system)
900 `(("python-click" ,python-click)
901 ("python-construct" ,python-construct)
902 ("python-ecdsa" ,python-ecdsa)
903 ("python-libusb1" ,python-libusb1)
904 ("python-mnemonic" ,python-mnemonic)
905 ("python-requests" ,python-requests)
906 ("python-typing-extensions" ,python-typing-extensions)))
909 `(("protobuf" ,protobuf)
910 ("python-black" ,python-black)
911 ("python-protobuf" ,python-protobuf)
912 ("python-isort" ,python-isort)
913 ("python-pyqt" ,python-pyqt)
914 ("python-pytest" ,python-pytest)))
915 (home-page "https://github.com/trezor/python-trezor")
916 (synopsis "Python library for communicating with TREZOR Hardware Wallet")
917 (description "@code{trezor} is a Python library for communicating with
918 TREZOR Hardware Wallet.")
919 (license license:lgpl3)))
921 (define-public python-keepkey
923 (name "python-keepkey")
928 (uri (pypi-uri "keepkey" version))
931 "0z3d0m6364v9dv0njs4cd5m5ai6j6v35xaaxfxl90m9vmyxy81vd"))))
932 (build-system python-build-system)
935 (modify-phases %standard-phases
937 (add-after 'install 'check
938 (lambda* (#:key inputs outputs #:allow-other-keys)
939 (add-installed-pythonpath inputs outputs)
940 (apply invoke "python" (find-files "tests/unit" "\\.py$")))))))
942 `(("python-ecdsa" ,python-ecdsa)
943 ("python-hidapi" ,python-hidapi)
944 ("python-libusb1" ,python-libusb1)
945 ("python-mnemonic" ,python-mnemonic)
946 ("python-protobuf" ,python-protobuf)))
947 (home-page "https://github.com/keepkey/python-keepkey")
948 (synopsis "Python library for communicating with KeepKey Hardware Wallet")
949 (description "@code{keepkey} is a Python library for communicating with
950 the KeepKey Hardware Wallet.")
951 (license license:lgpl3)))
953 (define-public python2-keepkey
954 (package-with-python2 python-keepkey))
956 (define-public ledger-agent
958 (name "ledger-agent")
963 (uri (pypi-uri "ledger_agent" version))
966 "03zj602m2rln9yvr08dswy56vzkbldp8b074ixwzz525dafblr92"))))
967 (build-system python-build-system)
969 `(("python-ledgerblue" ,python-ledgerblue)
970 ("python-trezor-agent" ,python-trezor-agent)))
971 (home-page "https://github.com/romanz/trezor-agent")
972 (synopsis "Ledger as hardware SSH/GPG agent")
973 (description "This package allows using Ledger as hardware SSH/GPG agent.
975 Usage for SSH: trezor-agent foo@@example.com --connect
976 Usage for GPG: Initialize using trezor-gpg init \"Foo <foo@@example.com>\"
977 Then set the environment variable GNUPGHOME to
978 \"${HOME}/.gnupg/trezor\".")
979 (license license:lgpl3)))
981 (define-public trezor-agent
983 (name "trezor-agent")
988 (uri (pypi-uri "trezor_agent" version))
991 "144657c7bn0a667dq5fv5r6j7iilxf3h9agj29v1m2qpq40g0az8"))))
993 ;; Tests fail with "AttributeError: module 'attr' has no attribute 's'".
995 (modify-phases %standard-phases
996 (add-after 'wrap 'fixup-agent-py
997 (lambda* (#:key inputs outputs #:allow-other-keys)
998 (let* ((out (assoc-ref outputs "out")))
999 ;; overwrite the wrapper with the real thing.
1000 (install-file "./trezor_agent.py"
1001 (string-append out "/bin"))
1003 (build-system python-build-system)
1005 `(("python-trezor" ,python-trezor)
1006 ("python-trezor-agent" ,python-trezor-agent)))
1008 `(("python-hidapi" ,python-hidapi)))
1009 (home-page "https://github.com/romanz/trezor-agent")
1010 (synopsis "Using Trezor as hardware SSH/GPG agent")
1011 (description "This package allows using Trezor as a hardware SSH/GPG
1013 (license license:lgpl3)))
1015 (define-public keepkey-agent
1017 (name "keepkey-agent")
1022 (uri (pypi-uri "keepkey_agent" version))
1025 "03779gvlx70i0nnry98i4pl1d92604ix5x6jgdfkrdgzqbh5vj27"))))
1026 (build-system python-build-system)
1028 `(("python-keepkey" ,python-keepkey)
1029 ("python-trezor-agent" ,python-trezor-agent)))
1030 (home-page "https://github.com/romanz/trezor-agent")
1031 (synopsis "KeepKey as hardware SSH/GPG agent")
1032 (description "This package allows using KeepKey as a hardware SSH/GPG
1034 (license license:lgpl3)))
1036 (define-public python-stdnum
1038 (name "python-stdnum")
1043 (uri (pypi-uri "python-stdnum" version))
1045 (base32 "070vd9zgvq0jchs4xc4j1h4r1l1lg4wwb8xs3p25k8c2xjw94fpx"))))
1046 (build-system python-build-system)
1048 '(#:phases (modify-phases %standard-phases
1051 (invoke "nosetests"))))))
1053 `(("python-nose" ,python-nose)))
1054 (home-page "https://arthurdejong.org/python-stdnum/")
1055 (synopsis "Python module to handle standardized number and code formats")
1057 "This is a Python library that aims to provide functions to handle,
1058 parse and validate standard numbers.
1059 The module supports more than 100 different number formats
1060 amongst which a great number of VAT and other tax numbers,
1061 personal identity and company identification codes,
1062 international standard numbers (ISBN, IBAN, EAN, etc.)
1063 and various other formats.
1064 The module also inclused implementations of the Verhoeff,
1065 Luhn and family of ISO/IEC 7064 check digit algorithms. ")
1066 (license license:lgpl2.1+)))
1068 (define-public python2-stdnum
1069 (package-with-python2 python-stdnum))
1071 (define-public python-duniterpy
1073 (name "python-duniterpy")
1078 (uri (pypi-uri "duniterpy" version))
1080 (base32 "0rw2c7r9gcqhymp82gbk1ky45zqbypsi2q5x4vdwjc6g00kh7h6l"))))
1081 (build-system python-build-system)
1083 ;; FIXME: Tests fail with: "ModuleNotFoundError: No module named
1084 ;; 'tests'". Not sure how to handle this.
1087 (modify-phases %standard-phases
1088 ;; "setup.py" tries to open missing "requirements.txt".
1089 (add-after 'unpack 'ignore-missing-file
1091 (substitute* "setup.py"
1092 (("open\\('requirements\\.txt'\\)") "[]"))
1095 `(("aiohttp" ,python-aiohttp)
1096 ("attrs" ,python-attrs)
1097 ("base58" ,python-base58)
1098 ("jsonschema" ,python-jsonschema)
1099 ("libnacl" ,python-libnacl)
1100 ("pyaes" ,python-pyaes)
1101 ("pylibscrypt" ,python-pylibscrypt)
1102 ("pypeg2" ,python-pypeg2)))
1103 (home-page "https://git.duniter.org/clients/python/duniterpy")
1104 (synopsis "Python implementation of Duniter API")
1105 (description "@code{duniterpy} is an implementation of
1106 @uref{https://github.com/duniter/duniter/, duniter} API. Its
1109 @item Support Duniter's Basic Merkle API and protocol
1110 @item Asynchronous/synchronous without threads
1111 @item Support HTTP, HTTPS and Web Socket transport for Basic Merkle API
1112 @item Support Elasticsearch Duniter4j API
1113 @item Duniter signing key
1114 @item Sign/verify and encrypt/decrypt messages with the Duniter credentials
1116 (license license:gpl3+)))
1118 (define-public silkaj
1125 (uri (pypi-uri "silkaj" version))
1127 (base32 "0hrn0jwg415z7wjkp0myvw85wszlfi18f56j03075xxakr4dmi2j"))))
1128 (build-system python-build-system)
1130 `(#:tests? #f)) ;no test
1132 `(("click" ,python-click)
1133 ("duniterpy" ,python-duniterpy)
1134 ("pynacl" ,python-pynacl)
1135 ("tabulate" ,python-tabulate)
1136 ("texttable" ,python-texttable)))
1137 (home-page "https://git.duniter.org/clients/python/silkaj")
1138 (synopsis "Command line client for Duniter network")
1139 (description "@code{Silkaj} is a command line client for the
1140 @uref{https://github.com/duniter/duniter/, Duniter} network.
1144 @item information about currency,
1145 @item issuers difficulty to generate next block,
1146 @item network view of nodes,
1147 @item list of last issuers,
1148 @item send transactions,
1149 @item get account amount.
1151 (license license:agpl3+)))
1153 (define-public grisbi
1161 "mirror://sourceforge/grisbi/grisbi%20stable/"
1162 (version-major+minor version) ".x/" version
1163 "/grisbi-" version ".tar.bz2"))
1166 "1piiyyxjsjbw9gcqydvknzxmmfgh8kdqal12ywrxyxih2afwnvbw"))))
1167 (build-system glib-or-gtk-build-system)
1169 `(#:configure-flags (list "--without-ofx")))
1171 `(("dconf" ,dconf)))
1173 `(("glib" ,glib "bin") ; glib-compile-schemas
1174 ("pkg-config" ,pkg-config)
1175 ("intltool" ,intltool)))
1178 ("libgsf" ,libgsf)))
1179 (synopsis "Personal accounting application")
1180 (description "Grisbi is a personal accounting application written by
1181 French developers that is designed to follow French accounting rules.
1182 Grisbi can manage multiple accounts, currencies and users. It manages
1183 third party, expenditure and receipt categories, budgetary lines,
1184 financial years, budget estimates, bankcard management and other
1186 (home-page "https://grisbi.org")
1187 (license license:gpl2+)))
1189 (define-public trezord-udev-rules
1190 (let ((commit "bff7fdfe436c727982cc553bdfb29a9021b423b0")
1193 (name "trezord-udev-rules")
1194 (version (git-version "0.0.0" revision commit))
1199 (url "https://github.com/trezor/trezor-common")
1203 "14mrirrn68if7ja6qdk9qlxs1hv0f21vrxy5ncnms0gx9iwakp2l"))
1204 (file-name (git-file-name name version))))
1205 (build-system copy-build-system)
1208 '(("./udev/51-trezor.rules" "lib/udev/rules.d/"))))
1209 (home-page "https://github.com/trezor/trezor-common")
1210 (synopsis "Udev rules for trezord")
1212 "This contains the udev rules for trezord. This will let a user run
1213 trezord as a regular user instead of needing to it run as root.")
1214 (license license:lgpl3+))))
1216 (define-public trezord
1224 (url "https://github.com/trezor/trezord-go")
1225 (commit (string-append "v" version))))
1228 "1ks1fa0027s3xp0z6qp0dxmayvrb4dwwscfhbx7da0khp153f2cp"))
1229 (file-name (git-file-name name version))))
1230 (build-system go-build-system)
1232 '(#:import-path "github.com/trezor/trezord-go"))
1233 (home-page "https://trezor.io")
1234 (synopsis "Trezor Communication Daemon aka Trezor Bridge (written in Go)")
1235 (description "This allows a Trezor hardware wallet to communicate to the
1237 (license license:lgpl3+)))
1239 (define-public bitcoin-abc
1241 (name "bitcoin-abc")
1245 (uri (string-append "https://download.bitcoinabc.org/"
1246 version "/src/bitcoin-abc-"
1250 "1amzwy3gpl8ai90dsy7g0z51qq8vxfzbf642wn4bfynb8jmw3kx5"))))
1251 (build-system cmake-build-system)
1253 `(("pkg-config" ,pkg-config)
1254 ("python" ,python) ; for the tests
1255 ("util-linux" ,util-linux) ; provides the hexdump command for tests
1256 ("qttools" ,qttools)))
1260 ("jemalloc" ,jemalloc)
1261 ("libevent" ,libevent)
1262 ("miniupnpc" ,miniupnpc)
1263 ("openssl" ,openssl)
1264 ("protobuf" ,protobuf)
1265 ("qrencode" ,qrencode)
1271 (modify-phases %standard-phases
1272 (add-before 'configure 'make-qt-deterministic
1274 ;; Make Qt deterministic.
1275 (setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1")
1277 (add-before 'check 'set-home
1279 (setenv "HOME" (getenv "TMPDIR")) ; tests write to $HOME
1281 (add-after 'check 'check-functional
1284 "python3" "./test/functional/test_runner.py"
1285 (string-append "--jobs=" (number->string (parallel-job-count)))
1286 ;; TODO: find why the abc-miner-fund test fails.
1287 "--exclude=abc-miner-fund")
1289 (home-page "https://www.bitcoinabc.org/")
1290 (synopsis "Bitcoin ABC peer-to-peer full node for the Bitcoin Cash protocol")
1292 "Bitcoin Cash brings sound money to the world, fulfilling the original
1293 promise of Bitcoin as Peer-to-Peer Electronic Cash. Merchants and users are
1294 empowered with low fees and reliable confirmations is a digital currency that
1295 enables instant payments to anyone anywhere in the world. It uses
1296 peer-to-peer technology to operate without central authority: managing
1297 transactions and issuing money are carried out collectively by the network.
1298 As a fork it implemented changes lowering the time between blocks and now
1299 offers confimations after less than 5 seconds and have significantly lower
1300 fees that BTC. Bitcoin ABC is the reference implementation of the Bitcoin
1301 Cash protocol. This package provides the Bitcoin Cash command line client and
1302 a client based on Qt. This is a fork of Bitcoin Core.")
1303 (license license:expat)))
1305 (define-public libofx
1312 (url "https://github.com/libofx/libofx")
1314 (file-name (git-file-name name version))
1317 "1jx56ma351p8af8dvavygjwf6ipa7qbgq7bpdsymwj27apdnixfy"))))
1318 (build-system gnu-build-system)
1320 '(#:parallel-build? #f ;fails with -j64
1322 (list (string-append "--with-opensp-includes="
1323 (assoc-ref %build-inputs "opensp")
1324 "/include/OpenSP"))))
1326 `(("autoconf" ,autoconf)
1327 ("automake" ,automake)
1328 ("gengetopt" ,gengetopt)
1329 ("help2man" ,help2man)
1330 ("libtool" ,libtool)
1331 ("pkg-config" ,pkg-config)))
1334 ("libxml++-2" ,libxml++-2)
1335 ("opensp" ,opensp)))
1336 (home-page "http://libofx.sourceforge.net/")
1337 (synopsis "Library supporting the Open Financial Exchange format")
1339 "The LibOFX library is an API designed to allow applications to very easily
1340 support OFX command responses, usually provided by financial institutions. The
1341 following three utilities are included with the library:
1343 @item @code{ofxdump}
1344 @item @code{ofx2qif}
1345 @item @code{ofxconnect}
1347 (license license:gpl2+)))
1349 (define-public opensp
1355 (uri (string-append "mirror://sourceforge/openjade/opensp/"
1356 version "/OpenSP-" version ".tar.gz"))
1359 "1khpasr6l0a8nfz6kcf3s81vgdab8fm2dj291n5r2s53k228kx2p"))))
1360 (build-system gnu-build-system)
1362 `(("gettext" ,gettext-minimal)))
1364 `(("docbook-xml" ,docbook-xml-4.1.2)
1365 ("docbook-xsl" ,docbook-xsl)
1368 `(;; TODO: Fix and enable tests.
1371 (modify-phases %standard-phases
1372 (add-after 'unpack 'patch-docbook-paths
1373 (lambda* (#:key inputs #:allow-other-keys)
1374 (let ((xmldoc (string-append (assoc-ref inputs "docbook-xml")
1375 "/xml/dtd/docbook"))
1376 (xsldoc (string-append (assoc-ref inputs "docbook-xsl")
1377 "/xml/xsl/docbook-xsl-"
1378 ,(package-version docbook-xsl))))
1379 (substitute* (find-files "docsrc" "\\.xml$")
1380 (("/usr/share/sgml/docbook/xml-dtd-4.1.2") xmldoc)
1381 (("http://.*/docbookx\\.dtd")
1382 (string-append xmldoc "/docbookx.dtd")))
1383 ;; Directly pass the path to the stylesheet to xmlto.
1384 (substitute* "docsrc/Makefile.in"
1386 (string-append "$(XMLTO) -x " xsldoc
1387 "/manpages/docbook.xsl")))
1389 (home-page "http://openjade.sourceforge.net/")
1390 (synopsis "Suite of SGML/XML processing tools")
1391 (description "OpenSP is an object-oriented toolkit for SGML parsing and
1392 entity management.")
1394 ;; expat license with added clause regarding advertising
1395 (license:non-copyleft
1397 "See COPYING in the distribution."))))
1399 (define-public bitcoin-unlimited
1401 (name "bitcoin-unlimited")
1407 (url "https://github.com/BitcoinUnlimited/BitcoinUnlimited")
1408 (commit (string-append "BCHunlimited" version))))
1409 (file-name (git-file-name name version))
1411 (base32 "1a64h7mcqdra4ahnw1nycp4ysx308ymgbl4yn5fj5jfaszdzvy0h"))))
1412 (build-system gnu-build-system)
1414 `(("autoconf" ,autoconf)
1415 ("automake" ,automake)
1416 ("libtool" ,libtool)
1417 ("pkg-config" ,pkg-config)
1418 ("python" ,python) ; for the tests
1419 ("util-linux" ,util-linux) ; provides the hexdump command for tests
1420 ("qttools" ,qttools)))
1424 ("libevent" ,libevent)
1425 ("miniupnpc" ,miniupnpc)
1426 ("openssl" ,openssl)
1427 ("protobuf" ,protobuf)
1428 ("qrencode" ,qrencode)
1435 ;; Boost is not found unless specified manually.
1436 (string-append "--with-boost="
1437 (assoc-ref %build-inputs "boost"))
1438 ;; XXX: The configure script looks up Qt paths by
1439 ;; `pkg-config --variable=host_bins Qt5Core`, which fails to pick
1440 ;; up executables residing in 'qttools', so we specify them here.
1441 (string-append "ac_cv_path_LRELEASE="
1442 (assoc-ref %build-inputs "qttools")
1444 (string-append "ac_cv_path_LUPDATE="
1445 (assoc-ref %build-inputs "qttools")
1448 (modify-phases %standard-phases
1449 (add-after 'unpack 'fix-build
1451 ;; The 'stack' header was not included in unlimited.cpp, which
1452 ;; caused the build to fail.
1453 (substitute* "src/unlimited.cpp"
1454 (("#include <queue>" all)
1455 (string-append all "\n#include <stack>")))
1457 (add-after 'unpack 'fix-tests
1459 ;; TODO: Find why txvalidationcache_tests fails and
1460 ;; utilprocess_tests never ends. Disable for now.
1461 (substitute* "src/Makefile.test.include"
1462 (("test/txvalidationcache_tests.cpp")
1464 (("test/utilprocess_tests.cpp")
1467 (add-before 'configure 'make-qt-deterministic
1469 ;; Make Qt deterministic.
1470 (setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1")
1472 (add-before 'check 'set-home
1474 (setenv "HOME" (getenv "TMPDIR")) ; tests write to $HOME
1476 (home-page "https://www.bitcoinunlimited.info/")
1477 (synopsis "Client for the Bitcoin Cash protocol")
1479 "Bitcoin Unlimited is a client for the Bitcoin Cash peer-to-peer
1480 electronic cash system. This package provides a command line client and
1482 (license license:expat)))
1484 (define-public fulcrum
1491 (uri (string-append "https://gitlab.com/FloweeTheHub/fulcrum/-/archive/v"
1492 version "/fulcrum-v" version ".tar.gz"))
1494 (base32 "04w5gw02d39caa8a0l6wkn87kc43zzad2prqsyrcq97vlbkdx6x6"))))
1495 (build-system gnu-build-system)
1498 (modify-phases %standard-phases
1499 ;; Call qmake instead of configure to create a Makefile.
1504 (string-append "PREFIX=" %output)
1507 `(("qttools" ,qttools)))
1509 `(("python" ,python)
1511 ("rocksdb" ,rocksdb)
1513 (home-page "https://gitlab.com/FloweeTheHub/fulcrum/")
1514 (synopsis "Fast and nimble SPV server for Bitcoin Cash")
1516 "Flowee Fulcrum is a server that is the back-end for @acronym{SPV,
1517 Simplified Payment Verification} wallets, it provides the full API for those
1518 walets in a fast and small server. The full data is stored in a full node,
1519 like Flowee the Hub, which Fulcrum connects to over RPC.")
1520 (license license:gpl3+)))
1522 (define-public flowee
1525 (version "2020.04.1")
1529 (uri (string-append "https://gitlab.com/FloweeTheHub/thehub/-/archive/"
1530 version "/thehub-" version ".tar.gz"))
1532 (base32 "1vwvaxm3b71pfx8l4rrv06wqks6xdf2333w856b36s1bzvj53rhc"))))
1533 (build-system cmake-build-system)
1535 `(#:configure-flags '("-Dbuild_tests=ON" "-Denable_gui=OFF")
1537 (modify-phases %standard-phases
1538 (add-before 'configure 'make-qt-deterministic
1540 ;; Make Qt deterministic.
1541 (setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1")
1543 (add-before 'configure 'disable-black-box
1544 ;; the black-box testing runs full hubs and lets them interact.
1545 ;; this is more fragile and a slow machine, or low memory machine, may
1546 ;; make the tests timeout and fail. We just disable them here.
1548 (substitute* "testing/CMakeLists.txt"
1550 (substitute* "testing/CMakeLists.txt"
1551 (("add_subdirectory\\(api\\)") ""))
1553 (add-after 'configure 'set-build-info
1554 ;; Their genbuild.sh to generate a build.h fails in guix (no .git dir) .
1555 ;; Its purpose is to write the tag name in the build.h file. We do that
1558 (with-output-to-file "include/build.h"
1561 (string-append "#define BUILD_DESC " "\"", version "\""))))))
1562 (add-before 'check 'set-home
1564 (setenv "HOME" (getenv "TMPDIR")) ; tests write to $HOME
1568 (invoke "make" "check" "-C" "testing"))))))
1572 ("libevent" ,libevent)
1573 ("miniupnpc" ,miniupnpc)
1574 ("openssl" ,openssl)
1575 ("qtbase" ,qtbase)))
1577 `(("pkg-config" ,pkg-config)
1578 ("qttools" ,qttools)
1579 ("util-linux" ,util-linux))) ; provides the hexdump command for tests
1580 (home-page "https://flowee.org")
1581 (synopsis "Flowee infrastructure tools and services")
1583 "Flowee packages all tier-1 applications and services from the Flowee group.
1584 This includes components like The Hub and Indexer which and various others
1585 that allows you to run services and through them access the Bitcoin Cash networks.")
1586 (license license:gpl3+)))
1589 (define-public beancount
1596 (uri (pypi-uri "beancount" version))
1599 "0pcfl2rx2ng06i4f9izdpnlnb1k0rdzsckbzzn4cn4ixfzyssm0m"))
1600 (patches (search-patches "beancount-disable-googleapis-fonts.patch"))))
1601 (build-system python-build-system)
1603 `(#:tests? #f ; Says test is missing, not sure why
1605 (modify-phases %standard-phases
1606 ;; Not importing the googleapis package for now
1607 (add-after 'unpack 'ignore-googleapis
1609 (substitute* "setup.py"
1610 (("'google-api-python-client',") ""))
1613 `(("python-beautifulsoup4" ,python-beautifulsoup4)
1614 ("python-bottle" ,python-bottle)
1615 ("python-chardet" ,python-chardet)
1616 ("python-dateutil" ,python-dateutil)
1617 ("python-lxml" ,python-lxml)
1618 ("python-magic" ,python-magic)
1619 ("python-ply" ,python-ply)
1620 ("python-requests" ,python-requests)))
1622 `(("python-pytest" ,python-pytest)))
1623 (home-page "http://furius.ca/beancount")
1624 (synopsis "Command-line double-entry accounting tool")
1626 "Beancount is a double-entry bookkeeping computer language that lets you
1627 define financial transaction records in a text file, read them in memory,
1628 generate a variety of reports from them, and provides a web interface.")
1629 (license license:gpl2)))
1631 ;; The beancount source ships with elisp in a subdirectory
1632 (define-public emacs-beancount
1635 (name "emacs-beancount")
1636 (build-system emacs-build-system)
1638 `(#:tests? #f ;no tests
1640 (modify-phases %standard-phases
1641 (add-before 'install 'chdir-emacs
1643 (chdir "editors/emacs")
1647 (synopsis "Emacs mode for beancount")
1649 "Emacs-beancount is an Emacs mode for the Beancount accounting tool.")))