From: Claudius Heine <claudius.heine.ext@siemens.com>
To: Henning Schild <henning.schild@siemens.com>,
Jan Kiszka <jan.kiszka@siemens.com>
Cc: isar-users@googlegroups.com,
Alexander Smirnov <alex.bluesman.smirnov@gmail.com>,
Christian Storm <christian.storm@siemens.com>,
Claudius Heine <ch@denx.de>
Subject: Re: [PATCH 5/6] meta/dpkg: add dpkg-custom class
Date: Thu, 31 Aug 2017 14:14:10 +0200 [thread overview]
Message-ID: <7c037e42-d6d5-db90-74e8-0c9b2ee94d2d@siemens.com> (raw)
In-Reply-To: <20170831113233.02d8c5b5@md1em3qc>
On 08/31/2017 11:32 AM, Henning Schild wrote:
> Am Thu, 31 Aug 2017 10:42:53 +0200
> schrieb Jan Kiszka <jan.kiszka@siemens.com>:
>
>> On 2017-08-31 10:38, [ext] Claudius Heine wrote:
>>> Hi
>>>
>>> On 08/30/2017 09:03 PM, [ext] Henning Schild wrote:
>>>> Issues:
>>>> 1. full customizations of the images is hard to impossible to
>>>> realize in a layer without touching Isar
>>>> 1.1. there is no easy way to just copy a file into the image
>>>> 1.2. configuration (passwords, groups, cfg-files changes) can not
>>>> be done in a layer, there is no way too hook into multistrap or the
>>>> configure-script
>>>>
>>>> Change:
>>>> Introduce a class that lets users create custom debian packages on
>>>> the fly, without having to create a /debian directory and actually
>>>> building. That allows you to pull in debian-dependencies, you
>>>> could have a package that has no content and is just there to
>>>> install what you need for a feature of your product.
>>>> Using package hooks (preinst, postinst ..) you can configure
>>>> pretty much all you want when installing the package.
>>>> The package can contain actual payload as well, basically any
>>>> files that come from "somewhere else". Say binary data like
>>>> wallpapers, sound files or application binaries.
>>>>
>>>> Impact:
>>>> This patch addresses the metioned issue in a way that uses debian
>>>> mechanism. All the customizations will enjoy features like
>>>> - collission protection (multiple packages providing the same file)
>>>> - config file protection
>>>> - versioning and the ability to deploy your changes in an
>>>> updateable way
>>>>
>>>> This patch introduces a major new feature to Isar.
>>>>
>>>> This class introduces a new class for building debian packages on
>>>> the fly. They can basically contain anything from random sources,
>>>> where building happens outside of Isar. It also allows to create
>>>> meta-packages that contain nothing but pull in dependencies, once
>>>> all our packets come in via multistrap that will come in handy.
>>>> For rootfs configuration you would use post- and pre- scripts just
>>>> like regular debian packages do.
>>>>
>>>> Signed-off-by: Henning Schild <henning.schild@siemens.com>
>>>> ---
>>>> meta/classes/dpkg-custom.bbclass | 57
>>>> ++++++++++++++++++++++++++++++++++++++++
>>>> 1 file changed, 57 insertions(+)
>>>> create mode 100644 meta/classes/dpkg-custom.bbclass
>>>
>>> Also not a big fan of this name. 'custom' is a bit too unspecific
>>> for what it does. I get that your idea that those packages are
>>> *custom* made, but at the same time, so are all the packages that
>>> are directly created within isar.
>>>
>>> I liked the old 'dpkg-bin' name more, but maybe even this is a bit
>>> to unspecific. How about 'dpkg-plain'? That describes better that
>>> those packages are very simple, created impromptu without much to
>>> it, IMO.
>>
>> How about dpkg-wrap, because this wraps existing stuff as-is into
>> debian package?
>
> I explained the new names in the cover letter. dpkg-bin can not be used
> because that suggests that we do not compile in this class. As of today
> we do not but i can imagine a future where we do, just without the
> debian/ directory.
> So now dpkg-src also does not match anymore, i think.
>
> Any suggestions for both names taking the custom-compile into account?
I would still use 'dpkg-plain' for 'dpkg-custom' and 'dpkg-src' or
'dpkg-src-dir' for 'dpkg-debian'.
Customization of the current implementation of the 'dpkg-custom' class
is a bit unusual, since it adds tasks before the do_install step. Maybe
it needs to be refactored a bit so that packaging is done after the
'do_install' task and then it packages just everything that is in '${D}'
while using the preinst and the other hooks from the WORKDIR. Maybe have
an additional directory for them, just so that its a bit cleaner.
As I pointed out in message
<60d3f1ca-67a1-9c43-07f6-d2d89e4c2e51@siemens.com>, we should fix the
general task pipeline for this. I would propose something like this:
fetch, unpack, configure, compile, install, package, populate_repo
So 'dpkg-custom'/'dpkg-plain' should only contain the 'do_package' and
their subordinate tasks.
Why would the 'dpkg-debian' class need a custom compile step? Since the
/debian directory already contains instructions to build the software.
If something needs to be done before or after compilation there, then
just modifiy the configure or install task.
Cheers,
Claudius
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-54 Fax: (+49)-8142-66989-80 Email: ch@denx.de
next prev parent reply other threads:[~2017-08-31 12:14 UTC|newest]
Thread overview: 51+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-30 19:03 [PATCH 0/6] v3 of getting the custom debian package in Henning Schild
2017-08-30 19:03 ` [PATCH 1/6] meta/dpkg: Make 'do_unpack' more generic, prepare for pulling out Henning Schild
2017-09-04 15:11 ` Alexander Smirnov
2017-09-04 16:47 ` Jan Kiszka
2017-09-05 7:05 ` Claudius Heine
2017-09-05 7:25 ` Alexander Smirnov
2017-09-05 7:37 ` Alexander Smirnov
2017-09-05 7:56 ` Claudius Heine
2017-09-08 8:30 ` Henning Schild
2017-09-08 8:44 ` Claudius Heine
2017-09-08 9:03 ` Henning Schild
2017-08-30 19:03 ` [PATCH 2/6] meta: Move 'do_fetch' and 'do_unpack' to base-class Henning Schild
2017-09-04 15:14 ` Alexander Smirnov
2017-09-04 16:03 ` Jan Kiszka
2017-09-04 16:10 ` Alexander Smirnov
2017-09-04 16:11 ` Jan Kiszka
2017-09-04 16:39 ` Alexander Smirnov
2017-09-04 16:45 ` Jan Kiszka
2017-08-30 19:03 ` [PATCH 3/6] meta/dpkg: rename to dpkg-debian and add comment Henning Schild
2017-08-31 8:23 ` Claudius Heine
2017-09-04 15:17 ` Alexander Smirnov
2017-09-04 16:05 ` Jan Kiszka
2017-08-30 19:03 ` [PATCH 4/6] meta/dpkg-debian: Make 'do_install' more generic, prepare for pulling out Henning Schild
2017-08-30 19:09 ` Henning Schild
2017-09-08 8:35 ` Henning Schild
2017-08-30 19:03 ` [PATCH 5/6] meta/dpkg: add dpkg-custom class Henning Schild
2017-08-31 8:38 ` Claudius Heine
2017-08-31 8:42 ` Jan Kiszka
2017-08-31 9:10 ` Claudius Heine
2017-08-31 9:32 ` Henning Schild
2017-08-31 12:14 ` Claudius Heine [this message]
2017-08-31 13:39 ` Henning Schild
2017-09-11 8:39 ` Alexander Smirnov
2017-08-31 8:53 ` Claudius Heine
2017-08-31 10:21 ` Henning Schild
2017-09-04 15:36 ` Alexander Smirnov
2017-09-04 16:08 ` Jan Kiszka
2017-09-04 16:30 ` Alexander Smirnov
2017-09-04 16:53 ` Jan Kiszka
2017-09-08 8:20 ` Henning Schild
2017-09-08 8:15 ` Henning Schild
2017-09-08 8:31 ` Alexander Smirnov
2017-09-08 8:42 ` Henning Schild
2017-09-08 8:50 ` Alexander Smirnov
2017-09-11 8:13 ` Claudius Heine
2017-09-11 8:19 ` Henning Schild
2017-09-11 9:12 ` Claudius Heine
2017-09-11 8:42 ` Claudius Heine
2017-08-30 19:03 ` [PATCH 6/6] recipes-app/example-custom: add example on how to use dpkg-custom Henning Schild
2017-09-04 15:40 ` Alexander Smirnov
2017-09-06 7:36 ` Henning Schild
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=7c037e42-d6d5-db90-74e8-0c9b2ee94d2d@siemens.com \
--to=claudius.heine.ext@siemens.com \
--cc=alex.bluesman.smirnov@gmail.com \
--cc=ch@denx.de \
--cc=christian.storm@siemens.com \
--cc=henning.schild@siemens.com \
--cc=isar-users@googlegroups.com \
--cc=jan.kiszka@siemens.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