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 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 Martin Becze <mjbecze@riseup.net>
17 ;;; Copyright © 2019 Sebastian Schott <sschott@mailbox.org>
18 ;;; Copyright © 2020 Kei Kebreau <kkebreau@posteo.net>
20 ;;; This file is part of GNU Guix.
22 ;;; GNU Guix is free software; you can redistribute it and/or modify it
23 ;;; under the terms of the GNU General Public License as published by
24 ;;; the Free Software Foundation; either version 3 of the License, or (at
25 ;;; your option) any later version.
27 ;;; GNU Guix is distributed in the hope that it will be useful, but
28 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
29 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 ;;; GNU General Public License for more details.
32 ;;; You should have received a copy of the GNU General Public License
33 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
35 (define-module (gnu packages finance)
36 #:use-module ((guix licenses) #:prefix license:)
37 #:use-module (guix packages)
38 #:use-module (guix download)
39 #:use-module (guix git-download)
40 #:use-module (guix build-system gnu)
41 #:use-module (guix build-system cmake)
42 #:use-module (guix build-system python)
43 #:use-module (guix build-system glib-or-gtk)
44 #:use-module (guix build-system go)
45 #:use-module (guix build-system qt)
46 #:use-module (guix utils)
47 #:use-module (gnu packages)
48 #:use-module (gnu packages aidc)
49 #:use-module (gnu packages autotools)
50 #:use-module (gnu packages base)
51 #:use-module (gnu packages boost)
52 #:use-module (gnu packages check)
53 #:use-module (gnu packages compression)
54 #:use-module (gnu packages crypto)
55 #:use-module (gnu packages curl)
56 #:use-module (gnu packages databases)
57 #:use-module (gnu packages docbook)
58 #:use-module (gnu packages documentation)
59 #:use-module (gnu packages dns)
60 #:use-module (gnu packages emacs)
61 #:use-module (gnu packages dbm)
62 #:use-module (gnu packages gettext)
63 #:use-module (gnu packages gnome)
64 #:use-module (gnu packages glib)
65 #:use-module (gnu packages gnupg)
66 #:use-module (gnu packages graphviz)
67 #:use-module (gnu packages groff)
68 #:use-module (gnu packages gtk)
69 #:use-module (gnu packages libedit)
70 #:use-module (gnu packages libevent)
71 #:use-module (gnu packages libunwind)
72 #:use-module (gnu packages libusb)
73 #:use-module (gnu packages linux)
74 #:use-module (gnu packages man)
75 #:use-module (gnu packages multiprecision)
76 #:use-module (gnu packages networking)
77 #:use-module (gnu packages pkg-config)
78 #:use-module (gnu packages popt)
79 #:use-module (gnu packages protobuf)
80 #:use-module (gnu packages python)
81 #:use-module (gnu packages python-crypto)
82 #:use-module (gnu packages python-web)
83 #:use-module (gnu packages python-xyz)
84 #:use-module (gnu packages qt)
85 #:use-module (gnu packages readline)
86 #:use-module (gnu packages sphinx)
87 #:use-module (gnu packages texinfo)
88 #:use-module (gnu packages textutils)
89 #:use-module (gnu packages time)
90 #:use-module (gnu packages tls)
91 #:use-module (gnu packages upnp)
92 #:use-module (gnu packages version-control)
93 #:use-module (gnu packages web)
94 #:use-module (gnu packages xml)
95 #:use-module (gnu packages gnuzilla))
97 (define-public bitcoin-core
104 (string-append "https://bitcoincore.org/bin/bitcoin-core-"
105 version "/bitcoin-" version ".tar.gz"))
108 "1172dl4b8h2a80ilk9sfgbl8yi55k6hs4b1m07nic2ls4irgkjbs"))))
109 (build-system gnu-build-system)
111 `(("pkg-config" ,pkg-config)
112 ("python" ,python) ; for the tests
113 ("util-linux" ,util-linux) ; provides the hexdump command for tests
114 ("qttools" ,qttools)))
116 `(("bdb" ,bdb-4.8) ; 4.8 required for compatibility
118 ("libevent" ,libevent)
119 ("miniupnpc" ,miniupnpc)
121 ("protobuf" ,protobuf)
126 ;; Boost is not found unless specified manually.
127 (string-append "--with-boost="
128 (assoc-ref %build-inputs "boost"))
129 ;; XXX: The configure script looks up Qt paths by
130 ;; `pkg-config --variable=host_bins Qt5Core`, which fails to pick
131 ;; up executables residing in 'qttools', so we specify them here.
132 (string-append "ac_cv_path_LRELEASE="
133 (assoc-ref %build-inputs "qttools")
135 (string-append "ac_cv_path_LUPDATE="
136 (assoc-ref %build-inputs "qttools")
139 (modify-phases %standard-phases
140 (add-before 'configure 'make-qt-deterministic
142 ;; Make Qt deterministic.
143 (setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1")
145 (add-before 'check 'set-home
147 (setenv "HOME" (getenv "TMPDIR")) ; tests write to $HOME
149 (add-after 'check 'check-functional
151 (invoke "python3" "./test/functional/test_runner.py"
152 (string-append "--jobs=" (number->string (parallel-job-count))))
154 (home-page "https://bitcoin.org/en/")
155 (synopsis "Bitcoin peer-to-peer client")
157 "Bitcoin is a digital currency that enables instant payments to anyone
158 anywhere in the world. It uses peer-to-peer technology to operate without
159 central authority: managing transactions and issuing money are carried out
160 collectively by the network. Bitcoin Core is the reference implementation
161 of the bitcoin protocol. This package provides the Bitcoin Core command
162 line client and a client based on Qt.")
163 (license license:expat)))
165 (define-public homebank
171 (uri (string-append "http://homebank.free.fr/public/homebank-"
175 "13ampiv68y30kc0p2560g3yz8whqpwnidfcnb9lndv93b9ca767y"))))
176 (build-system glib-or-gtk-build-system)
178 `(("pkg-config" ,pkg-config)
179 ("intltool" ,intltool)))
182 ("libsoup" ,libsoup)))
184 `(#:configure-flags (list "-without-ofx"))) ; libofx is not available yet
185 (home-page "http://homebank.free.fr/")
186 (synopsis "Graphical personal accounting application")
187 (description "HomeBank allows you to manage your personal accounts at
188 home. The seeks to be lightweight, simple and easy to use. It brings
189 features that allow you to analyze your finances in a detailed way instantly
190 and dynamically with report tools based on filtering and graphical charts.")
191 (license license:gpl2+)))
193 (define-public ledger
201 (url "https://github.com/ledger/ledger.git")
202 (commit (string-append "v" version))))
203 (file-name (git-file-name name version))
205 (base32 "0bfnrqrd6wqgsngfpqi30xh6yy86pwl25iwzrqy44q31r0zl4mm3"))))
206 (build-system cmake-build-system)
209 `("-DBUILD_DOCS:BOOL=ON"
210 "-DBUILD_WEB_DOCS:BOOL=ON"
211 "-DUSE_PYTHON:BOOL=ON"
212 "-DCMAKE_INSTALL_LIBDIR:PATH=lib")
214 (modify-phases %standard-phases
215 (add-before 'configure 'install-examples
216 (lambda* (#:key outputs #:allow-other-keys)
217 (let ((examples (string-append (assoc-ref outputs "out")
218 "/share/doc/ledger/examples")))
219 (install-file "test/input/sample.dat" examples)
220 (install-file "test/input/demo.ledger" examples))
222 (add-after 'build 'build-doc
223 (lambda _ (invoke "make" "doc")))
224 (add-before 'check 'check-setup
225 ;; One test fails if it can't set the timezone.
226 (lambda* (#:key inputs #:allow-other-keys)
228 (string-append (assoc-ref inputs "tzdata")
230 ;; Skip failing test BaselineTest_cmd-org.
231 ;; This is a known upstream issue. See
232 ;; https://github.com/ledger/ledger/issues/550
233 (setenv "ARGS" "-E BaselineTest_cmd-org")
245 ("texinfo" ,texinfo)))
246 (home-page "https://ledger-cli.org/")
247 (synopsis "Command-line double-entry accounting program")
249 "Ledger is a powerful, double-entry accounting system that is
250 accessed from the UNIX command-line. This may put off some users, since
251 there is no flashy UI, but for those who want unparalleled reporting
252 access to their data there are few alternatives.
254 Ledger uses text files for input. It reads the files and generates
255 reports; there is no other database or stored state. To use Ledger,
256 you create a file of your account names and transactions, run from the
257 command line with some options to specify input and requested reports, and
258 get output. The output is generally plain text, though you could generate
259 a graph or html instead. Ledger is simple in concept, surprisingly rich
260 in ability, and easy to use.")
261 ;; There are some extra licenses in files which do not presently get
262 ;; installed when you build this package. Different versions of the GPL
263 ;; are used in the contrib and python subdirectories. The bundled version
264 ;; of utfcpp is under the Boost 1.0 license. Also the file
265 ;; `tools/update_copyright_year` has an Expat license.
266 (license (list license:bsd-3
267 license:asl2.0 ; src/strptime.cc
268 (license:non-copyleft
269 "file://src/wcwidth.cc"
270 "See src/wcwidth.cc in the distribution.")))))
272 (define-public emacs-ledger-mode
273 ;; There have been no new releases since 2016.
274 (let ((commit "253a20dc62e137ed0ed8e1dd8614ecba116610ea")
277 (name "emacs-ledger-mode")
278 (version (git-version "3.1.1" revision commit))
283 (url "https://github.com/ledger/ledger-mode.git")
285 (file-name (git-file-name name version))
287 (base32 "06wrgkqpgvk17vibrk2qikdlqn8y63jg86marp1wgmram92mb3jk"))))
288 (build-system cmake-build-system)
290 `(#:modules ((guix build cmake-build-system)
292 (guix build emacs-utils))
293 #:imported-modules (,@%cmake-build-system-modules
294 (guix build emacs-utils))
295 #:tests? #f ; there are none
297 (modify-phases %standard-phases
298 (add-after 'unpack 'patch-site-dir
300 (substitute* "CMakeLists.txt"
301 (("DESTINATION share/emacs/site-lisp/ledger-mode")
302 "DESTINATION share/emacs/site-lisp"))
304 (add-before 'build 'patch-path
305 (lambda* (#:key inputs #:allow-other-keys)
306 (let ((ledger (assoc-ref inputs "ledger")))
307 (make-file-writable "ledger-exec.el")
308 (emacs-substitute-variables "ledger-exec.el"
309 ("ledger-binary-path" (string-append ledger "/bin/ledger"))))
311 (add-after 'build 'build-doc
312 (lambda* (#:key outputs #:allow-other-keys)
313 (let ((target (string-append (assoc-ref outputs "out")
316 (invoke "makeinfo" "-o" target
317 "../source/doc/ledger-mode.texi"))
319 (add-after 'install 'generate-autoload
320 (lambda* (#:key outputs #:allow-other-keys)
321 (let* ((site-dir (string-append (assoc-ref outputs "out")
322 "/share/emacs/site-lisp")))
323 (emacs-generate-autoloads ,name site-dir))
326 `(("ledger" ,ledger)))
328 `(("emacs-minimal" ,emacs-minimal)
329 ("texinfo" ,texinfo)))
330 (home-page "https://ledger-cli.org/")
331 (synopsis "Command-line double-entry accounting program")
333 "Ledger is a powerful, double-entry accounting system that is
334 accessed from the UNIX command-line. This may put off some users, since
335 there is no flashy UI, but for those who want unparalleled reporting
336 access to their data there are few alternatives.
338 Ledger uses text files for input. It reads the files and generates
339 reports; there is no other database or stored state. To use Ledger,
340 you create a file of your account names and transactions, run from the
341 command line with some options to specify input and requested reports, and
342 get output. The output is generally plain text, though you could generate
343 a graph or html instead. Ledger is simple in concept, surprisingly rich
344 in ability, and easy to use.
346 This package provides the Emacs mode.")
347 (license license:gpl2+))))
349 (define-public geierlein
357 (url "https://github.com/stesie/geierlein.git")
358 (commit (string-append "V" version))))
359 (file-name (git-file-name name version))
361 (base32 "00zpwr3lk2vdmd60fgdwdk0xxs52wvnm19ln2m75yfphydvkglic"))))
362 (build-system gnu-build-system)
364 `(#:tests? #f ; would require npm, python and a lot more
366 (modify-phases %standard-phases
367 (delete 'configure) ; no configure script
368 (add-after 'unpack 'override-target-directory-and-tool-paths
369 (lambda* (#:key inputs outputs #:allow-other-keys)
370 (substitute* "Makefile"
372 (string-append "prefix := " (assoc-ref outputs "out") "\n"))
373 ;; Required for tests, unused for now:
375 ;; (string-append (which "python") "\n")))
377 (string-append "INSTALL := " (which "install") "\n")))
378 (substitute* "bin/xgeierlein.in"
379 ;; Use icecat as XULRUNNER
381 (string-append "XULRUNNER=" (which "icecat") "\n"
385 `(("icecat" ,icecat)))
386 (home-page "https://stesie.github.io/geierlein/")
387 (synopsis "Free Elster client, for sending Germany VAT declarations")
389 "Geierlein is a free Elster client, i.e. an application that
390 allows to send VAT declarations to Germany's fiscal authorities.
392 Currently it is *not* possible to send returns that are due annually
393 (especially the income tax return) since the fiscal authority doesn't
394 allow to do that off the ERiC library (which is proprietary however).
395 It's not clear at the moment whether one day it will be possible to
397 (license license:agpl3+)))
399 (define-public electrum
406 (uri (string-append "https://download.electrum.org/"
410 (base32 "1g00cj1pmckd4xis8r032wmraiv3vd3zc803hnyxa2bnhj8z3bg2"))
411 (modules '((guix build utils)))
414 ;; Delete the bundled dependencies.
415 (delete-file-recursively "packages")
417 (build-system python-build-system)
419 `(("python-pyaes" ,python-pyaes)
420 ("python-pysocks" ,python-pysocks)
421 ("python-sip" ,python-sip)
422 ("python-pyqt" ,python-pyqt)
423 ("python-ecdsa" ,python-ecdsa)
424 ("python-pbkdf2" ,python-pbkdf2)
425 ("python-requests" ,python-requests)
426 ("python-qrcode" ,python-qrcode)
427 ("python-protobuf" ,python-protobuf)
428 ("python-aiohttp" ,python-aiohttp)
429 ("python-aiohttp-socks" ,python-aiohttp-socks)
430 ("python-aiorpcx" ,python-aiorpcx)
431 ("python-certifi" ,python-certifi)
432 ("python-dnspython" ,python-dnspython)
433 ("python-jsonrpclib-pelix" ,python-jsonrpclib-pelix)))
435 `(#:tests? #f ;; package doesn't have any tests
437 (modify-phases %standard-phases
438 (add-before 'build 'patch-home
439 (lambda* (#:key outputs #:allow-other-keys)
440 (substitute* "setup.py"
442 (string-append (assoc-ref outputs "out") "/local/share"))))))))
443 (home-page "https://electrum.org/")
444 (synopsis "Bitcoin wallet")
446 "Electrum is a lightweight Bitcoin client, based on a client-server
447 protocol. It supports Simple Payment Verification (SPV) and deterministic key
448 generation from a seed. Your secret keys are encrypted and are never sent to
449 other machines/servers. Electrum does not download the Bitcoin blockchain.")
450 (license license:expat)))
452 (define-public electron-cash
455 (name "electron-cash")
461 (url "https://github.com/Electron-Cash/Electron-Cash.git")
463 (file-name (git-file-name name version))
466 "0gidrx8499v7rig7ljhd70wssshs1qm0gp1553g70i323hcbf62x"))))
468 `(,@(package-inputs electrum)
469 ("libsecp256k1", libsecp256k1)
470 ("python-dateutil", python-dateutil)
471 ("python-dnspython", python-dnspython)))
473 (substitute-keyword-arguments (package-arguments electrum)
475 `(modify-phases ,phases
476 (add-after 'unpack 'use-libsecp256k1-input
477 (lambda* (#:key inputs #:allow-other-keys)
478 (substitute* "lib/secp256k1.py"
479 (("library_paths = .* 'libsecp256k1.so.0'.")
480 (string-append "library_paths = ('" (assoc-ref inputs "libsecp256k1") "/lib/libsecp256k1.so.0'")))))))))
481 (home-page "https://electroncash.org/")
482 (synopsis "Bitcoin Cash wallet")
484 "Electroncash is a lightweight Bitcoin Cash client, based on a client-server
485 protocol. It supports Simple Payment Verification (SPV) and deterministic key
486 generation from a seed. Your secret keys are encrypted and are never sent to
487 other machines/servers. Electroncash does not download the Bitcoin Cash blockchain.")
488 (license license:expat)))
490 (define-public monero
491 ;; This package bundles easylogging++ and lmdb.
492 ;; The bundled easylogging++ is modified, and the changes will not be
494 ;; The devs deem the lmdb driver too critical a consenus component, to use
495 ;; the system's dynamically linked library.
503 (url "https://github.com/monero-project/monero.git")
504 (commit (string-append "v" version))
506 (file-name (git-file-name name version))
507 (patches (search-patches "monero-use-system-miniupnpc.patch"))
508 (modules '((guix build utils)))
511 ;; Delete bundled dependencies.
513 delete-file-recursively
514 '("external/miniupnp" "external/rapidjson"
519 "0sypa235lf2bbib4b71xpaw39h9304slgsvnsz8wmy9fq1zx009m"))))
520 (build-system cmake-build-system)
522 `(("doxygen" ,doxygen)
524 ("graphviz" ,graphviz)
525 ("pkg-config" ,pkg-config)
526 ("protobuf" ,protobuf)
528 ("qttools" ,qttools)))
534 ("libsodium" ,libsodium)
535 ("libunwind" ,libunwind)
537 ("miniupnpc" ,miniupnpc)
539 ("protobuf" ,protobuf)
540 ("rapidjson" ,rapidjson)
541 ("readline" ,readline)
546 `(#:out-of-source? #t
548 (list "-DARCH=default"
550 "-DBUILD_GUI_DEPS=ON"
551 (string-append "-DReadline_ROOT_DIR="
552 (assoc-ref %build-inputs "readline")))
554 (modify-phases %standard-phases
555 ;; tests/core_tests need a valid HOME
556 (add-before 'configure 'set-home
558 (setenv "HOME" (getcwd))
560 (add-after 'set-home 'change-log-path
562 (substitute* "contrib/epee/src/mlog.cpp"
563 (("epee::string_tools::get_current_module_folder\\(\\)")
566 "return ((std::string(getenv(\"HOME\"))) / "))
568 (add-after 'change-log-path 'fix-file-permissions-for-tests
570 (for-each make-file-writable
571 (find-files "tests/data/" "wallet_9svHk1.*"))
573 ;; Only try tests that don't need access to network or system
576 (invoke "make" "ARGS=-R 'hash|core_tests' --verbose" "test")))
577 (add-after 'check 'unit-tests
579 (let ((excluded-unit-tests
581 '("AddressFromURL.Success"
582 "AddressFromURL.Failure"
583 "DNSResolver.IPv4Success"
584 "DNSResolver.DNSSECSuccess"
585 "DNSResolver.DNSSECFailure"
586 "DNSResolver.GetTXTRecord"
587 "is_hdd.linux_os_root")
589 (invoke "tests/unit_tests/unit_tests"
590 (string-append "--gtest_filter=-"
591 excluded-unit-tests)))))
592 (add-after 'install 'install-librandomx
593 (lambda* (#:key outputs #:allow-other-keys)
594 (let ((lib (string-append (assoc-ref outputs "out") "/lib")))
595 (install-file "external/randomx/librandomx.a" lib)
597 (add-after 'install 'delete-dead-links
598 (lambda* (#:key outputs #:allow-other-keys)
599 (let ((out (assoc-ref outputs "out")))
600 (delete-file (string-append out "/lib/libprotobuf.so"))
601 (delete-file (string-append out "/lib/libusb-1.0.so"))
603 (home-page "https://web.getmonero.org/")
604 (synopsis "Command-line interface to the Monero currency")
606 "Monero is a secure, private, untraceable currency. This package provides
607 the Monero command line client and daemon.")
608 (license license:bsd-3)))
610 (define-public monero-gui
618 (url "https://github.com/monero-project/monero-gui.git")
619 (commit (string-append "v" version))))
620 (file-name (git-file-name name version))
623 "1v2mk6qp7dfdj4j4cilxp0s0phfwwnmjvpvjrz6jzzlpvbnavkr0"))))
624 (build-system qt-build-system)
626 `(("pkg-config" ,pkg-config)
627 ("qttools" ,qttools)))
631 ("libsodium" ,libsodium)
632 ("libunwind" ,libunwind)
635 ("protobuf" ,protobuf)
637 ("qtdeclarative" ,qtdeclarative)
638 ("qtgraphicaleffects" ,qtgraphicaleffects)
639 ("qtlocation" ,qtlocation)
640 ("qtmultimedia" ,qtmultimedia)
641 ("qtquickcontrols" ,qtquickcontrols)
642 ("qtquickcontrols2",qtquickcontrols2)
644 ("qtxmlpatterns" ,qtxmlpatterns)
645 ("unbound" ,unbound)))
647 `(("monero" ,monero)))
649 `(#:tests? #f ; No tests
651 (modify-phases %standard-phases
652 (add-after 'unpack 'fix-makefile-vars
654 (substitute* "src/zxcvbn-c/makefile"
657 (add-after 'fix-makefile-vars 'fix-paths
658 (lambda* (#:key inputs outputs #:allow-other-keys)
659 (let ((boost (assoc-ref inputs "boost"))
660 (monero (assoc-ref inputs "monero"))
661 (openssl (assoc-ref inputs "openssl"))
662 (qttools (assoc-ref inputs "qttools"))
663 (out (assoc-ref outputs "out")))
664 (substitute* "monero-wallet-gui.pro"
665 (("-L/usr/local/lib")
667 (("-L/usr/local/opt/openssl/lib")
668 (string-append "-L" openssl "/lib"))
669 (("-L/usr/local/opt/boost/lib")
670 (string-append "-L" boost "/lib"))
671 (("\\$\\$\\[QT_INSTALL_BINS\\]/lrelease")
672 (string-append qttools "/bin/lrelease"))
673 (("\\$\\$\\[QT_INSTALL_BINS\\]/lupdate")
674 (string-append qttools "/bin/lupdate")))
675 (substitute* "deployment.pri"
676 (("/opt/\\$\\$\\{TARGET\\}/bin")
677 (string-append out "/bin")))
678 (substitute* "src/daemon/DaemonManager.cpp"
679 (("QApplication::applicationDirPath\\(\\) \\+ \"/monerod")
680 (string-append "\"" monero "/bin/monerod")))
682 (add-after 'fix-paths 'make-qt-deterministic
684 (setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1")
686 (add-after 'make-qt-deterministic 'fix-version
688 (substitute* "build.sh"
689 (("echo .*> version.js")
691 (with-output-to-file "version.js"
694 "var GUI_VERSION = \"~a\"~@
695 var GUI_MONERO_VERSION = \"~a\"~%"
697 ,(package-version monero))))
703 (invoke "qmake" "../monero-wallet-gui.pro" "CONFIG+=release")))
704 (add-before 'build 'build-zxcvbn-c
706 (invoke "make" "-C" "../src/zxcvbn-c"))))))
707 (home-page "https://web.getmonero.org/")
708 (synopsis "Graphical user interface for the Monero currency")
710 "Monero is a secure, private, untraceable currency. This package provides
711 the Monero GUI client.")
712 (license license:bsd-3)))
714 (define-public monero-core
715 (deprecated-package "monero-core" monero-gui))
717 (define-public python-trezor-agent
719 (name "python-trezor-agent")
725 (url "https://github.com/romanz/trezor-agent.git")
726 (commit (string-append "v" version))))
727 (file-name (git-file-name name version))
729 (base32 "0q99vbfd3h85s8rnjipnmldixabqmmlk5w9karv6f0rhyi54f4zv"))))
730 (build-system python-build-system)
733 (modify-phases %standard-phases
734 (add-after 'unpack 'remove-requires-backports-shutil-which
735 ;; Remove requires on backport of shutil_which, as python 3.4+ has
736 ;; a built-in implementation supported in python-trezor-agent.
738 (substitute* "setup.py"
739 (("'backports.shutil_which>=3.5.1',") ""))
742 (add-after 'install 'check
743 (lambda* (#:key outputs inputs #:allow-other-keys)
744 ;; Make installed package available for running the tests.
745 (add-installed-pythonpath inputs outputs)
746 (invoke "py.test"))))))
748 `(("python-configargparse" ,python-configargparse)
749 ("python-daemon" ,python-daemon)
750 ("python-docutils" ,python-docutils)
751 ("python-ecdsa" ,python-ecdsa)
752 ("python-ed25519" ,python-ed25519)
753 ("python-mnemonic" ,python-mnemonic)
754 ("python-pymsgbox" ,python-pymsgbox)
755 ("python-semver" ,python-semver)
756 ("python-unidecode" ,python-unidecode)
757 ("python-wheel" ,python-wheel)))
760 ("python-mock" ,python-mock)
761 ("python-pytest" ,python-pytest)))
762 (home-page "https://github.com/romanz/trezor-agent")
763 (synopsis "Use hardware wallets as SSH and GPG agent")
765 "@code{libagent} is a library that allows using TREZOR, Keepkey and
766 Ledger Nano as a hardware SSH/GPG agent.")
767 (license license:lgpl3)))
769 (define-public python-mnemonic
771 (name "python-mnemonic")
776 (uri (pypi-uri "mnemonic" version))
778 (base32 "0cd9prmdj8wzdmc7lxbf9lz0xrlkvak5ignag406mmfbn81fndsf"))))
779 (build-system python-build-system)
781 `(("python-pbkdf2" ,python-pbkdf2)))
782 (home-page "https://github.com/trezor/python-mnemonic")
783 (synopsis "Implementation of Bitcoin BIP-0039")
784 (description "@code{mnemonic} is a library that provides an implementation
785 of Bitcoin BIP-0039.")
786 (license license:expat)))
788 (define-public python2-mnemonic
789 (package-with-python2 python-mnemonic))
791 (define-public python-ledgerblue
793 (name "python-ledgerblue")
798 (uri (pypi-uri "ledgerblue" version))
801 "010mghaqh1cmz3a0ifc3f40mmyplilwlw7kpha2mzyrrff46p9gb"))))
802 (build-system python-build-system)
804 `(("python-ecpy" ,python-ecpy)
805 ("python-future" ,python-future)
806 ("python-hidapi" ,python-hidapi)
807 ("python-pillow" ,python-pillow)
808 ("python-protobuf" ,python-protobuf)
809 ("python-pycrypto" ,python-pycrypto)))
810 (home-page "https://github.com/LedgerHQ/blue-loader-python")
811 (synopsis "Python library to communicate with Ledger Blue/Nano S")
812 (description "@code{ledgerblue} is a Python library to communicate with
813 Ledger Blue/Nano S.")
814 (license license:asl2.0)))
816 (define-public python2-ledgerblue
817 (package-with-python2 python-ledgerblue))
819 (define-public python-trezor
821 (name "python-trezor")
826 (uri (pypi-uri "trezor" version))
829 "0211m027vlvyqy83kwbjjjxalb04xgf1klv0h0y0f0yhj07516n7"))))
830 (build-system python-build-system)
833 (modify-phases %standard-phases
834 ;; Default tests run device-specific tests which fail, only run specific tests.
836 (lambda* (#:key inputs outputs #:allow-other-keys)
837 ;; Delete tests that require network access.
838 (delete-file "trezorlib/tests/unit_tests/test_tx_api.py")
839 (invoke "python" "-m" "pytest" "--pyarg" "trezorlib.tests.unit_tests"))))))
841 `(("python-click" ,python-click)
842 ("python-construct" ,python-construct)
843 ("python-ecdsa" ,python-ecdsa)
844 ("python-libusb1" ,python-libusb1)
845 ("python-mnemonic" ,python-mnemonic)
846 ("python-pyblake2" ,python-pyblake2)
847 ("python-requests" ,python-requests)
848 ("python-typing-extensions" ,python-typing-extensions)))
851 `(("protobuf" ,protobuf)
852 ("python-black" ,python-black)
853 ("python-protobuf" ,python-protobuf)
854 ("python-isort" ,python-isort)
855 ("python-pyqt" ,python-pyqt)
856 ("python-pytest" ,python-pytest)))
857 (home-page "https://github.com/trezor/python-trezor")
858 (synopsis "Python library for communicating with TREZOR Hardware Wallet")
859 (description "@code{trezor} is a Python library for communicating with
860 TREZOR Hardware Wallet.")
861 (license license:lgpl3)))
863 (define-public python-keepkey
865 (name "python-keepkey")
870 (uri (pypi-uri "keepkey" version))
873 "0z3d0m6364v9dv0njs4cd5m5ai6j6v35xaaxfxl90m9vmyxy81vd"))))
874 (build-system python-build-system)
877 (modify-phases %standard-phases
879 (add-after 'install 'check
880 (lambda* (#:key inputs outputs #:allow-other-keys)
881 (add-installed-pythonpath inputs outputs)
882 (apply invoke "python" (find-files "tests/unit" "\\.py$")))))))
884 `(("python-ecdsa" ,python-ecdsa)
885 ("python-hidapi" ,python-hidapi)
886 ("python-libusb1" ,python-libusb1)
887 ("python-mnemonic" ,python-mnemonic)
888 ("python-protobuf" ,python-protobuf)))
889 (home-page "https://github.com/keepkey/python-keepkey")
890 (synopsis "Python library for communicating with KeepKey Hardware Wallet")
891 (description "@code{keepkey} is a Python library for communicating with
892 the KeepKey Hardware Wallet.")
893 (license license:lgpl3)))
895 (define-public python2-keepkey
896 (package-with-python2 python-keepkey))
898 (define-public ledger-agent
900 (name "ledger-agent")
905 (uri (pypi-uri "ledger_agent" version))
908 "03zj602m2rln9yvr08dswy56vzkbldp8b074ixwzz525dafblr92"))))
909 (build-system python-build-system)
911 `(("python-ledgerblue" ,python-ledgerblue)
912 ("python-trezor-agent" ,python-trezor-agent)))
913 (home-page "http://github.com/romanz/trezor-agent")
914 (synopsis "Ledger as hardware SSH/GPG agent")
915 (description "This package allows using Ledger as hardware SSH/GPG agent.
917 Usage for SSH: trezor-agent foo@@example.com --connect
918 Usage for GPG: Initialize using trezor-gpg init \"Foo <foo@@example.com>\"
919 Then set the environment variable GNUPGHOME to
920 \"${HOME}/.gnupg/trezor\".")
921 (license license:lgpl3)))
923 (define-public trezor-agent
925 (name "trezor-agent")
930 (uri (pypi-uri "trezor_agent" version))
933 "144657c7bn0a667dq5fv5r6j7iilxf3h9agj29v1m2qpq40g0az8"))))
935 ;; Tests fail with "AttributeError: module 'attr' has no attribute 's'".
937 (modify-phases %standard-phases
938 (add-after 'wrap 'fixup-agent-py
939 (lambda* (#:key inputs outputs #:allow-other-keys)
940 (let* ((out (assoc-ref outputs "out")))
941 ;; overwrite the wrapper with the real thing.
942 (install-file "./trezor_agent.py"
943 (string-append out "/bin"))
945 (build-system python-build-system)
947 `(("python-trezor" ,python-trezor)
948 ("python-trezor-agent" ,python-trezor-agent)))
950 `(("python-hidapi" ,python-hidapi)))
951 (home-page "https://github.com/romanz/trezor-agent")
952 (synopsis "Using Trezor as hardware SSH/GPG agent")
953 (description "This package allows using Trezor as a hardware SSH/GPG
955 (license license:lgpl3)))
957 (define-public keepkey-agent
959 (name "keepkey-agent")
964 (uri (pypi-uri "keepkey_agent" version))
967 "03779gvlx70i0nnry98i4pl1d92604ix5x6jgdfkrdgzqbh5vj27"))))
968 (build-system python-build-system)
970 `(("python-keepkey" ,python-keepkey)
971 ("python-trezor-agent" ,python-trezor-agent)))
972 (home-page "http://github.com/romanz/trezor-agent")
973 (synopsis "KeepKey as hardware SSH/GPG agent")
974 (description "This package allows using KeepKey as a hardware SSH/GPG
976 (license license:lgpl3)))
978 (define-public python-stdnum
980 (name "python-stdnum")
985 (uri (pypi-uri "python-stdnum" version))
988 "0hvr47q32xbyiznpmbg4r8rcvxhnf0lwf33hcpnynyik57djy5np"))))
989 (build-system python-build-system)
991 "https://arthurdejong.org/python-stdnum/")
993 "Python module to handle standardized number and code formats")
995 "This is a Python library that aims to provide functions to handle,
996 parse and validate standard numbers.
997 The module supports more than 100 different number formats
998 amongst which a great number of VAT and other tax numbers,
999 personal identity and company identification codes,
1000 international standard numbers (ISBN, IBAN, EAN, etc.)
1001 and various other formats.
1002 The module also inclused implementations of the Verhoeff,
1003 Luhn and family of ISO/IEC 7064 check digit algorithms. ")
1004 (license license:lgpl2.1+)))
1006 (define-public python2-stdnum
1007 (package-with-python2 python-stdnum))
1009 (define-public python-duniterpy
1011 (name "python-duniterpy")
1016 (uri (pypi-uri "duniterpy" version))
1018 (base32 "1h8d8cnr6k5sw4cqy8r82zy4ldzpvn4nlk2221lz2haqq7xm4s5z"))))
1019 (build-system python-build-system)
1021 ;; FIXME: Tests fail with: "ModuleNotFoundError: No module named
1022 ;; 'tests'". Not sure how to handle this.
1025 (modify-phases %standard-phases
1026 ;; "setup.py" tries to open missing "requirements.txt".
1027 (add-after 'unpack 'ignore-missing-file
1029 (substitute* "setup.py"
1030 (("open\\('requirements\\.txt'\\)") "[]"))
1033 `(("aiohttp" ,python-aiohttp)
1034 ("attrs" ,python-attrs)
1035 ("base58" ,python-base58)
1036 ("jsonschema" ,python-jsonschema)
1037 ("libnacl" ,python-libnacl)
1038 ("pyaes" ,python-pyaes)
1039 ("pylibscrypt" ,python-pylibscrypt)
1040 ("pypeg2" ,python-pypeg2)))
1041 (home-page "https://git.duniter.org/clients/python/duniterpy")
1042 (synopsis "Python implementation of Duniter API")
1043 (description "@code{duniterpy} is an implementation of
1044 @uref{https://github.com/duniter/duniter/, duniter} API. Its
1047 @item Support Duniter's Basic Merkle API and protocol
1048 @item Asynchronous/synchronous without threads
1049 @item Support HTTP, HTTPS and Web Socket transport for Basic Merkle API
1050 @item Support Elasticsearch Duniter4j API
1051 @item Duniter signing key
1052 @item Sign/verify and encrypt/decrypt messages with the Duniter credentials
1054 (license license:gpl3+)))
1056 (define-public silkaj
1063 (uri (pypi-uri "silkaj" version))
1065 (base32 "0hrn0jwg415z7wjkp0myvw85wszlfi18f56j03075xxakr4dmi2j"))))
1066 (build-system python-build-system)
1068 `(#:tests? #f)) ;no test
1070 `(("click" ,python-click)
1071 ("duniterpy" ,python-duniterpy)
1072 ("ipaddress" ,python-ipaddress)
1073 ("pynacl" ,python-pynacl)
1074 ("tabulate" ,python-tabulate)
1075 ("texttable" ,python-texttable)))
1076 (home-page "https://git.duniter.org/clients/python/silkaj")
1077 (synopsis "Command line client for Duniter network")
1078 (description "@code{Silkaj} is a command line client for the
1079 @uref{https://github.com/duniter/duniter/, Duniter} network.
1083 @item information about currency,
1084 @item issuers difficulty to generate next block,
1085 @item network view of nodes,
1086 @item list of last issuers,
1087 @item send transactions,
1088 @item get account amount.
1090 (license license:agpl3+)))
1092 (define-public grisbi
1100 "mirror://sourceforge/grisbi/grisbi%20stable/"
1101 (version-major+minor version) ".x/" version
1102 "/grisbi-" version ".tar.bz2"))
1105 "1piiyyxjsjbw9gcqydvknzxmmfgh8kdqal12ywrxyxih2afwnvbw"))))
1106 (build-system glib-or-gtk-build-system)
1108 `(#:configure-flags (list "--without-ofx")))
1110 `(("dconf" ,dconf)))
1112 `(("glib" ,glib "bin") ; glib-compile-schemas
1113 ("pkg-config" ,pkg-config)
1114 ("intltool" ,intltool)))
1117 ("libgsf" ,libgsf)))
1118 (synopsis "Personal accounting application")
1119 (description "Grisbi is a personal accounting application written by
1120 French developers that is designed to follow French accounting rules.
1121 Grisbi can manage multiple accounts, currencies and users. It manages
1122 third party, expenditure and receipt categories, budgetary lines,
1123 financial years, budget estimates, bankcard management and other
1125 (home-page "http://grisbi.org")
1126 (license license:gpl2+)))
1128 (define-public trezord
1136 (url "https://github.com/trezor/trezord-go.git")
1137 (commit (string-append "v" version))))
1140 "0nqzpq0i3crh0i4r1cppja5sn3rwi1fv9afxzwzv63096x5l30a7"))
1141 (file-name (git-file-name name version))))
1142 (build-system go-build-system)
1144 '(#:import-path "github.com/trezor/trezord-go"))
1145 (home-page "https://trezor.io")
1146 (synopsis "Trezor Communication Daemon aka Trezor Bridge (written in Go)")
1147 (description "This allows a Trezor hardware wallet to communicate to the
1149 (license license:lgpl3+)))
1151 (define-public bitcoin-abc
1153 (inherit bitcoin-core)
1154 (name "bitcoin-abc")
1158 (uri (string-append "https://download.bitcoinabc.org/"
1159 version "/src/bitcoin-abc-"
1163 "0py5ilfi4r8qh5r9637vwch27sqrrn0dg9rz8bccnj3lp2xpzw27"))))
1165 `(("autoconf" ,autoconf)
1166 ("automake" ,automake)
1167 ("libtool" ,libtool)
1168 ("pkg-config" ,pkg-config)
1169 ("python" ,python) ; for the tests
1170 ("util-linux" ,util-linux) ; provides the hexdump command for tests
1171 ("qttools" ,qttools)))
1175 ("libevent" ,libevent)
1176 ("miniupnpc" ,miniupnpc)
1177 ("openssl" ,openssl)
1178 ("protobuf" ,protobuf)
1179 ("qrencode" ,qrencode)
1182 (home-page "https://www.bitcoinabc.org/")
1183 (synopsis "Bitcoin ABC peer-to-peer full node for the Bitcoin Cash protocol")
1185 "Bitcoin Cash brings sound money to the world, fulfilling the original
1186 promise of Bitcoin as Peer-to-Peer Electronic Cash. Merchants and users are
1187 empowered with low fees and reliable confirmations is a digital currency that
1188 enables instant payments to anyone anywhere in the world. It uses
1189 peer-to-peer technology to operate without central authority: managing
1190 transactions and issuing money are carried out collectively by the network.
1191 As a fork it implemented changes lowering the time between blocks and now
1192 offers confimations after less than 5 seconds and have significantly lower
1193 fees that BTC. Bitcoin ABC is the reference implementation of the Bitcoin
1194 Cash protocol. This package provides the Bitcoin Cash command line client and
1195 a client based on Qt. This is a fork of Bitcoin Core.")))
1197 (define-public libofx
1204 (url "https://github.com/libofx/libofx")
1206 (file-name (git-file-name name version))
1209 "1jx56ma351p8af8dvavygjwf6ipa7qbgq7bpdsymwj27apdnixfy"))))
1210 (build-system gnu-build-system)
1212 '(#:parallel-build? #f ;fails with -j64
1214 (list (string-append "--with-opensp-includes="
1215 (assoc-ref %build-inputs "opensp")
1216 "/include/OpenSP"))))
1218 `(("autoconf" ,autoconf)
1219 ("automake" ,automake)
1220 ("gengetopt" ,gengetopt)
1221 ("help2man" ,help2man)
1222 ("libtool" ,libtool)
1223 ("pkg-config" ,pkg-config)))
1226 ("libxml++-2" ,libxml++-2)
1227 ("opensp" ,opensp)))
1228 (home-page "http://libofx.sourceforge.net/")
1229 (synopsis "Library supporting the Open Financial Exchange format")
1231 "The LibOFX library is an API designed to allow applications to very easily
1232 support OFX command responses, usually provided by financial institutions. The
1233 following three utilities are included with the library:
1235 @item @code{ofxdump}
1236 @item @code{ofx2qif}
1237 @item @code{ofxconnect}
1239 (license license:gpl2+)))
1241 (define-public opensp
1247 (uri (string-append "mirror://sourceforge/openjade/opensp/"
1248 version "/OpenSP-" version ".tar.gz"))
1251 "1khpasr6l0a8nfz6kcf3s81vgdab8fm2dj291n5r2s53k228kx2p"))))
1252 (build-system gnu-build-system)
1254 `(("gettext" ,gettext-minimal)))
1256 `(("docbook-xml" ,docbook-xml-4.1.2)
1257 ("docbook-xsl" ,docbook-xsl)
1260 `(;; TODO: Fix and enable tests.
1263 (modify-phases %standard-phases
1264 (add-after 'unpack 'patch-docbook-paths
1265 (lambda* (#:key inputs #:allow-other-keys)
1266 (let ((xmldoc (string-append (assoc-ref inputs "docbook-xml")
1267 "/xml/dtd/docbook"))
1268 (xsldoc (string-append (assoc-ref inputs "docbook-xsl")
1269 "/xml/xsl/docbook-xsl-"
1270 ,(package-version docbook-xsl))))
1271 (substitute* (find-files "docsrc" "\\.xml$")
1272 (("/usr/share/sgml/docbook/xml-dtd-4.1.2") xmldoc)
1273 (("http://.*/docbookx\\.dtd")
1274 (string-append xmldoc "/docbookx.dtd")))
1275 ;; Directly pass the path to the stylesheet to xmlto.
1276 (substitute* "docsrc/Makefile.in"
1278 (string-append "$(XMLTO) -x " xsldoc
1279 "/manpages/docbook.xsl")))
1281 (home-page "http://openjade.sourceforge.net/")
1282 (synopsis "Suite of SGML/XML processing tools")
1283 (description "OpenSP is an object-oriented toolkit for SGML parsing and
1284 entity management.")
1286 ;; expat license with added clause regarding advertising
1287 (license:non-copyleft
1289 "See COPYING in the distribution."))))
1291 (define-public bitcoin-unlimited
1293 (name "bitcoin-unlimited")
1299 (url "https://github.com/BitcoinUnlimited/BitcoinUnlimited.git")
1300 (commit (string-append "bucash" version))))
1301 (file-name (git-file-name name version))
1303 (base32 "05rcd73mg2fb2zb6b1imzspck6jhcy3xymrr7n24kwjrzmvihdpx"))))
1304 (build-system gnu-build-system)
1306 `(("autoconf" ,autoconf)
1307 ("automake" ,automake)
1308 ("libtool" ,libtool)
1309 ("pkg-config" ,pkg-config)
1310 ("python" ,python) ; for the tests
1311 ("util-linux" ,util-linux) ; provides the hexdump command for tests
1312 ("qttools" ,qttools)))
1316 ("libevent" ,libevent)
1317 ("miniupnpc" ,miniupnpc)
1318 ("openssl" ,openssl)
1319 ("protobuf" ,protobuf)
1320 ("qrencode" ,qrencode)
1327 ;; Boost is not found unless specified manually.
1328 (string-append "--with-boost="
1329 (assoc-ref %build-inputs "boost"))
1330 ;; XXX: The configure script looks up Qt paths by
1331 ;; `pkg-config --variable=host_bins Qt5Core`, which fails to pick
1332 ;; up executables residing in 'qttools', so we specify them here.
1333 (string-append "ac_cv_path_LRELEASE="
1334 (assoc-ref %build-inputs "qttools")
1336 (string-append "ac_cv_path_LUPDATE="
1337 (assoc-ref %build-inputs "qttools")
1340 (modify-phases %standard-phases
1341 (add-after 'unpack 'fix-tests
1343 ;; TODO: Find why utilprocess_tests never ends. Disable for now.
1344 (substitute* "src/test/utilprocess_tests.cpp"
1345 (("#if \\(BOOST_OS_LINUX && \\(BOOST_VERSION >= 106500\\)\\)")
1348 (add-before 'configure 'make-qt-deterministic
1350 ;; Make Qt deterministic.
1351 (setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1")
1353 (add-before 'check 'set-home
1355 (setenv "HOME" (getenv "TMPDIR")) ; tests write to $HOME
1357 (home-page "https://www.bitcoinunlimited.info/")
1358 (synopsis "Client for the Bitcoin Cash protocol")
1360 "Bitcoin Unlimited is a client for the Bitcoin Cash peer-to-peer
1361 electronic cash system. This package provides a command line client and
1363 (license license:expat)))