public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: isar-users <isar-users@googlegroups.com>,
	Anton Mikanovich <amikan@ilbers.de>,
	"Moessbauer, Felix (T CED SES-DE)" <felix.moessbauer@siemens.com>,
	"Schmidt, Adriaan" <adriaan.schmidt@siemens.com>
Subject: Re: [PATCH 1/2] dpkg-source: Fix source deployment
Date: Mon, 13 May 2024 09:29:00 +0200	[thread overview]
Message-ID: <9ef15f78-0c18-4d84-bf75-caea12ef1e5b@siemens.com> (raw)
In-Reply-To: <556e196e-4fcf-41df-9089-91579a6b56e7@siemens.com>

On 10.05.24 19:55, 'Jan Kiszka' via isar-users wrote:
> On 10.05.24 19:32, Jan Kiszka wrote:
>> On 05.05.24 22:32, 'Jan Kiszka' via isar-users wrote:
>>> From: Jan Kiszka <jan.kiszka@siemens.com>
>>>
>>> This failed if S was not a direct subdir of WORKDIR. Align it with
>>> do_dpkg_source.
>>>
>>> Furthermore, move -maxdepth before -name to prevent warnings about a
>>> global option specified after a positional one.
>>>
>>> Fixes: 38b832ad8248 ("meta: Implement two stage build")
>>> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
>>> ---
>>>  meta/classes/dpkg-source.bbclass | 2 +-
>>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/meta/classes/dpkg-source.bbclass b/meta/classes/dpkg-source.bbclass
>>> index 7fd5d2ed..005eafbe 100644
>>> --- a/meta/classes/dpkg-source.bbclass
>>> +++ b/meta/classes/dpkg-source.bbclass
>>> @@ -21,7 +21,7 @@ do_deploy_source[dirs] = "${S}"
>>>  do_deploy_source() {
>>>      repo_del_srcpackage "${REPO_ISAR_DIR}"/"${DISTRO}" \
>>>          "${REPO_ISAR_DB_DIR}"/"${DISTRO}" "${DEBDISTRONAME}" "${BPN}"
>>> -    find "${S}/../" -name '*\.dsc' -maxdepth 1 | while read package; do
>>> +    find "${WORKDIR}" -maxdepth 1 -name '*\.dsc' | while read package; do
>>>          repo_add_srcpackage "${REPO_ISAR_DIR}"/"${DISTRO}" \
>>>              "${REPO_ISAR_DB_DIR}"/"${DISTRO}" \
>>>              "${DEBDISTRONAME}" \
>>
>> The longer I look at this... Why is this a loop over potentially
>> multiple dsc files? We are expecting a single source package, and that
>> is assumed to be called ${BPN} (that assumption for cleaning may be
>> wrong with external source packages, though). So there should be also
>> only a single match for *_*.dsc, no?
>>
> 
> Ok, there is a case where there could be multiple dsc files: If someone
> fetches apt://foo in order to build bar.deb. Then we will not only
> deploy the sources of bar to isar-apt but also those of the dependency
> foo - ouch.
> 
> We need to figure out the source name of the target package differently.
> Not so easy...
> 

I'm inclined to assume "Source: ${BPN}" and warn during dpkg_source in
case this assumption is violated.

First, this would allow to drop all those retrieval operations later on
using debian/changelog or worse. Second, I see no other way to get the
information to a recipe that fetches the sources from isar-apt. That
recipe would otherwise have to recreate debian/changelog beforehand,
just to fetch it along with the source package.

Thoughts?

Jan

-- 
Siemens AG, Technology
Linux Expert Center


  reply	other threads:[~2024-05-13  7:29 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-05 20:32 Jan Kiszka
2024-05-05 20:32 ` [PATCH 2/2] dpkg-source: Build source package only once Jan Kiszka
2024-05-06  6:29   ` Schmidt, Adriaan
2024-05-06  6:33     ` Jan Kiszka
2024-05-06  8:11   ` Koch, Stefan
2024-05-06  9:06     ` Jan Kiszka
2024-05-13 12:04   ` Anton Mikanovich
2024-05-13 12:08     ` Jan Kiszka
2024-05-10 17:32 ` [PATCH 1/2] dpkg-source: Fix source deployment Jan Kiszka
2024-05-10 17:55   ` Jan Kiszka
2024-05-13  7:29     ` Jan Kiszka [this message]
2024-05-13  6:56   ` Jan Kiszka
2024-05-13  7:01     ` Jan Kiszka

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=9ef15f78-0c18-4d84-bf75-caea12ef1e5b@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=adriaan.schmidt@siemens.com \
    --cc=amikan@ilbers.de \
    --cc=felix.moessbauer@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