GNU bug report logs - #76015
[PATCH] gnu: haruna: Fix finding yt-dlp.

Previous Next

Package: guix-patches;

Reported by: Sughosha <sughosha <at> disroot.org>

Date: Sun, 2 Feb 2025 16:14:01 UTC

Severity: normal

Tags: patch

Done: Nicolas Goaziou <mail <at> nicolasgoaziou.fr>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 76015 in the body.
You can then email your comments to 76015 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#76015; Package guix-patches. (Sun, 02 Feb 2025 16:14:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Sughosha <sughosha <at> disroot.org>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Sun, 02 Feb 2025 16:14:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Sughosha <sughosha <at> disroot.org>
To: guix-patches <at> gnu.org
Cc: Sughosha <sughosha <at> disroot.org>
Subject: [PATCH] gnu: haruna: Fix finding yt-dlp.
Date: Sun,  2 Feb 2025 21:42:21 +0530
* gnu/packages/kde-multimedia.scm (yt-dlp)[arguments]<#:phases>: Add wrap-path.

Change-Id: I4f2f7303b02441399c042d4bdd8e7586adfd9fe3
---
 gnu/packages/kde-multimedia.scm | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/kde-multimedia.scm b/gnu/packages/kde-multimedia.scm
index ad0b504268..4d859cdedb 100644
--- a/gnu/packages/kde-multimedia.scm
+++ b/gnu/packages/kde-multimedia.scm
@@ -156,7 +156,15 @@ (define-public haruna
                (base32 "0gvwsxlrwn2s6i4agmwa0r1lq1fybfyxv933g2z3n76qnn9mkbrb"))))
     (build-system qt-build-system)
     (arguments
-     (list #:qtbase qtbase))
+     (list #:qtbase qtbase
+           #:phases
+           #~(modify-phases %standard-phases
+               (add-after 'qt-wrap 'wrap-path
+                 (lambda _
+                   (wrap-program (string-append #$output "/bin/haruna")
+                     `("PATH" ":" prefix
+                       (,(string-append #$(this-package-input "yt-dlp")
+                                       "/bin")))))))))
     (native-inputs
      (list extra-cmake-modules))
     (inputs

base-commit: 070c073d508d3197f0235adc424aec287e7dd916
-- 
2.47.1





Information forwarded to guix-patches <at> gnu.org:
bug#76015; Package guix-patches. (Thu, 06 Feb 2025 17:18:01 GMT) Full text and rfc822 format available.

Message #8 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Z572 <z572 <at> z572.online>
To: Sughosha via Guix-patches via <guix-patches <at> gnu.org>
Cc: 76015 <at> debbugs.gnu.org, Sughosha <sughosha <at> disroot.org>
Subject: Re: [bug#76015] [PATCH] gnu: haruna: Fix finding yt-dlp.
Date: Fri, 07 Feb 2025 01:17:00 +0800
[Message part 1 (text/plain, inline)]
Sughosha via Guix-patches via <guix-patches <at> gnu.org> writes:

> * gnu/packages/kde-multimedia.scm (yt-dlp)[arguments]<#:phases>: Add wrap-path.
>
> Change-Id: I4f2f7303b02441399c042d4bdd8e7586adfd9fe3
> ---
>  gnu/packages/kde-multimedia.scm | 10 +++++++++-
>  1 file changed, 9 insertions(+), 1 deletion(-)
>
> diff --git a/gnu/packages/kde-multimedia.scm b/gnu/packages/kde-multimedia.scm
> index ad0b504268..4d859cdedb 100644
> --- a/gnu/packages/kde-multimedia.scm
> +++ b/gnu/packages/kde-multimedia.scm
> @@ -156,7 +156,15 @@ (define-public haruna
>                 (base32 "0gvwsxlrwn2s6i4agmwa0r1lq1fybfyxv933g2z3n76qnn9mkbrb"))))
>      (build-system qt-build-system)
>      (arguments
> -     (list #:qtbase qtbase))
> +     (list #:qtbase qtbase
> +           #:phases
> +           #~(modify-phases %standard-phases
> +               (add-after 'qt-wrap 'wrap-path
> +                 (lambda _
> +                   (wrap-program (string-append #$output "/bin/haruna")
> +                     `("PATH" ":" prefix
> +                       (,(string-append #$(this-package-input "yt-dlp")
> +                                       "/bin")))))))))

see src/application.cpp
QString Application::youtubeDlExecutable()
{
    auto ytDlp = QStandardPaths::findExecutable(u"yt-dlp"_s);
    if (!ytDlp.isEmpty()) {
        return ytDlp;
    }

    auto youtubeDl = QStandardPaths::findExecutable(u"youtube-dl"_s);
    if (!youtubeDl.isEmpty()) {
        return youtubeDl;
    }

    return QString();
}

It is better to replace findExecutable(u"yt-dlp"_s) with
findExecutable(u"/gnu/store/xxxx/bin/yt-dlp"_s)

>      (native-inputs
>       (list extra-cmake-modules))
>      (inputs
>
> base-commit: 070c073d508d3197f0235adc424aec287e7dd916
[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#76015; Package guix-patches. (Thu, 06 Feb 2025 17:18:02 GMT) Full text and rfc822 format available.

Information forwarded to guix-patches <at> gnu.org:
bug#76015; Package guix-patches. (Sat, 08 Feb 2025 12:56:02 GMT) Full text and rfc822 format available.

Message #14 received at 76015 <at> debbugs.gnu.org (full text, mbox):

From: Sughosha <sughosha <at> disroot.org>
To: 76015 <at> debbugs.gnu.org
Cc: Sughosha <sughosha <at> disroot.org>
Subject: [PATCH v2] gnu: haruna: Fix finding yt-dlp.
Date: Sat,  8 Feb 2025 18:24:36 +0530
* gnu/packages/kde-multimedia.scm (haruna)[arguments]<#:phases>: Add
fix-yt-dlp-path.

Change-Id: I3f6e3f5b9f2dd56ec69b6ea38a0da9a5e01a1909
---
 gnu/packages/kde-multimedia.scm | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/kde-multimedia.scm b/gnu/packages/kde-multimedia.scm
index ad0b504268..ac0b90c9b6 100644
--- a/gnu/packages/kde-multimedia.scm
+++ b/gnu/packages/kde-multimedia.scm
@@ -156,7 +156,16 @@ (define-public haruna
                (base32 "0gvwsxlrwn2s6i4agmwa0r1lq1fybfyxv933g2z3n76qnn9mkbrb"))))
     (build-system qt-build-system)
     (arguments
-     (list #:qtbase qtbase))
+     (list #:qtbase qtbase
+           #:phases
+           #~(modify-phases %standard-phases
+               (add-after 'unpack 'fix-yt-dlp-path
+                 (lambda* (#:key inputs #:allow-other-keys)
+                   (substitute* "src/application.cpp"
+                     (("findExecutable\\(u\"yt-dlp\"")
+                      (string-append "findExecutable(u\""
+                                     (search-input-file inputs "bin/yt-dlp")
+                                     "\""))))))))
     (native-inputs
      (list extra-cmake-modules))
     (inputs

base-commit: b64d3168af697ceb2a96e7e2c62bcf418b8a586a
-- 
2.47.1





Reply sent to Nicolas Goaziou <mail <at> nicolasgoaziou.fr>:
You have taken responsibility. (Mon, 03 Mar 2025 21:33:02 GMT) Full text and rfc822 format available.

Notification sent to Sughosha <sughosha <at> disroot.org>:
bug acknowledged by developer. (Mon, 03 Mar 2025 21:33:02 GMT) Full text and rfc822 format available.

Message #19 received at 76015-done <at> debbugs.gnu.org (full text, mbox):

From: Nicolas Goaziou <mail <at> nicolasgoaziou.fr>
To: 76015-done <at> debbugs.gnu.org
Cc: Z572 <z572 <at> z572.online>, Sughosha <sughosha <at> disroot.org>
Subject: Re: [PATCH] gnu: haruna: Fix finding yt-dlp.
Date: Mon, 03 Mar 2025 22:32:21 +0100
Hello,

> * gnu/packages/kde-multimedia.scm (haruna)[arguments]<#:phases>: Add
> fix-yt-dlp-path.

Closing as this is already applied.

Thanks.
-- 
Nicolas Goaziou






bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Tue, 01 Apr 2025 11:24:42 GMT) Full text and rfc822 format available.

This bug report was last modified 81 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.