You need to make two slightly different recipes (put common bits into an .inc), and then install one or the other to the respective images.
Alex On Tue, 10 Sept 2024 at 13:16, Gennady Abramov via lists.yoctoproject.org <agv100=gmail....@lists.yoctoproject.org> wrote: > > Dear community, > > I'm trying to build A+B+Data distro + update distros using RAUC and populate > Data partition with default configuration files. > > Thus, I want a particular recipe, if "full" image build, install particular > default configuration files, and if "update" image build, not to do that, > maintain only symlinks to /data partition. > I included if ${IMAGE_BASENAME} in application do_install:append(), but this > doesn't work! > > > > do_install:append () { > # If building full image, install default config to /data/ partition > if [ ${IMAGE_BASENAME} = "image-full" ]; then > install -Dm 0755 ${WORKDIR}/app.conf ${D}/data/etc/app/app.conf > fi > #in any case, replace default config from distribution to link to /data/etc/ > rm ${D}/etc/app/app.conf > ln -s /data/etc/app/app.conf ${D}/etc/app/app.conf > } > > I included > export IMAGE_BASENAME = "core-image-full-cmdline" in "image-full.bb", but > this still doesn't help. > > By replacing "if [ ${IMAGE_BASENAME} " with predefined variable, I found that > "if " works well itself, so probably using IMAGE_BASENAME is not correct. > > So, probably I should use other variable or initialize it somehow other way. > I think that is typical scenario, and I missing something obvious, but still > cannot find it. > Any advice? > > > > >
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#63812): https://lists.yoctoproject.org/g/yocto/message/63812 Mute This Topic: https://lists.yoctoproject.org/mt/108372539/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-