Putting image specific tweaks into local.conf is not a good practice.
Local.conf should be extremely minimal, and ideally contain only
MACHINE and DISTRO.

I would do it with two different image recipes that share almost
everything via common .inc, except ROOTFS_POSTPROCESS_COMMAND. You can
find examples for how to manipulate sshd_config using that in
meta/classes-recipe/rootfs-postcommands.bbclass

Alex

On Sat, 27 Jan 2024 at 08:27, Jörg Sommer via lists.yoctoproject.org
<joerg.sommer=navimatix...@lists.yoctoproject.org> wrote:
>
> [I posted this question on Stackoverflow: 
> https://stackoverflow.com/q/77871008/8452187]
>
> I have two images with the same distro and the same machine and each image 
> should contain the same package, but build with different settings.
>
> For example, the config file sshd_config is part of the opensshd package, but 
> I need a different set of HostKeyAlgorithms depending on the image. (Yes, I 
> could use Include, but that's not the point of this question.)
>
> How can I build two different flavours of the same package? One way would be 
> to have a different distro for each image, but this wouldn't scale. My other 
> idea is to use local.conf to change the build behaviour of the recipe and 
> control the image content (and the difference between both) with different 
> local.conf. (BTW: I'm using KAS which makes local.conf generation easy.) But 
> what's best practice?
>
>
> 
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#62309): https://lists.yoctoproject.org/g/yocto/message/62309
Mute This Topic: https://lists.yoctoproject.org/mt/103992605/21656
Group Owner: yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to