* Re: [isar-cip-core][RFC 1/2] copy and symlink dpkg db to ro-rootfs
[not found] ` <464bd7dc-85a8-4fd5-8452-256c02f60ff4@siemens.com>
@ 2024-02-19 11:19 ` MOESSBAUER, Felix
2024-02-19 11:35 ` Jan Kiszka
0 siblings, 1 reply; 2+ messages in thread
From: MOESSBAUER, Felix @ 2024-02-19 11:19 UTC (permalink / raw)
To: cip-dev, Kiszka, Jan; +Cc: shivanand.kunijadar, quirin.gylstorff, isar-users
On Tue, 2024-02-13 at 11:33 +0100, Jan Kiszka wrote:
> > > > image_configure_fstab() {
> > > > sudo tee '${IMAGE_ROOTFS}/etc/fstab' << EOF
> > > > # Begin /etc/fstab
> > > > diff --git a/recipes-core/cip-read-only-rootfs/cip-read-only-
> > > > rootfs_0.1.bb b/recipes-core/cip-read-only-rootfs/cip-read-
> > > > only-
> > > > rootfs_0.1.bb
> > > > new file mode 100644
> > > > index 0000000..76453ab
> > > > --- /dev/null
> > > > +++ b/recipes-core/cip-read-only-rootfs/cip-read-only-
> > > > rootfs_0.1.bb
> > > > @@ -0,0 +1,26 @@
> > > > +#
> > > > +# CIP Core, generic profile
> > > > +#
> > > > +# Copyright (c) Siemens AG, 2024
> > > > +#
> > > > +# Authors:
> > > > +# Felix Moessbauer <felix.moessbauer@siemens.com>
> > > > +#
> > > > +# SPDX-License-Identifier: MIT
> > > > +
> > > > +# Note: This requires debhelper-compat 13, which limits it to
> > > > bookworm
> > > > +
> > > > +inherit dpkg
> > > > +
> > > > +SRC_URI = " \
> > > > + file://${BPN}.tmpfiles \
> > > > + file://control"
> > > > +
> > > > +do_prepare_build[cleandirs] += "${S}/debian"
> > > > +do_prepare_build() {
> > > > + deb_debianize
> > > > + rm -f ${S}/debian/compat
> > > > + cp ${WORKDIR}/control \
> > > > + ${WORKDIR}/${BPN}.tmpfiles \
> > > > + ${S}/debian/
> > >
> > > dpkg-raw wouldn't have simplified this? I think even compat is
> > > not
> > > customizable.
> >
> > DPKG raw in general is only useful for a trivial copy of files into
> > the
> > rootfs. Here, we need the debhelper logic to process the
> > tmpfiles.d.
> > Also, we need to update the compat mode so that these debhelpers
> > become
> > active. I don't see any value in mixing this with dpkg-raw, as most
> > parts would need to be written manually anyways.
> >
>
> With [1] (granted, not yet upstream), this would simply be
This is already merged into ISAR-next (as f1b8679), but as we only
reference ISAR-master in CIP, we need to wait for that to get
integrated there as well. I can prepare everything, but still we need
to wait for the ISAR update.
Putting the ISAR list in CC.
Felix
>
> inherit dpkg-raw
>
> DPKG_ARCH = "all"
>
> SRC_URI = "file://${BPN}.tmpfiles"
>
> do_install() {
> cp ${WORKDIR}/${BPN}.tmpfiles ${S}/debian/
> }
>
>
> The whole control file would become obsolete.
>
> Jan
>
> [1]
> https://groups.google.com/d/msgid/isar-users/20240201101236.3555681-1-Quirin.Gylstorff%40siemens.com
>
--
Siemens AG, Technology
Linux Expert Center
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [isar-cip-core][RFC 1/2] copy and symlink dpkg db to ro-rootfs
2024-02-19 11:19 ` [isar-cip-core][RFC 1/2] copy and symlink dpkg db to ro-rootfs MOESSBAUER, Felix
@ 2024-02-19 11:35 ` Jan Kiszka
0 siblings, 0 replies; 2+ messages in thread
From: Jan Kiszka @ 2024-02-19 11:35 UTC (permalink / raw)
To: Moessbauer, Felix (T CED OES-DE), cip-dev
Cc: shivanand.kunijadar, Gylstorff, Quirin (T CED OES-DE), isar-users
On 19.02.24 12:19, Moessbauer, Felix (T CED OES-DE) wrote:
> On Tue, 2024-02-13 at 11:33 +0100, Jan Kiszka wrote:
>>>>> image_configure_fstab() {
>>>>> sudo tee '${IMAGE_ROOTFS}/etc/fstab' << EOF
>>>>> # Begin /etc/fstab
>>>>> diff --git a/recipes-core/cip-read-only-rootfs/cip-read-only-
>>>>> rootfs_0.1.bb b/recipes-core/cip-read-only-rootfs/cip-read-
>>>>> only-
>>>>> rootfs_0.1.bb
>>>>> new file mode 100644
>>>>> index 0000000..76453ab
>>>>> --- /dev/null
>>>>> +++ b/recipes-core/cip-read-only-rootfs/cip-read-only-
>>>>> rootfs_0.1.bb
>>>>> @@ -0,0 +1,26 @@
>>>>> +#
>>>>> +# CIP Core, generic profile
>>>>> +#
>>>>> +# Copyright (c) Siemens AG, 2024
>>>>> +#
>>>>> +# Authors:
>>>>> +# Felix Moessbauer <felix.moessbauer@siemens.com>
>>>>> +#
>>>>> +# SPDX-License-Identifier: MIT
>>>>> +
>>>>> +# Note: This requires debhelper-compat 13, which limits it to
>>>>> bookworm
>>>>> +
>>>>> +inherit dpkg
>>>>> +
>>>>> +SRC_URI = " \
>>>>> + file://${BPN}.tmpfiles \
>>>>> + file://control"
>>>>> +
>>>>> +do_prepare_build[cleandirs] += "${S}/debian"
>>>>> +do_prepare_build() {
>>>>> + deb_debianize
>>>>> + rm -f ${S}/debian/compat
>>>>> + cp ${WORKDIR}/control \
>>>>> + ${WORKDIR}/${BPN}.tmpfiles \
>>>>> + ${S}/debian/
>>>>
>>>> dpkg-raw wouldn't have simplified this? I think even compat is
>>>> not
>>>> customizable.
>>>
>>> DPKG raw in general is only useful for a trivial copy of files into
>>> the
>>> rootfs. Here, we need the debhelper logic to process the
>>> tmpfiles.d.
>>> Also, we need to update the compat mode so that these debhelpers
>>> become
>>> active. I don't see any value in mixing this with dpkg-raw, as most
>>> parts would need to be written manually anyways.
>>>
>>
>> With [1] (granted, not yet upstream), this would simply be
>
> This is already merged into ISAR-next (as f1b8679), but as we only
> reference ISAR-master in CIP, we need to wait for that to get
> integrated there as well. I can prepare everything, but still we need
> to wait for the ISAR update.
We don't have a master-only rule in isar-cip-core /wrt isar because isar
is not rebasing next (unlike many other projects).
Jan
>
> Putting the ISAR list in CC.
>
> Felix
>
>
>>
>> inherit dpkg-raw
>>
>> DPKG_ARCH = "all"
>>
>> SRC_URI = "file://${BPN}.tmpfiles"
>>
>> do_install() {
>> cp ${WORKDIR}/${BPN}.tmpfiles ${S}/debian/
>> }
>>
>>
>> The whole control file would become obsolete.
>>
>> Jan
>>
>> [1]
>> https://groups.google.com/d/msgid/isar-users/20240201101236.3555681-1-Quirin.Gylstorff%40siemens.com
>>
>
--
Siemens AG, Technology
Linux Expert Center
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-02-19 11:35 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <20240130115648.311177-1-felix.moessbauer@siemens.com>
[not found] ` <20240130115648.311177-2-felix.moessbauer@siemens.com>
[not found] ` <29de90aa-1a30-4f17-9538-e6a2334bc343@siemens.com>
[not found] ` <cd3b8b6b9d762cda263489202a5c16ecbb3fe68a.camel@siemens.com>
[not found] ` <464bd7dc-85a8-4fd5-8452-256c02f60ff4@siemens.com>
2024-02-19 11:19 ` [isar-cip-core][RFC 1/2] copy and symlink dpkg db to ro-rootfs MOESSBAUER, Felix
2024-02-19 11:35 ` Jan Kiszka
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox