public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
From: Zhihang Wei <wzh@ilbers.de>
To: Cedric Hombourger <cedric.hombourger@siemens.com>,
	isar-users@googlegroups.com
Subject: Re: [PATCH] deb-src: do not error but warn for missing source packages
Date: Wed, 26 Nov 2025 11:03:16 +0100	[thread overview]
Message-ID: <bf1a2ab6-5fa0-454f-8ea8-6cbad891a5e2@ilbers.de> (raw)
In-Reply-To: <20251123070029.1674527-1-cedric.hombourger@siemens.com>

Applied to next, thanks.

On 11/23/25 08:00, 'Cedric Hombourger' via isar-users wrote:
> Some package repositories may only provide binary packages and no
> source packages. While this is unfortunate, it shouldn't be fatal
> either. Collect names and versions and print a warning for each.
>
> Signed-off-by: Cedric Hombourger <cedric.hombourger@siemens.com>
> ---
>   meta/classes/deb-dl-dir.bbclass | 12 ++++++++++--
>   1 file changed, 10 insertions(+), 2 deletions(-)
>
> diff --git a/meta/classes/deb-dl-dir.bbclass b/meta/classes/deb-dl-dir.bbclass
> index 16ccd426..7ebc3526 100644
> --- a/meta/classes/deb-dl-dir.bbclass
> +++ b/meta/classes/deb-dl-dir.bbclass
> @@ -41,7 +41,8 @@ debsrc_download() {
>       # since "set -e" is used)
>       avail=$(mktemp)
>       wanted=$(mktemp)
> -    trap "rm -f ${avail} ${wanted}" EXIT
> +    missing=$(mktemp)
> +    trap "rm -f ${avail} ${wanted} ${missing}" EXIT
>   
>       # List all packages known to apt
>       apt-cache -o APT::Architecture=${DISTRO_ARCH} -o Dir=${rootfs} dumpavail \
> @@ -80,9 +81,16 @@ debsrc_download() {
>                   -- \
>                   apt-get -o APT::Architecture=${DISTRO_ARCH} \
>                           -o Dir="${rootfs}" -y --download-only \
> -                        --only-source source "${src}=${version}"
> +                        --only-source source "${src}=${version}" \
> +                || echo "${src} ${version}" >> ${missing}
>           }
>       done
> +
> +    # warn for missing source packages
> +    sort -u -o ${missing} ${missing}
> +    while read pkg ver; do
> +        bbwarn "could not find or download sources for ${pkg} ${ver}"
> +    done < ${missing}
>       ) 9>"${DEBSRCDIR}/${rootfs_distro}.lock"
>   }
>   

-- 
You received this message because you are subscribed to the Google Groups "isar-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/isar-users/bf1a2ab6-5fa0-454f-8ea8-6cbad891a5e2%40ilbers.de.

      reply	other threads:[~2025-11-26 10:03 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-23  7:00 'Cedric Hombourger' via isar-users
2025-11-26 10:03 ` Zhihang Wei [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bf1a2ab6-5fa0-454f-8ea8-6cbad891a5e2@ilbers.de \
    --to=wzh@ilbers.de \
    --cc=cedric.hombourger@siemens.com \
    --cc=isar-users@googlegroups.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox