Archived
1
0
Fork 0

gnu: monero-gui: Update to 0.15.0.3.

* gnu/packages/finance.scm (monero-gui): Update to 0.15.0.3.
  [build-system]: Use qt-build-system.
  [inputs]: Remove qtwebchannel and qtx11extras.
  [arguments]: Merge fix-library-paths, fix-monerod-path, fix-qt-paths and
  fix-install-path phases into a fix-paths phase. Remove custom build,
  change-dir and wrap-program phases. Add configure and build-zxcvbn-c phases.
This commit is contained in:
Guillaume Le Vaillant 2020-01-10 09:52:20 +01:00
parent 8a6c5b5d99
commit 230e5db71e
No known key found for this signature in database
GPG key ID: 6BE8208ADF21FE3F

View file

@ -11,7 +11,7 @@
;;; Copyright © 2018 Adriano Peluso <catonano@gmail.com> ;;; Copyright © 2018 Adriano Peluso <catonano@gmail.com>
;;; Copyright © 2018, 2019 Nicolas Goaziou <mail@nicolasgoaziou.fr> ;;; Copyright © 2018, 2019 Nicolas Goaziou <mail@nicolasgoaziou.fr>
;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net> ;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
;;; Copyright © 2019 Guillaume Le Vaillant <glv@posteo.net> ;;; Copyright © 2019, 2020 Guillaume Le Vaillant <glv@posteo.net>
;;; Copyright © 2019 Tanguy Le Carrour <tanguy@bioneland.org> ;;; Copyright © 2019 Tanguy Le Carrour <tanguy@bioneland.org>
;;; Copyright © 2019 Martin Becze <mjbecze@riseup.net> ;;; Copyright © 2019 Martin Becze <mjbecze@riseup.net>
;;; Copyright © 2019 Sebastian Schott <sschott@mailbox.org> ;;; Copyright © 2019 Sebastian Schott <sschott@mailbox.org>
@ -41,6 +41,7 @@
#:use-module (guix build-system python) #:use-module (guix build-system python)
#:use-module (guix build-system glib-or-gtk) #:use-module (guix build-system glib-or-gtk)
#:use-module (guix build-system go) #:use-module (guix build-system go)
#:use-module (guix build-system qt)
#:use-module (guix utils) #:use-module (guix utils)
#:use-module (gnu packages) #:use-module (gnu packages)
#:use-module (gnu packages aidc) #:use-module (gnu packages aidc)
@ -603,7 +604,7 @@ the Monero command line client and daemon.")
(define-public monero-gui (define-public monero-gui
(package (package
(name "monero-gui") (name "monero-gui")
(version "0.15.0.1") (version "0.15.0.3")
(source (source
(origin (origin
(method git-fetch) (method git-fetch)
@ -613,8 +614,8 @@ the Monero command line client and daemon.")
(file-name (git-file-name name version)) (file-name (git-file-name name version))
(sha256 (sha256
(base32 (base32
"08j8kkncdn57xql0bhmlzjpjkdfhqbpda1p07r797q8qi0nl4w8n")))) "1v2mk6qp7dfdj4j4cilxp0s0phfwwnmjvpvjrz6jzzlpvbnavkr0"))))
(build-system gnu-build-system) (build-system qt-build-system)
(native-inputs (native-inputs
`(("pkg-config" ,pkg-config) `(("pkg-config" ,pkg-config)
("qttools" ,qttools))) ("qttools" ,qttools)))
@ -634,53 +635,45 @@ the Monero command line client and daemon.")
("qtquickcontrols" ,qtquickcontrols) ("qtquickcontrols" ,qtquickcontrols)
("qtquickcontrols2",qtquickcontrols2) ("qtquickcontrols2",qtquickcontrols2)
("qtsvg" ,qtsvg) ("qtsvg" ,qtsvg)
("qtwebchannel" ,qtwebchannel)
("qtx11extras" ,qtx11extras)
("qtxmlpatterns" ,qtxmlpatterns) ("qtxmlpatterns" ,qtxmlpatterns)
("unbound" ,unbound))) ("unbound" ,unbound)))
(propagated-inputs (propagated-inputs
`(("monero" ,monero))) `(("monero" ,monero)))
(arguments (arguments
`(#:modules ((guix build gnu-build-system) `(#:tests? #f ; No tests
(guix build qt-utils)
(guix build utils))
#:imported-modules (,@%gnu-build-system-modules
(guix build qt-utils))
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(delete 'configure) (add-after 'unpack 'fix-makefile-vars
(delete 'check)
(add-before 'build 'fix-makefile-vars
(lambda _ (lambda _
(substitute* "src/zxcvbn-c/makefile" (substitute* "src/zxcvbn-c/makefile"
(("\\?=") "=")) (("\\?=") "="))
#t)) #t))
(add-after 'fix-makefile-vars 'fix-library-paths (add-after 'fix-makefile-vars 'fix-paths
(lambda* (#:key inputs #:allow-other-keys) (lambda* (#:key inputs outputs #:allow-other-keys)
(substitute* "monero-wallet-gui.pro" (let ((boost (assoc-ref inputs "boost"))
(("-L/usr/local/lib") (monero (assoc-ref inputs "monero"))
"") (openssl (assoc-ref inputs "openssl"))
(("-L/usr/local/opt/openssl/lib") (qttools (assoc-ref inputs "qttools"))
(string-append "-L" (assoc-ref inputs "openssl") "/lib")) (out (assoc-ref outputs "out")))
(("-L/usr/local/opt/boost/lib") (substitute* "monero-wallet-gui.pro"
(string-append "-L" (assoc-ref inputs "boost") "/lib"))) (("-L/usr/local/lib")
#t)) "")
(add-after 'fix-library-paths 'fix-monerod-path (("-L/usr/local/opt/openssl/lib")
(lambda* (#:key inputs #:allow-other-keys) (string-append "-L" openssl "/lib"))
(substitute* "src/daemon/DaemonManager.cpp" (("-L/usr/local/opt/boost/lib")
(("QApplication::applicationDirPath\\(\\) \\+ \"/monerod") (string-append "-L" boost "/lib"))
(string-append "\"" (assoc-ref inputs "monero") (("\\$\\$\\[QT_INSTALL_BINS\\]/lrelease")
"/bin/monerod"))) (string-append qttools "/bin/lrelease"))
#t)) (("\\$\\$\\[QT_INSTALL_BINS\\]/lupdate")
(add-after 'fix-monerod-path 'fix-qt-paths (string-append qttools "/bin/lupdate")))
(lambda* (#:key inputs #:allow-other-keys) (substitute* "deployment.pri"
(substitute* "monero-wallet-gui.pro" (("/opt/\\$\\$\\{TARGET\\}/bin")
(("\\$\\$\\[QT_INSTALL_BINS\\]/lrelease") (string-append out "/bin")))
(string-append (assoc-ref inputs "qttools") "/bin/lrelease")) (substitute* "src/daemon/DaemonManager.cpp"
(("\\$\\$\\[QT_INSTALL_BINS\\]/lupdate") (("QApplication::applicationDirPath\\(\\) \\+ \"/monerod")
(string-append (assoc-ref inputs "qttools") "/bin/lupdate"))) (string-append "\"" monero "/bin/monerod")))
#t)) #t)))
(add-after 'fix-qt-paths 'make-qt-deterministic (add-after 'fix-paths 'make-qt-deterministic
(lambda _ (lambda _
(setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1") (setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1")
#t)) #t))
@ -697,24 +690,14 @@ the Monero command line client and daemon.")
,version ,version
,(package-version monero)))) ,(package-version monero))))
#t)) #t))
(replace 'build (replace 'configure
(lambda _
(invoke "./build.sh")))
(add-after 'build 'fix-install-path
(lambda* (#:key outputs #:allow-other-keys)
(substitute* "build/Makefile"
(("/opt/monero-wallet-gui")
(assoc-ref outputs "out")))
#t))
(add-before 'install 'change-dir
(lambda _ (lambda _
(mkdir-p "build")
(chdir "build") (chdir "build")
#t)) (invoke "qmake" "../monero-wallet-gui.pro" "CONFIG+=release")))
(add-after 'install 'wrap-program (add-before 'build 'build-zxcvbn-c
(lambda* (#:key outputs #:allow-other-keys) (lambda _
(let ((out (assoc-ref outputs "out"))) (invoke "make" "-C" "../src/zxcvbn-c"))))))
(wrap-qt-program out "monero-wallet-gui"))
#t)))))
(home-page "https://web.getmonero.org/") (home-page "https://web.getmonero.org/")
(synopsis "Graphical user interface for the Monero currency") (synopsis "Graphical user interface for the Monero currency")
(description (description