From 06f11bf2fc83fa9c07414e4e32d7834bff5f8829 Mon Sep 17 00:00:00 2001 From: hashirama Date: Tue, 5 Nov 2024 21:42:04 -0400 Subject: [PATCH] fix goldendict-ng the previous patch for goldendict-ng couldn't get rid of the wrapper, it still relies heavily on environment variables to find other components --- ajatt/packages/dictionaries.scm | 27 ++++++++++++++++----------- 1 file changed, 16 insertions(+), 11 deletions(-) diff --git a/ajatt/packages/dictionaries.scm b/ajatt/packages/dictionaries.scm index b3898dd..df133c3 100644 --- a/ajatt/packages/dictionaries.scm +++ b/ajatt/packages/dictionaries.scm @@ -71,11 +71,24 @@ #~(list "-DCMAKE_BUILD_TYPE=Release" (string-append "PKG_CONFIG_PATH=" #$(this-package-input "qtbase") - "/include/qt6/QtPrintSupport")))) + "/include/qt6/QtPrintSupport")) + #:phases + #~(modify-phases %standard-phases + (add-after 'install 'wrap-qt-process-path + (lambda* (#:key inputs outputs #:allow-other-keys) + (wrap-program (search-input-file outputs "bin/goldendict") + `("QTWEBENGINE_RESOURCES_PATH" = + (,(search-input-directory + inputs "/share/qt6/resources"))) + `("QTWEBENGINEPROCESS_PATH" = + (,(search-input-file + inputs "/lib/qt6/libexec/QtWebEngineProcess"))))))))) (native-inputs (list hunspell icu4c libeb + qtwebengine + qtsvg libtiff libvorbis libxkbcommon @@ -105,18 +118,10 @@ qtmultimedia gstreamer qtbase + qtsvg xproto)) (propagated-inputs - (list qtwebengine)) - (search-paths - (list (search-path-specification - (variable "QTWEBENGINE_RESOURCES_PATH") - (files (list "share/qt6/resources"))) - (search-path-specification - (variable "QTWEBENGINEPROCESS_PATH") - (file-type 'regular) - (separator " ") - (files (list "lib/qt6/libexec/QtWebEngineProcess"))))) + (list qtsvg)) (synopsis "A feature-rich dictionary lookup program") (description "GoldenDict is a feature-rich dictionary lookup program,