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 Nicolas Goaziou <mail@nicolasgoaziou.fr>
13 ;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
14 ;;; Copyright © 2019 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>
19 ;;; This file is part of GNU Guix.
21 ;;; GNU Guix is free software; you can redistribute it and/or modify it
22 ;;; under the terms of the GNU General Public License as published by
23 ;;; the Free Software Foundation; either version 3 of the License, or (at
24 ;;; your option) any later version.
26 ;;; GNU Guix is distributed in the hope that it will be useful, but
27 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
28 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
29 ;;; GNU General Public License for more details.
31 ;;; You should have received a copy of the GNU General Public License
32 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
34 (define-module (gnu packages finance)
35 #:use-module ((guix licenses) #:prefix license:)
36 #:use-module (guix packages)
37 #:use-module (guix download)
38 #:use-module (guix git-download)
39 #:use-module (guix build-system gnu)
40 #:use-module (guix build-system cmake)
41 #:use-module (guix build-system python)
42 #:use-module (guix build-system glib-or-gtk)
43 #:use-module (guix build-system go)
44 #:use-module (guix utils)
45 #:use-module (gnu packages)
46 #:use-module (gnu packages aidc)
47 #:use-module (gnu packages autotools)
48 #:use-module (gnu packages base)
49 #:use-module (gnu packages boost)
50 #:use-module (gnu packages check)
51 #:use-module (gnu packages compression)
52 #:use-module (gnu packages crypto)
53 #:use-module (gnu packages databases)
54 #:use-module (gnu packages documentation)
55 #:use-module (gnu packages dns)
56 #:use-module (gnu packages emacs)
57 #:use-module (gnu packages dbm)
58 #:use-module (gnu packages gnome)
59 #:use-module (gnu packages glib)
60 #:use-module (gnu packages gnupg)
61 #:use-module (gnu packages graphviz)
62 #:use-module (gnu packages groff)
63 #:use-module (gnu packages gtk)
64 #:use-module (gnu packages libedit)
65 #:use-module (gnu packages libevent)
66 #:use-module (gnu packages libunwind)
67 #:use-module (gnu packages libusb)
68 #:use-module (gnu packages linux)
69 #:use-module (gnu packages multiprecision)
70 #:use-module (gnu packages networking)
71 #:use-module (gnu packages pkg-config)
72 #:use-module (gnu packages protobuf)
73 #:use-module (gnu packages python)
74 #:use-module (gnu packages python-crypto)
75 #:use-module (gnu packages python-web)
76 #:use-module (gnu packages python-xyz)
77 #:use-module (gnu packages qt)
78 #:use-module (gnu packages readline)
79 #:use-module (gnu packages sphinx)
80 #:use-module (gnu packages texinfo)
81 #:use-module (gnu packages textutils)
82 #:use-module (gnu packages time)
83 #:use-module (gnu packages tls)
84 #:use-module (gnu packages upnp)
85 #:use-module (gnu packages version-control)
86 #:use-module (gnu packages web)
87 #:use-module (gnu packages xml)
88 #:use-module (gnu packages gnuzilla))
90 (define-public bitcoin-core
97 (string-append "https://bitcoincore.org/bin/bitcoin-core-"
98 version "/bitcoin-" version ".tar.gz"))
101 "15mz0gmm058gmq2gdpffbw25jpv7mksyhyfws6i7mqvrapqr6zaw"))))
102 (build-system gnu-build-system)
104 `(("pkg-config" ,pkg-config)
105 ("python" ,python) ; for the tests
106 ("util-linux" ,util-linux) ; provides the hexdump command for tests
107 ("qttools" ,qttools)))
109 `(("bdb" ,bdb-4.8) ; 4.8 required for compatibility
111 ("libevent" ,libevent)
112 ("miniupnpc" ,miniupnpc)
114 ("protobuf" ,protobuf)
119 ;; Boost is not found unless specified manually.
120 (string-append "--with-boost="
121 (assoc-ref %build-inputs "boost"))
122 ;; XXX: The configure script looks up Qt paths by
123 ;; `pkg-config --variable=host_bins Qt5Core`, which fails to pick
124 ;; up executables residing in 'qttools', so we specify them here.
125 (string-append "ac_cv_path_LRELEASE="
126 (assoc-ref %build-inputs "qttools")
128 (string-append "ac_cv_path_LUPDATE="
129 (assoc-ref %build-inputs "qttools")
132 (modify-phases %standard-phases
133 (add-before 'configure 'make-qt-deterministic
135 ;; Make Qt deterministic.
136 (setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1")
138 (add-before 'check 'set-home
140 (setenv "HOME" (getenv "TMPDIR")) ; tests write to $HOME
142 (add-after 'check 'check-functional
144 (invoke "python3" "./test/functional/test_runner.py"
145 (string-append "--jobs=" (number->string (parallel-job-count))))
147 (home-page "https://bitcoin.org/en/")
148 (synopsis "Bitcoin peer-to-peer client")
150 "Bitcoin is a digital currency that enables instant payments to anyone
151 anywhere in the world. It uses peer-to-peer technology to operate without
152 central authority: managing transactions and issuing money are carried out
153 collectively by the network. Bitcoin Core is the reference implementation
154 of the bitcoin protocol. This package provides the Bitcoin Core command
155 line client and a client based on Qt.")
156 (license license:expat)))
158 (define-public homebank
164 (uri (string-append "http://homebank.free.fr/public/homebank-"
168 "13ampiv68y30kc0p2560g3yz8whqpwnidfcnb9lndv93b9ca767y"))))
169 (build-system glib-or-gtk-build-system)
171 `(("pkg-config" ,pkg-config)
172 ("intltool" ,intltool)))
175 ("libsoup" ,libsoup)))
177 `(#:configure-flags (list "-without-ofx"))) ; libofx is not available yet
178 (home-page "http://homebank.free.fr/")
179 (synopsis "Graphical personal accounting application")
180 (description "HomeBank allows you to manage your personal accounts at
181 home. The seeks to be lightweight, simple and easy to use. It brings
182 features that allow you to analyze your finances in a detailed way instantly
183 and dynamically with report tools based on filtering and graphical charts.")
184 (license license:gpl2+)))
186 (define-public ledger
194 (url "https://github.com/ledger/ledger.git")
195 (commit (string-append "v" version))))
196 (file-name (git-file-name name version))
198 (base32 "0bfnrqrd6wqgsngfpqi30xh6yy86pwl25iwzrqy44q31r0zl4mm3"))))
199 (build-system cmake-build-system)
202 `("-DBUILD_DOCS:BOOL=ON"
203 "-DBUILD_WEB_DOCS:BOOL=ON"
204 "-DUSE_PYTHON:BOOL=ON"
205 "-DCMAKE_INSTALL_LIBDIR:PATH=lib")
207 (modify-phases %standard-phases
208 (add-before 'configure 'install-examples
209 (lambda* (#:key outputs #:allow-other-keys)
210 (let ((examples (string-append (assoc-ref outputs "out")
211 "/share/doc/ledger/examples")))
212 (install-file "test/input/sample.dat" examples)
213 (install-file "test/input/demo.ledger" examples))
215 (add-after 'build 'build-doc
216 (lambda _ (invoke "make" "doc")))
217 (add-before 'check 'check-setup
218 ;; One test fails if it can't set the timezone.
219 (lambda* (#:key inputs #:allow-other-keys)
221 (string-append (assoc-ref inputs "tzdata")
223 ;; Skip failing test BaselineTest_cmd-org.
224 ;; This is a known upstream issue. See
225 ;; https://github.com/ledger/ledger/issues/550
226 (setenv "ARGS" "-E BaselineTest_cmd-org")
238 ("texinfo" ,texinfo)))
239 (home-page "https://ledger-cli.org/")
240 (synopsis "Command-line double-entry accounting program")
242 "Ledger is a powerful, double-entry accounting system that is
243 accessed from the UNIX command-line. This may put off some users, since
244 there is no flashy UI, but for those who want unparalleled reporting
245 access to their data there are few alternatives.
247 Ledger uses text files for input. It reads the files and generates
248 reports; there is no other database or stored state. To use Ledger,
249 you create a file of your account names and transactions, run from the
250 command line with some options to specify input and requested reports, and
251 get output. The output is generally plain text, though you could generate
252 a graph or html instead. Ledger is simple in concept, surprisingly rich
253 in ability, and easy to use.")
254 ;; There are some extra licenses in files which do not presently get
255 ;; installed when you build this package. Different versions of the GPL
256 ;; are used in the contrib and python subdirectories. The bundled version
257 ;; of utfcpp is under the Boost 1.0 license. Also the file
258 ;; `tools/update_copyright_year` has an Expat license.
259 (license (list license:bsd-3
260 license:asl2.0 ; src/strptime.cc
261 (license:non-copyleft
262 "file://src/wcwidth.cc"
263 "See src/wcwidth.cc in the distribution.")))))
265 (define-public emacs-ledger-mode
266 ;; There have been no new releases since 2016.
267 (let ((commit "253a20dc62e137ed0ed8e1dd8614ecba116610ea")
270 (name "emacs-ledger-mode")
271 (version (git-version "3.1.1" revision commit))
276 (url "https://github.com/ledger/ledger-mode.git")
278 (file-name (git-file-name name version))
280 (base32 "06wrgkqpgvk17vibrk2qikdlqn8y63jg86marp1wgmram92mb3jk"))))
281 (build-system cmake-build-system)
283 `(#:modules ((guix build cmake-build-system)
285 (guix build emacs-utils))
286 #:imported-modules (,@%cmake-build-system-modules
287 (guix build emacs-utils))
288 #:tests? #f ; there are none
290 (modify-phases %standard-phases
291 (add-before 'build 'patch-path
292 (lambda* (#:key inputs #:allow-other-keys)
293 (let ((ledger (assoc-ref inputs "ledger")))
294 (make-file-writable "ledger-exec.el")
295 (emacs-substitute-variables "ledger-exec.el"
296 ("ledger-binary-path" (string-append ledger "/bin/ledger"))))
298 (add-after 'build 'build-doc
299 (lambda* (#:key outputs #:allow-other-keys)
300 (let ((target (string-append (assoc-ref outputs "out")
303 (invoke "makeinfo" "-o" target
304 "../source/doc/ledger-mode.texi"))
306 (add-after 'install 'relocate-elisp
307 (lambda* (#:key outputs #:allow-other-keys)
308 (let* ((site-dir (string-append (assoc-ref outputs "out")
309 "/share/emacs/site-lisp"))
310 (guix-dir (string-append site-dir "/guix.d"))
311 (orig-dir (string-append site-dir "/ledger-mode"))
312 (dest-dir (string-append guix-dir "/ledger-mode")))
314 (rename-file orig-dir dest-dir)
315 (emacs-generate-autoloads ,name dest-dir)
318 `(("ledger" ,ledger)))
320 `(("emacs-minimal" ,emacs-minimal)
321 ("texinfo" ,texinfo)))
322 (home-page "https://ledger-cli.org/")
323 (synopsis "Command-line double-entry accounting program")
325 "Ledger is a powerful, double-entry accounting system that is
326 accessed from the UNIX command-line. This may put off some users, since
327 there is no flashy UI, but for those who want unparalleled reporting
328 access to their data there are few alternatives.
330 Ledger uses text files for input. It reads the files and generates
331 reports; there is no other database or stored state. To use Ledger,
332 you create a file of your account names and transactions, run from the
333 command line with some options to specify input and requested reports, and
334 get output. The output is generally plain text, though you could generate
335 a graph or html instead. Ledger is simple in concept, surprisingly rich
336 in ability, and easy to use.
338 This package provides the Emacs mode.")
339 (license license:gpl2+))))
341 (define-public geierlein
349 (url "https://github.com/stesie/geierlein.git")
350 (commit (string-append "V" version))))
351 (file-name (git-file-name name version))
353 (base32 "00zpwr3lk2vdmd60fgdwdk0xxs52wvnm19ln2m75yfphydvkglic"))))
354 (build-system gnu-build-system)
356 `(#:tests? #f ; would require npm, python and a lot more
358 (modify-phases %standard-phases
359 (delete 'configure) ; no configure script
360 (add-after 'unpack 'override-target-directory-and-tool-paths
361 (lambda* (#:key inputs outputs #:allow-other-keys)
362 (substitute* "Makefile"
364 (string-append "prefix := " (assoc-ref outputs "out") "\n"))
365 ;; Required for tests, unused for now:
367 ;; (string-append (which "python") "\n")))
369 (string-append "INSTALL := " (which "install") "\n")))
370 (substitute* "bin/xgeierlein.in"
371 ;; Use icecat as XULRUNNER
373 (string-append "XULRUNNER=" (which "icecat") "\n"
377 `(("icecat" ,icecat)))
378 (home-page "https://stesie.github.io/geierlein/")
379 (synopsis "Free Elster client, for sending Germany VAT declarations")
381 "Geierlein is a free Elster client, i.e. an application that
382 allows to send VAT declarations to Germany's fiscal authorities.
384 Currently it is *not* possible to send returns that are due annually
385 (especially the income tax return) since the fiscal authority doesn't
386 allow to do that off the ERiC library (which is proprietary however).
387 It's not clear at the moment whether one day it will be possible to
389 (license license:agpl3+)))
391 (define-public electrum
398 (uri (string-append "https://download.electrum.org/"
402 (base32 "1g00cj1pmckd4xis8r032wmraiv3vd3zc803hnyxa2bnhj8z3bg2"))
403 (modules '((guix build utils)))
406 ;; Delete the bundled dependencies.
407 (delete-file-recursively "packages")
409 (build-system python-build-system)
411 `(("python-pyaes" ,python-pyaes)
412 ("python-pysocks" ,python-pysocks)
413 ("python-sip" ,python-sip)
414 ("python-pyqt" ,python-pyqt)
415 ("python-ecdsa" ,python-ecdsa)
416 ("python-pbkdf2" ,python-pbkdf2)
417 ("python-requests" ,python-requests)
418 ("python-qrcode" ,python-qrcode)
419 ("python-protobuf" ,python-protobuf)
420 ("python-aiohttp" ,python-aiohttp)
421 ("python-aiohttp-socks" ,python-aiohttp-socks)
422 ("python-aiorpcx" ,python-aiorpcx)
423 ("python-certifi" ,python-certifi)
424 ("python-dnspython" ,python-dnspython)
425 ("python-jsonrpclib-pelix" ,python-jsonrpclib-pelix)))
427 `(#:tests? #f ;; package doesn't have any tests
429 (modify-phases %standard-phases
430 (add-before 'build 'patch-home
431 (lambda* (#:key outputs #:allow-other-keys)
432 (substitute* "setup.py"
434 (string-append (assoc-ref outputs "out") "/local/share"))))))))
435 (home-page "https://electrum.org/")
436 (synopsis "Bitcoin wallet")
438 "Electrum is a lightweight Bitcoin client, based on a client-server
439 protocol. It supports Simple Payment Verification (SPV) and deterministic key
440 generation from a seed. Your secret keys are encrypted and are never sent to
441 other machines/servers. Electrum does not download the Bitcoin blockchain.")
442 (license license:expat)))
444 (define-public electron-cash
447 (name "electron-cash")
453 (url "https://github.com/Electron-Cash/Electron-Cash.git")
455 (file-name (git-file-name name version))
458 "0gidrx8499v7rig7ljhd70wssshs1qm0gp1553g70i323hcbf62x"))))
460 `(,@(package-inputs electrum)
461 ("libsecp256k1", libsecp256k1)
462 ("python-dateutil", python-dateutil)
463 ("python-dnspython", python-dnspython)))
465 (substitute-keyword-arguments (package-arguments electrum)
467 `(modify-phases ,phases
468 (add-after 'unpack 'use-libsecp256k1-input
469 (lambda* (#:key inputs #:allow-other-keys)
470 (substitute* "lib/secp256k1.py"
471 (("library_paths = .* 'libsecp256k1.so.0'.")
472 (string-append "library_paths = ('" (assoc-ref inputs "libsecp256k1") "/lib/libsecp256k1.so.0'")))))))))
473 (home-page "https://electroncash.org/")
474 (synopsis "Bitcoin Cash wallet")
476 "Electroncash is a lightweight Bitcoin Cash client, based on a client-server
477 protocol. It supports Simple Payment Verification (SPV) and deterministic key
478 generation from a seed. Your secret keys are encrypted and are never sent to
479 other machines/servers. Electroncash does not download the Bitcoin Cash blockchain.")
480 (license license:expat)))
482 (define-public monero
483 ;; This package bundles easylogging++ and lmdb.
484 ;; The bundled easylogging++ is modified, and the changes will not be
486 ;; The devs deem the lmdb driver too critical a consenus component, to use
487 ;; the system's dynamically linked library.
495 (url "https://github.com/monero-project/monero.git")
496 (commit (string-append "v" version))
498 (file-name (git-file-name name version))
499 (patches (search-patches "monero-use-system-miniupnpc.patch"))
500 (modules '((guix build utils)))
503 ;; Delete bundled dependencies.
505 delete-file-recursively
506 '("external/miniupnp" "external/rapidjson"
511 "0sypa235lf2bbib4b71xpaw39h9304slgsvnsz8wmy9fq1zx009m"))))
512 (build-system cmake-build-system)
514 `(("doxygen" ,doxygen)
516 ("graphviz" ,graphviz)
517 ("pkg-config" ,pkg-config)
518 ("protobuf" ,protobuf)
520 ("qttools" ,qttools)))
526 ("libsodium" ,libsodium)
527 ("libunwind" ,libunwind)
529 ("miniupnpc" ,miniupnpc)
531 ("protobuf" ,protobuf)
532 ("rapidjson" ,rapidjson)
533 ("readline" ,readline)
538 `(#:out-of-source? #t
540 (list "-DARCH=default"
542 "-DBUILD_GUI_DEPS=ON"
543 (string-append "-DReadline_ROOT_DIR="
544 (assoc-ref %build-inputs "readline")))
546 (modify-phases %standard-phases
547 ;; tests/core_tests need a valid HOME
548 (add-before 'configure 'set-home
550 (setenv "HOME" (getcwd))
552 (add-after 'set-home 'change-log-path
554 (substitute* "contrib/epee/src/mlog.cpp"
555 (("epee::string_tools::get_current_module_folder\\(\\)")
558 "return ((std::string(getenv(\"HOME\"))) / "))
560 (add-after 'change-log-path 'fix-file-permissions-for-tests
562 (for-each make-file-writable
563 (find-files "tests/data/" "wallet_9svHk1.*"))
565 ;; Only try tests that don't need access to network or system
568 (invoke "make" "ARGS=-R 'hash|core_tests' --verbose" "test")))
569 (add-after 'check 'unit-tests
571 (let ((excluded-unit-tests
573 '("AddressFromURL.Success"
574 "AddressFromURL.Failure"
575 "DNSResolver.IPv4Success"
576 "DNSResolver.DNSSECSuccess"
577 "DNSResolver.DNSSECFailure"
578 "DNSResolver.GetTXTRecord"
579 "is_hdd.linux_os_root")
581 (invoke "tests/unit_tests/unit_tests"
582 (string-append "--gtest_filter=-"
583 excluded-unit-tests)))))
584 (add-after 'install 'install-librandomx
585 (lambda* (#:key outputs #:allow-other-keys)
586 (let ((lib (string-append (assoc-ref outputs "out") "/lib")))
587 (install-file "external/randomx/librandomx.a" lib)
589 (add-after 'install 'delete-dead-links
590 (lambda* (#:key outputs #:allow-other-keys)
591 (let ((out (assoc-ref outputs "out")))
592 (delete-file (string-append out "/lib/libprotobuf.so"))
593 (delete-file (string-append out "/lib/libusb-1.0.so"))
595 (home-page "https://web.getmonero.org/")
596 (synopsis "Command-line interface to the Monero currency")
598 "Monero is a secure, private, untraceable currency. This package provides
599 the Monero command line client and daemon.")
600 (license license:bsd-3)))
602 (define-public monero-gui
610 (url "https://github.com/monero-project/monero-gui.git")
611 (commit (string-append "v" version))))
612 (file-name (git-file-name name version))
615 "08j8kkncdn57xql0bhmlzjpjkdfhqbpda1p07r797q8qi0nl4w8n"))))
616 (build-system gnu-build-system)
618 `(("pkg-config" ,pkg-config)
619 ("qttools" ,qttools)))
623 ("libsodium" ,libsodium)
624 ("libunwind" ,libunwind)
627 ("protobuf" ,protobuf)
629 ("qtdeclarative" ,qtdeclarative)
630 ("qtgraphicaleffects" ,qtgraphicaleffects)
631 ("qtlocation" ,qtlocation)
632 ("qtmultimedia" ,qtmultimedia)
633 ("qtquickcontrols" ,qtquickcontrols)
634 ("qtquickcontrols2",qtquickcontrols2)
636 ("qtwebchannel" ,qtwebchannel)
637 ("qtx11extras" ,qtx11extras)
638 ("qtxmlpatterns" ,qtxmlpatterns)
639 ("unbound" ,unbound)))
641 `(("monero" ,monero)))
643 `(#:modules ((guix build gnu-build-system)
644 (guix build qt-utils)
646 #:imported-modules (,@%gnu-build-system-modules
647 (guix build qt-utils))
649 (modify-phases %standard-phases
652 (add-before 'build 'fix-makefile-vars
654 (substitute* "src/zxcvbn-c/makefile"
657 (add-after 'fix-makefile-vars 'fix-library-paths
658 (lambda* (#:key inputs #:allow-other-keys)
659 (substitute* "monero-wallet-gui.pro"
660 (("-L/usr/local/lib")
662 (("-L/usr/local/opt/openssl/lib")
663 (string-append "-L" (assoc-ref inputs "openssl") "/lib"))
664 (("-L/usr/local/opt/boost/lib")
665 (string-append "-L" (assoc-ref inputs "boost") "/lib")))
667 (add-after 'fix-library-paths 'fix-monerod-path
668 (lambda* (#:key inputs #:allow-other-keys)
669 (substitute* "src/daemon/DaemonManager.cpp"
670 (("QApplication::applicationDirPath\\(\\) \\+ \"/monerod")
671 (string-append "\"" (assoc-ref inputs "monero")
674 (add-after 'fix-monerod-path 'fix-qt-paths
675 (lambda* (#:key inputs #:allow-other-keys)
676 (substitute* "monero-wallet-gui.pro"
677 (("\\$\\$\\[QT_INSTALL_BINS\\]/lrelease")
678 (string-append (assoc-ref inputs "qttools") "/bin/lrelease"))
679 (("\\$\\$\\[QT_INSTALL_BINS\\]/lupdate")
680 (string-append (assoc-ref inputs "qttools") "/bin/lupdate")))
682 (add-after 'fix-qt-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))))
701 (invoke "./build.sh")))
702 (add-after 'build 'fix-install-path
703 (lambda* (#:key outputs #:allow-other-keys)
704 (substitute* "build/Makefile"
705 (("/opt/monero-wallet-gui")
706 (assoc-ref outputs "out")))
708 (add-before 'install 'change-dir
712 (add-after 'install 'wrap-program
713 (lambda* (#:key outputs #:allow-other-keys)
714 (let ((out (assoc-ref outputs "out")))
715 (wrap-qt-program out "monero-wallet-gui"))
717 (home-page "https://web.getmonero.org/")
718 (synopsis "Graphical user interface for the Monero currency")
720 "Monero is a secure, private, untraceable currency. This package provides
721 the Monero GUI client.")
722 (license license:bsd-3)))
724 (define-public monero-core
725 (deprecated-package "monero-core" monero-gui))
727 (define-public python-trezor-agent
729 (name "python-trezor-agent")
735 (url "https://github.com/romanz/trezor-agent.git")
736 (commit (string-append "v" version))))
737 (file-name (git-file-name name version))
739 (base32 "0q99vbfd3h85s8rnjipnmldixabqmmlk5w9karv6f0rhyi54f4zv"))))
740 (build-system python-build-system)
743 (modify-phases %standard-phases
744 (add-after 'unpack 'remove-requires-backports-shutil-which
745 ;; Remove requires on backport of shutil_which, as python 3.4+ has
746 ;; a built-in implementation supported in python-trezor-agent.
748 (substitute* "setup.py"
749 (("'backports.shutil_which>=3.5.1',") ""))
752 (add-after 'install 'check
753 (lambda* (#:key outputs inputs #:allow-other-keys)
754 ;; Make installed package available for running the tests.
755 (add-installed-pythonpath inputs outputs)
756 (invoke "py.test"))))))
758 `(("python-configargparse" ,python-configargparse)
759 ("python-daemon" ,python-daemon)
760 ("python-docutils" ,python-docutils)
761 ("python-ecdsa" ,python-ecdsa)
762 ("python-ed25519" ,python-ed25519)
763 ("python-mnemonic" ,python-mnemonic)
764 ("python-pymsgbox" ,python-pymsgbox)
765 ("python-semver" ,python-semver)
766 ("python-unidecode" ,python-unidecode)
767 ("python-wheel" ,python-wheel)))
770 ("python-mock" ,python-mock)
771 ("python-pytest" ,python-pytest)))
772 (home-page "https://github.com/romanz/trezor-agent")
773 (synopsis "Use hardware wallets as SSH and GPG agent")
775 "@code{libagent} is a library that allows using TREZOR, Keepkey and
776 Ledger Nano as a hardware SSH/GPG agent.")
777 (license license:lgpl3)))
779 (define-public python-mnemonic
781 (name "python-mnemonic")
786 (uri (pypi-uri "mnemonic" version))
788 (base32 "0cd9prmdj8wzdmc7lxbf9lz0xrlkvak5ignag406mmfbn81fndsf"))))
789 (build-system python-build-system)
791 `(("python-pbkdf2" ,python-pbkdf2)))
792 (home-page "https://github.com/trezor/python-mnemonic")
793 (synopsis "Implementation of Bitcoin BIP-0039")
794 (description "@code{mnemonic} is a library that provides an implementation
795 of Bitcoin BIP-0039.")
796 (license license:expat)))
798 (define-public python2-mnemonic
799 (package-with-python2 python-mnemonic))
801 (define-public python-ledgerblue
803 (name "python-ledgerblue")
808 (uri (pypi-uri "ledgerblue" version))
811 "010mghaqh1cmz3a0ifc3f40mmyplilwlw7kpha2mzyrrff46p9gb"))))
812 (build-system python-build-system)
814 `(("python-ecpy" ,python-ecpy)
815 ("python-future" ,python-future)
816 ("python-hidapi" ,python-hidapi)
817 ("python-pillow" ,python-pillow)
818 ("python-protobuf" ,python-protobuf)
819 ("python-pycrypto" ,python-pycrypto)))
820 (home-page "https://github.com/LedgerHQ/blue-loader-python")
821 (synopsis "Python library to communicate with Ledger Blue/Nano S")
822 (description "@code{ledgerblue} is a Python library to communicate with
823 Ledger Blue/Nano S.")
824 (license license:asl2.0)))
826 (define-public python2-ledgerblue
827 (package-with-python2 python-ledgerblue))
829 (define-public python-trezor
831 (name "python-trezor")
836 (uri (pypi-uri "trezor" version))
839 "0211m027vlvyqy83kwbjjjxalb04xgf1klv0h0y0f0yhj07516n7"))))
840 (build-system python-build-system)
843 (modify-phases %standard-phases
844 ;; Default tests run device-specific tests which fail, only run specific tests.
846 (lambda* (#:key inputs outputs #:allow-other-keys)
847 ;; Delete tests that require network access.
848 (delete-file "trezorlib/tests/unit_tests/test_tx_api.py")
849 (invoke "python" "-m" "pytest" "--pyarg" "trezorlib.tests.unit_tests"))))))
851 `(("python-click" ,python-click)
852 ("python-construct" ,python-construct)
853 ("python-ecdsa" ,python-ecdsa)
854 ("python-libusb1" ,python-libusb1)
855 ("python-mnemonic" ,python-mnemonic)
856 ("python-pyblake2" ,python-pyblake2)
857 ("python-requests" ,python-requests)
858 ("python-typing-extensions" ,python-typing-extensions)))
861 `(("protobuf" ,protobuf)
862 ("python-black" ,python-black)
863 ("python-protobuf" ,python-protobuf)
864 ("python-isort" ,python-isort)
865 ("python-pyqt" ,python-pyqt)
866 ("python-pytest" ,python-pytest)))
867 (home-page "https://github.com/trezor/python-trezor")
868 (synopsis "Python library for communicating with TREZOR Hardware Wallet")
869 (description "@code{trezor} is a Python library for communicating with
870 TREZOR Hardware Wallet.")
871 (license license:lgpl3)))
873 (define-public python-keepkey
875 (name "python-keepkey")
880 (uri (pypi-uri "keepkey" version))
883 "0z3d0m6364v9dv0njs4cd5m5ai6j6v35xaaxfxl90m9vmyxy81vd"))))
884 (build-system python-build-system)
887 (modify-phases %standard-phases
889 (add-after 'install 'check
890 (lambda* (#:key inputs outputs #:allow-other-keys)
891 (add-installed-pythonpath inputs outputs)
892 (apply invoke "python" (find-files "tests/unit" "\\.py$")))))))
894 `(("python-ecdsa" ,python-ecdsa)
895 ("python-hidapi" ,python-hidapi)
896 ("python-libusb1" ,python-libusb1)
897 ("python-mnemonic" ,python-mnemonic)
898 ("python-protobuf" ,python-protobuf)))
899 (home-page "https://github.com/keepkey/python-keepkey")
900 (synopsis "Python library for communicating with KeepKey Hardware Wallet")
901 (description "@code{keepkey} is a Python library for communicating with
902 the KeepKey Hardware Wallet.")
903 (license license:lgpl3)))
905 (define-public python2-keepkey
906 (package-with-python2 python-keepkey))
908 (define-public ledger-agent
910 (name "ledger-agent")
915 (uri (pypi-uri "ledger_agent" version))
918 "03zj602m2rln9yvr08dswy56vzkbldp8b074ixwzz525dafblr92"))))
919 (build-system python-build-system)
921 `(("python-ledgerblue" ,python-ledgerblue)
922 ("python-trezor-agent" ,python-trezor-agent)))
923 (home-page "http://github.com/romanz/trezor-agent")
924 (synopsis "Ledger as hardware SSH/GPG agent")
925 (description "This package allows using Ledger as hardware SSH/GPG agent.
927 Usage for SSH: trezor-agent foo@@example.com --connect
928 Usage for GPG: Initialize using trezor-gpg init \"Foo <foo@@example.com>\"
929 Then set the environment variable GNUPGHOME to
930 \"${HOME}/.gnupg/trezor\".")
931 (license license:lgpl3)))
933 (define-public trezor-agent
935 (name "trezor-agent")
940 (uri (pypi-uri "trezor_agent" version))
943 "144657c7bn0a667dq5fv5r6j7iilxf3h9agj29v1m2qpq40g0az8"))))
945 ;; Tests fail with "AttributeError: module 'attr' has no attribute 's'".
947 (modify-phases %standard-phases
948 (add-after 'wrap 'fixup-agent-py
949 (lambda* (#:key inputs outputs #:allow-other-keys)
950 (let* ((out (assoc-ref outputs "out")))
951 ;; overwrite the wrapper with the real thing.
952 (install-file "./trezor_agent.py"
953 (string-append out "/bin"))
955 (build-system python-build-system)
957 `(("python-trezor" ,python-trezor)
958 ("python-trezor-agent" ,python-trezor-agent)))
960 `(("python-hidapi" ,python-hidapi)))
961 (home-page "https://github.com/romanz/trezor-agent")
962 (synopsis "Using Trezor as hardware SSH/GPG agent")
963 (description "This package allows using Trezor as a hardware SSH/GPG
965 (license license:lgpl3)))
967 (define-public keepkey-agent
969 (name "keepkey-agent")
974 (uri (pypi-uri "keepkey_agent" version))
977 "03779gvlx70i0nnry98i4pl1d92604ix5x6jgdfkrdgzqbh5vj27"))))
978 (build-system python-build-system)
980 `(("python-keepkey" ,python-keepkey)
981 ("python-trezor-agent" ,python-trezor-agent)))
982 (home-page "http://github.com/romanz/trezor-agent")
983 (synopsis "KeepKey as hardware SSH/GPG agent")
984 (description "This package allows using KeepKey as a hardware SSH/GPG
986 (license license:lgpl3)))
988 (define-public python-stdnum
990 (name "python-stdnum")
995 (uri (pypi-uri "python-stdnum" version))
998 "0hvr47q32xbyiznpmbg4r8rcvxhnf0lwf33hcpnynyik57djy5np"))))
999 (build-system python-build-system)
1001 "https://arthurdejong.org/python-stdnum/")
1003 "Python module to handle standardized number and code formats")
1005 "This is a Python library that aims to provide functions to handle,
1006 parse and validate standard numbers.
1007 The module supports more than 100 different number formats
1008 amongst which a great number of VAT and other tax numbers,
1009 personal identity and company identification codes,
1010 international standard numbers (ISBN, IBAN, EAN, etc.)
1011 and various other formats.
1012 The module also inclused implementations of the Verhoeff,
1013 Luhn and family of ISO/IEC 7064 check digit algorithms. ")
1014 (license license:lgpl2.1+)))
1016 (define-public python2-stdnum
1017 (package-with-python2 python-stdnum))
1019 (define-public python-duniterpy
1021 (name "python-duniterpy")
1026 ;; Pypi's default URI is missing "requirements.txt" file.
1028 (url "https://git.duniter.org/clients/python/duniterpy.git")
1030 (file-name (git-file-name name version))
1033 "07zsbbkzmnvyv5v0vw2d42vw3ar4iqhlidy9376ysk4ldlj1igf7"))))
1034 (build-system python-build-system)
1036 ;; Tests fail with "AttributeError: module 'attr' has no attribute 's'".
1039 (modify-phases %standard-phases
1040 (add-after 'build 'build-documentation
1042 (invoke "make" "docs")))
1043 (add-after 'build-documentation 'install-documentation
1044 (lambda* (#:key inputs outputs #:allow-other-keys)
1045 (let* ((out (assoc-ref outputs "out"))
1046 (doc (string-append out "/share/doc/" ,name)))
1048 (copy-recursively "docs/_build/html" doc))
1051 `(("sphinx" ,python-sphinx)
1052 ("sphinx-rtd-theme" ,python-sphinx-rtd-theme)))
1054 `(("aiohttp" ,python-aiohttp)
1055 ("attr" ,python-attr)
1056 ("base58" ,python-base58)
1057 ("jsonschema" ,python-jsonschema)
1058 ("libnacl" ,python-libnacl)
1059 ("pyaes" ,python-pyaes)
1060 ("pylibscrypt" ,python-pylibscrypt)
1061 ("pypeg2" ,python-pypeg2)))
1062 (home-page "https://git.duniter.org/clients/python/duniterpy")
1063 (synopsis "Python implementation of Duniter API")
1064 (description "@code{duniterpy} is an implementation of
1065 @uref{https://github.com/duniter/duniter/, duniter} API. Its
1068 @item Support Duniter's Basic Merkle API and protocol
1069 @item Asynchronous/synchronous without threads
1070 @item Support HTTP, HTTPS and Web Socket transport for Basic Merkle API
1071 @item Support Elasticsearch Duniter4j API
1072 @item Duniter signing key
1073 @item Sign/verify and encrypt/decrypt messages with the Duniter credentials
1075 (license license:gpl3+)))
1077 (define-public silkaj
1085 (url "https://git.duniter.org/clients/python/silkaj.git")
1086 (commit (string-append "v" version))))
1087 (file-name (git-file-name name version))
1090 "0yk2574yb0d0k0rg7qf0pkmjidblsad04x8hhqpy9k80rvgjcr5w"))))
1091 (build-system python-build-system)
1093 `(#:tests? #f)) ;no test
1095 `(("click" ,python-click)
1096 ("duniterpy" ,python-duniterpy)
1097 ("ipaddress" ,python-ipaddress)
1098 ("pynacl" ,python-pynacl)
1099 ("tabulate" ,python-tabulate)
1100 ("texttable" ,python-texttable)))
1101 (home-page "https://silkaj.duniter.org/")
1102 (synopsis "Command line client for Duniter network")
1103 (description "@code{Silkaj} is a command line client for the
1104 @uref{https://github.com/duniter/duniter/, Duniter} network.
1108 @item information about currency,
1109 @item issuers difficulty to generate next block,
1110 @item network view of nodes,
1111 @item list of last issuers,
1112 @item send transactions,
1113 @item get account amount.
1115 (license license:agpl3+)))
1117 (define-public grisbi
1125 "mirror://sourceforge/grisbi/grisbi%20stable/"
1126 (version-major+minor version) ".x/" version
1127 "/grisbi-" version ".tar.bz2"))
1130 "1piiyyxjsjbw9gcqydvknzxmmfgh8kdqal12ywrxyxih2afwnvbw"))))
1131 (build-system glib-or-gtk-build-system)
1133 `(#:configure-flags (list "--without-ofx")))
1135 `(("dconf" ,dconf)))
1137 `(("glib" ,glib "bin") ; glib-compile-schemas
1138 ("pkg-config" ,pkg-config)
1139 ("intltool" ,intltool)))
1142 ("libgsf" ,libgsf)))
1143 (synopsis "Personal accounting application")
1144 (description "Grisbi is a personal accounting application written by
1145 French developers that is designed to follow French accounting rules.
1146 Grisbi can manage multiple accounts, currencies and users. It manages
1147 third party, expenditure and receipt categories, budgetary lines,
1148 financial years, budget estimates, bankcard management and other
1150 (home-page "http://grisbi.org")
1151 (license license:gpl2+)))
1153 (define-public trezord
1161 (url "https://github.com/trezor/trezord-go.git")
1162 (commit (string-append "v" version))))
1165 "0nqzpq0i3crh0i4r1cppja5sn3rwi1fv9afxzwzv63096x5l30a7"))
1166 (file-name (git-file-name name version))))
1167 (build-system go-build-system)
1169 '(#:import-path "github.com/trezor/trezord-go"))
1170 (home-page "https://trezor.io")
1171 (synopsis "Trezor Communication Daemon aka Trezor Bridge (written in Go)")
1172 (description "This allows a Trezor hardware wallet to communicate to the
1174 (license license:lgpl3+)))
1176 (define-public bitcoin-abc
1178 (inherit bitcoin-core)
1179 (name "bitcoin-abc")
1183 (uri (string-append "https://download.bitcoinabc.org/"
1184 version "/src/bitcoin-abc-"
1188 "0py5ilfi4r8qh5r9637vwch27sqrrn0dg9rz8bccnj3lp2xpzw27"))))
1190 `(("autoconf" ,autoconf)
1191 ("automake" ,automake)
1192 ("libtool" ,libtool)
1193 ("pkg-config" ,pkg-config)
1194 ("python" ,python) ; for the tests
1195 ("util-linux" ,util-linux) ; provides the hexdump command for tests
1196 ("qttools" ,qttools)))
1200 ("libevent" ,libevent)
1201 ("miniupnpc" ,miniupnpc)
1202 ("openssl" ,openssl)
1203 ("protobuf" ,protobuf)
1204 ("qrencode" ,qrencode)
1207 (home-page "https://www.bitcoinabc.org/")
1208 (synopsis "Bitcoin ABC peer-to-peer full node for the Bitcoin Cash protocol")
1210 "Bitcoin Cash brings sound money to the world, fulfilling the original
1211 promise of Bitcoin as Peer-to-Peer Electronic Cash. Merchants and users are
1212 empowered with low fees and reliable confirmations is a digital currency that
1213 enables instant payments to anyone anywhere in the world. It uses
1214 peer-to-peer technology to operate without central authority: managing
1215 transactions and issuing money are carried out collectively by the network.
1216 As a fork it implemented changes lowering the time between blocks and now
1217 offers confimations after less than 5 seconds and have significantly lower
1218 fees that BTC. Bitcoin ABC is the reference implementation of the Bitcoin
1219 Cash protocol. This package provides the Bitcoin Cash command line client and
1220 a client based on Qt. This is a fork of Bitcoin Core.")))