diff mbox series

[bug#53336] qbittorrent: Bump 4.2.5 -> 4.4.0

Message ID 20220119115522.8192-1-kreyren@rixotstudio.cz
State Accepted
Headers show
Series [bug#53336] qbittorrent: Bump 4.2.5 -> 4.4.0 | expand

Checks

Context Check Description
cbaines/applying patch fail View Laminar job
cbaines/issue success View issue

Commit Message

Jacob Hrbek Jan. 19, 2022, 11:55 a.m. UTC
---
 gnu/packages/bittorrent.scm | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

            (lambda* (#:key outputs inputs #:allow-other-keys)
              (let ((out (assoc-ref outputs "out")))
--
2.34.0

Comments

Jacob Hrbek Jan. 19, 2022, 11:56 a.m. UTC | #1
submitted patch without signed-off-by

On 1/19/22 12:55, Jacob Hrbek wrote:
> ---
>   gnu/packages/bittorrent.scm | 11 +++++++++--
>   1 file changed, 9 insertions(+), 2 deletions(-)
>
> diff --git a/gnu/packages/bittorrent.scm b/gnu/packages/bittorrent.scm
> index fa88c91163..dc2e192c2b 100644
> --- a/gnu/packages/bittorrent.scm
> +++ b/gnu/packages/bittorrent.scm
> @@ -466,7 +466,7 @@ (define-public libtorrent-rasterbar
>   (define-public qbittorrent
>     (package
>       (name "qbittorrent")
> -    (version "4.2.5")
> +    (version "4.4.0")
>       (source
>        (origin
>          (method git-fetch)
> @@ -475,7 +475,7 @@ (define-public qbittorrent
>                (commit (string-append "release-" version))))
>          (file-name (git-file-name name version))
>          (sha256
> -        (base32 "1n613ylg6i9gisgk0dbr2kpfasyizrkdjff1r8smd4vri2qrdksn"))))
> +        (base32 "0aqrcwxi3s2alila3fa7fjs4hifkq7055wa4xvz17hajchs3l567"))))
>       (build-system
 gnu-build-system)
>       (arguments
>        `(#:configure-flags
> @@ -491,6 +491,13 @@ (define-public qbittorrent
>                              (guix build qt-utils))
>          #:phases
>          (modify-phases %standard-phases
> +         ;; The package is checking for a `python` or `python3` executable in an environment variable `PATH` which causes the search engine to fail with "Missing Python Runtime" this phase substitutes the python executables with full path in the nix store executable -- https://issues.guix.gnu.org/53334
> +	 ;; FIXME-QA(Krey): This codeblock depends on upstream's declaration of https://github.com/qbittorrent/qBittorrent/blob/master/src/base/utils/foreignapps.cpp#L277, if the file declaration changes then this phase will be malfunction -> Consider optimizing the upstream code for nix userland
> +	 (add-after 'unpack 'python-path-compat
> +           (lambda* (#:key inputs #:allow-other-keys)
> +	     (substitute* "src/base/utils/foreignapps.cpp
"
> +	       (("if \\(testPythonInstallation\\(\"python3\", pyInfo\\)\\)")
> +		 (string-append "if (testPythonInstallation(\"" (search-input-file inputs "/bin/python") "\", pyInfo))")))))
>            (add-after 'install 'wrap-qt
>              (lambda* (#:key outputs inputs #:allow-other-keys)
>                (let ((out (assoc-ref outputs "out")))
> --
> 2.34.0
>
--
Jacob Hrbek
Nicolas Goaziou Jan. 23, 2022, 9:48 a.m. UTC | #2
Hello,

Jacob Hrbek <kreyren@rixotstudio.cz> writes:

> submitted patch without signed-off-by

Thank you. However, I'm unable to apply it on top of HEAD. Could you
send it again, with a proper commit message, like the following:

--8<---------------cut here---------------start------------->8---
gnu: qbittorrent: Update to 4.4.0.

* gnu/packages/bittorrent.scm (qbittorrent): Update to 4.4.0.
--8<---------------cut here---------------end--------------->8---

Regards,
diff mbox series

Patch

diff --git a/gnu/packages/bittorrent.scm b/gnu/packages/bittorrent.scm
index fa88c91163..dc2e192c2b 100644
--- a/gnu/packages/bittorrent.scm
+++ b/gnu/packages/bittorrent.scm
@@ -466,7 +466,7 @@  (define-public libtorrent-rasterbar
 (define-public qbittorrent
   (package
     (name "qbittorrent")
-    (version "4.2.5")
+    (version "4.4.0")
     (source
      (origin
        (method git-fetch)
@@ -475,7 +475,7 @@  (define-public qbittorrent
              (commit (string-append "release-" version))))
        (file-name (git-file-name name version))
        (sha256
-        (base32 "1n613ylg6i9gisgk0dbr2kpfasyizrkdjff1r8smd4vri2qrdksn"))))
+        (base32 "0aqrcwxi3s2alila3fa7fjs4hifkq7055wa4xvz17hajchs3l567"))))
     (build-system gnu-build-system)
     (arguments
      `(#:configure-flags
@@ -491,6 +491,13 @@  (define-public qbittorrent

   (guix build qt-utils))
        #:phases
        (modify-phases %standard-phases
+         ;; The package is checking for a `python` or `python3` executable in an environment variable `PATH` which causes the search engine to fail with "Missing Python Runtime" this phase substitutes the python executables with full path in the nix store executable -- https://issues.guix.gnu.org/53334
+	 ;; FIXME-QA(Krey): This codeblock depends on upstream's declaration of https://github.com/qbittorrent/qBittorrent/blob/master/src/base/utils/foreignapps.cpp#L277, if the file declaration changes then this phase will be malfunction -> Consider optimizing the upstream code for nix userland
+	 (add-after 'unpack 'python-path-compat
+           (lambda* (#:key inputs #:allow-other-keys)
+	     (substitute* "src/base/utils/foreignapps.cpp"
+	       (("if \\(testPythonInstallation\\(\"python3\", pyInfo\\)\\)")
+		 (string-append "if (testPythonInstallation(\"" (search-input-file inputs "/bin/python"
) "\", pyInfo))")))))
          (add-after 'install 'wrap-qt