[PATCH 0/2] gnu: plover: Fix missing icons + dbus

  • Done
  • quality assurance status badge
Details
2 participants
  • Nicolas Goaziou
  • Parnikkapore
Owner
unassigned
Submitted by
Parnikkapore
Severity
normal
P
P
Parnikkapore wrote on 1 Jan 2023 17:47
(address . guix-patches@gnu.org)
cover.1672504941.git.poomklao@yahoo.com
A couple of changes to the plover package to make it function properly. The
plugin manager should also be included, but it requires a few more python
packages to be packaged into Guix, so holding off on that for now. Installing
it via pip works.

Parnikkapore (2):
gnu: plover: Wrap so that icons can be found
gnu: plover: Add dbus to inputs

gnu/packages/stenography.scm | 87 ++++++++++++++++++++----------------
1 file changed, 49 insertions(+), 38 deletions(-)

--
2.38.1
P
P
Parnikkapore wrote on 2 Jan 2023 02:08
[PATCH 2/2] gnu: plover: Add dbus to inputs
(address . 60480@debbugs.gnu.org)
d1392b204dd78dcffbb18b17807158f5eb062cd3.1672504941.git.poomklao@yahoo.com
* gnu/packages/stenography.scm (plover): Add dbus to inputs and LD_LIBRARY_PATH
Plover tries to load dbus during startup (visible with --log-level debug).
This will allow it to find it.
---
gnu/packages/stenography.scm | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)

Toggle diff (31 lines)
diff --git a/gnu/packages/stenography.scm b/gnu/packages/stenography.scm
index 3249ee4c4f..e4617031fd 100644
--- a/gnu/packages/stenography.scm
+++ b/gnu/packages/stenography.scm
@@ -27,6 +27,7 @@ (define-module (gnu packages stenography)
#:use-module (guix packages)
#:use-module (gnu packages)
#:use-module (gnu packages bash)
+ #:use-module (gnu packages glib)
#:use-module (gnu packages qt)
#:use-module (gnu packages check)
#:use-module (gnu packages libusb)
@@ -87,10 +88,15 @@ (define-public plover
,(list (string-append (assoc-ref
inputs
"qtsvg")
- "/lib/qt5/plugins/"))))))))))
+ "/lib/qt5/plugins/")))
+ `("LD_LIBRARY_PATH" prefix
+ (,(string-append (assoc-ref
+ inputs "dbus")
+ "/lib/"))))))))))
(native-inputs (list python-babel python-mock python-pytest
python-pytest-qt python-pytest-xvfb))
(inputs (list bash-minimal
+ dbus
python-appdirs
python-dbus
python-hidapi
--
2.38.1
P
P
Parnikkapore wrote on 2 Jan 2023 02:08
[PATCH 1/2] gnu: plover: Wrap so that icons can be found
(address . 60480@debbugs.gnu.org)
02f456e3dd1951b64ee6216bef6d424ff139667f.1672504941.git.poomklao@yahoo.com
* gnu/packages/stenography.scm (plover): Wrap and add qtsvg to QT_PLUGIN_PATH
This is needed for the icons in Plover's UI to appear.
---
gnu/packages/stenography.scm | 81 +++++++++++++++++++-----------------
1 file changed, 43 insertions(+), 38 deletions(-)

Toggle diff (103 lines)
diff --git a/gnu/packages/stenography.scm b/gnu/packages/stenography.scm
index 504dfc990f..3249ee4c4f 100644
--- a/gnu/packages/stenography.scm
+++ b/gnu/packages/stenography.scm
@@ -26,6 +26,7 @@ (define-module (gnu packages stenography)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
#:use-module (gnu packages)
+ #:use-module (gnu packages bash)
#:use-module (gnu packages qt)
#:use-module (gnu packages check)
#:use-module (gnu packages libusb)
@@ -55,46 +56,50 @@ (define-public plover
(package
(name "plover")
(version "4.0.0.dev12")
- (source
- (origin
- (method git-fetch)
- (uri (git-reference
- (url "https://github.com/openstenoproject/plover")
- (commit (string-append "v" version))))
- (file-name (git-file-name name version))
- (sha256
- (base32 "0vk6nh2gpn7f7rv2spi2a7n3m0d9kaan6r22mx3vwxprpbvrkbm8"))))
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/openstenoproject/plover")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0vk6nh2gpn7f7rv2spi2a7n3m0d9kaan6r22mx3vwxprpbvrkbm8"))))
(build-system python-build-system)
(arguments
- (list
- #:phases
- #~(modify-phases %standard-phases
- (replace 'check
- (lambda* (#:key tests? #:allow-other-keys)
- (when tests?
- (invoke "python" "-m" "pytest"
- "-p" "pytest-qt"
- "-p" "xvfb"
- "test"
- ;; FIXME: Ignore failing test.
- "--ignore"
- "test/gui_qt/test_dictionaries_widget.py")))))))
- (native-inputs
- (list python-babel
- python-mock
- python-pytest
- python-pytest-qt
- python-pytest-xvfb))
- (inputs
- (list python-appdirs
- python-dbus
- python-hidapi
- python-plover-stroke
- python-pyqt
- python-pyserial
- python-rtf-tokenize
- python-xlib
- qtsvg-5))
+ (list #:phases #~(modify-phases %standard-phases
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (invoke "python" "-m" "pytest"
+ "-p" "pytest-qt"
+ "-p" "xvfb"
+ "test"
+ ;; FIXME: Ignore failing test.
+ "--ignore"
+ "test/gui_qt/test_dictionaries_widget.py"))))
+ ;; Ensure that icons are found at runtime.
+ (add-after 'install 'wrap-executable
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out")))
+ (wrap-program (string-append out "/bin/plover")
+ `("QT_PLUGIN_PATH" prefix
+ ,(list (string-append (assoc-ref
+ inputs
+ "qtsvg")
+ "/lib/qt5/plugins/"))))))))))
+ (native-inputs (list python-babel python-mock python-pytest
+ python-pytest-qt python-pytest-xvfb))
+ (inputs (list bash-minimal
+ python-appdirs
+ python-dbus
+ python-hidapi
+ python-plover-stroke
+ python-pyqt
+ python-pyserial
+ python-rtf-tokenize
+ python-xlib
+ qtsvg-5))
(home-page "https://www.openstenoproject.org/plover/")
(synopsis "Stenography engine")
(description
--
2.38.1
N
N
Nicolas Goaziou wrote on 3 Jan 2023 22:00
(name . Parnikkapore via Guix-patches via)(address . guix-patches@gnu.org)
87pmbvib9s.fsf@nicolasgoaziou.fr
Hello,

Parnikkapore via Guix-patches via <guix-patches@gnu.org> writes:

Toggle quote (3 lines)
> * gnu/packages/stenography.scm (plover): Wrap and add qtsvg to QT_PLUGIN_PATH
> This is needed for the icons in Plover's UI to appear.

Applied both patches. Thank you.

Ialso made use of G-expressions, added a copyright line for you, and
added to the commit message the changes made to inputs.

Regards,
--
Nicolas Goaziou
?
Your comment

This issue is archived.

To comment on this conversation send an email to 60480@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 60480
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch