GNU bug report logs -
#37147
[PATCH] gnu: lyx: Wrap binary to let it find qtsvg
Previous Next
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 37147 in the body.
You can then email your comments to 37147 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
guix-patches <at> gnu.org
:
bug#37147
; Package
guix-patches
.
(Thu, 22 Aug 2019 16:17:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
"Xavier Montillet" <xavierm02 <at> guix.xavierm02.fr>
:
New bug report received and forwarded. Copy sent to
guix-patches <at> gnu.org
.
(Thu, 22 Aug 2019 16:17:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
From 18929f612dcb3c9210a953c29713ff6cb2a5f222 Mon Sep 17 00:00:00 2001
From: Xavier Montillet <xavierm02 <at> guix.xavierm02.fr>
Date: Thu, 22 Aug 2019 17:48:42 +0200
Subject: [PATCH 1/1] gnu: lyx: Wrap binary to let it find qtsvg
Wrap the lyx binary to set QT_PLUGIN_PATH to let it find qtsvg. Without this, when running lyx in a profile without qtsvg, the menu will contain text instead of icons.
The prefix was changed and the symlink phase was removed because wrapping the lyx binary made it fail to find the lyx system directory. Other solutions were setting the LYX_DIR_23x environment variable and using the -sysdir argument.
Changing the prefix and removing the symlink phase made the LYX_DIR_23x environment variable used earlier in the build redundant, and it was therefore removed.
---
gnu/packages/tex.scm | 26 ++++++++++----------------
1 file changed, 10 insertions(+), 16 deletions(-)
diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm
index 5be86e7d9e..9111580fce 100644
--- a/gnu/packages/tex.scm
+++ b/gnu/packages/tex.scm
@@ -6215,7 +6215,7 @@ and Karl Berry.")
(method url-fetch)
(uri (string-append "http://ftp.lyx.org/pub/lyx/stable/"
(version-major+minor version) ".x/"
- name "-" version ".tar.gz"))
+ "lyx-" version ".tar.gz"))
(sha256
(base32
"0vr0qwis6rhind6azfa270hqxci7rj8qb1kk5x6lm80mc34nvrqi"))
@@ -6231,9 +6231,7 @@ and Karl Berry.")
"-DLYX_INSTALL=1"
"-DLYX_RELEASE=1"
,(string-append "-DLYX_INSTALL_PREFIX="
- (assoc-ref %outputs "out")
- ;; Exact name and level is necessary.
- "/lyx" ,(version-major+minor version)))
+ (assoc-ref %outputs "out")))
#:phases
(modify-phases %standard-phases
;; See ;; https://www.lyx.org/trac/changeset/3a123b90af838b08680471d87170c38e56787df9/lyxgit
@@ -6265,19 +6263,15 @@ and Karl Berry.")
,version
"/src/tests/check_layout.cmake")
(const #t))
- (setenv (string-append "LYX_DIR_"
- (string-join
- (string-split
- ,(version-major+minor version) #\-)) "x")
- (string-append (getcwd) "/../lyx-" ,version "/lib"))
#t))
- (add-after 'install 'install-symlinks
- (lambda* (#:key outputs #:allow-other-keys)
- (let ((out (assoc-ref outputs "out")))
- (mkdir-p (string-append out "/bin"))
- (symlink (string-append "../lyx" ,(version-major+minor version)
- "/bin/lyx" ,(version-major+minor version))
- (string-append out "/bin/lyx" ,(version-major+minor version)))
+ ;; Ensure that qtsvg is found at run time (otherwise the menu has text instead of icons), even if it's not installed in the current profile
+ (add-after 'install 'wrap-executable
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (lyx-bin-name (string-append "lyx" ,(version-major+minor version)))
+ (lyx-bin-path (string-append out "/bin/" lyx-bin-name)))
+ (wrap-program lyx-bin-path
+ `("QT_PLUGIN_PATH" ":" = (,(string-append (assoc-ref inputs "qtsvg") "/lib/qt5/plugins/"))))
#t))))))
(inputs
`(("boost" ,boost)
--
2.23.0
Information forwarded
to
guix-patches <at> gnu.org
:
bug#37147
; Package
guix-patches
.
(Sat, 21 Mar 2020 20:10:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 37147 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hello Xavier,
"Xavier Montillet" <xavierm02 <at> guix.xavierm02.fr> writes:
> From 18929f612dcb3c9210a953c29713ff6cb2a5f222 Mon Sep 17 00:00:00 2001
> From: Xavier Montillet <xavierm02 <at> guix.xavierm02.fr>
> Date: Thu, 22 Aug 2019 17:48:42 +0200
> Subject: [PATCH 1/1] gnu: lyx: Wrap binary to let it find qtsvg
>
> Wrap the lyx binary to set QT_PLUGIN_PATH to let it find qtsvg. Without this, when running lyx in a profile without qtsvg, the menu will contain text instead of icons.
> The prefix was changed and the symlink phase was removed because wrapping the lyx binary made it fail to find the lyx system directory. Other solutions were setting the LYX_DIR_23x environment variable and using the -sysdir argument.
> Changing the prefix and removing the symlink phase made the LYX_DIR_23x environment variable used earlier in the build redundant, and it was therefore removed.
Sorry for the slooooow response. This seems like a good idea, but the
patch no longer applies cleanly. Do you think you can rebase it on the
current master branch?
Apologies for the inconvenience!
[signature.asc (application/pgp-signature, inline)]
Information forwarded
to
guix-patches <at> gnu.org
:
bug#37147
; Package
guix-patches
.
(Sun, 22 Mar 2020 07:18:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 37147 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
On Sat, Mar 21, 2020 at 09:09:20PM +0100, Marius Bakke wrote:
> Hello Xavier,
>
> "Xavier Montillet" <xavierm02 <at> guix.xavierm02.fr> writes:
>
> > From 18929f612dcb3c9210a953c29713ff6cb2a5f222 Mon Sep 17 00:00:00 2001
> > From: Xavier Montillet <xavierm02 <at> guix.xavierm02.fr>
> > Date: Thu, 22 Aug 2019 17:48:42 +0200
> > Subject: [PATCH 1/1] gnu: lyx: Wrap binary to let it find qtsvg
> >
> > Wrap the lyx binary to set QT_PLUGIN_PATH to let it find qtsvg. Without this, when running lyx in a profile without qtsvg, the menu will contain text instead of icons.
> > The prefix was changed and the symlink phase was removed because wrapping the lyx binary made it fail to find the lyx system directory. Other solutions were setting the LYX_DIR_23x environment variable and using the -sysdir argument.
> > Changing the prefix and removing the symlink phase made the LYX_DIR_23x environment variable used earlier in the build redundant, and it was therefore removed.
>
> Sorry for the slooooow response. This seems like a good idea, but the
> patch no longer applies cleanly. Do you think you can rebase it on the
> current master branch?
>
> Apologies for the inconvenience!
Would this be a good use for the qt-build-system?
--
Efraim Flashner <efraim <at> flashner.co.il> אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
[signature.asc (application/pgp-signature, inline)]
Information forwarded
to
guix-patches <at> gnu.org
:
bug#37147
; Package
guix-patches
.
(Fri, 29 May 2020 00:43:01 GMT)
Full text and
rfc822 format available.
Message #14 received at 37147 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
On Sun, Mar 22, 2020 at 09:16:43AM +0200, Efraim Flashner wrote:
> Would this be a good use for the qt-build-system?
Ping!
[signature.asc (application/pgp-signature, inline)]
Reply sent
to
Efraim Flashner <efraim <at> flashner.co.il>
:
You have taken responsibility.
(Thu, 11 Jun 2020 07:03:01 GMT)
Full text and
rfc822 format available.
Notification sent
to
"Xavier Montillet" <xavierm02 <at> guix.xavierm02.fr>
:
bug acknowledged by developer.
(Thu, 11 Jun 2020 07:03:02 GMT)
Full text and
rfc822 format available.
Message #19 received at 37147-done <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
On Thu, May 28, 2020 at 08:42:38PM -0400, Leo Famulari wrote:
> On Sun, Mar 22, 2020 at 09:16:43AM +0200, Efraim Flashner wrote:
> > Would this be a good use for the qt-build-system?
>
> Ping!
It ended up being a bit more involved but I pushed a couple of patches.
The icons now show up as expected.
--
Efraim Flashner <efraim <at> flashner.co.il> אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
[signature.asc (application/pgp-signature, inline)]
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Thu, 09 Jul 2020 11:24:04 GMT)
Full text and
rfc822 format available.
This bug report was last modified 4 years and 266 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.