Hi Alex!

On Tue, 2023-11-28 at 14:31 +0100, Alexander Kanavin wrote:
> On Tue, 28 Nov 2023 at 14:20, A. Sverdlin
> <alexander.sverd...@siemens.com> wrote:
> > Versions starting from 20230919 require rdfind; at some point new make
> > target was introduced with commit 4124f8f928d5 ("Make rdfind optional").
> > The commit is not yet included even in 20231111, thus make even the
> > new make target optional.
> > 
> > Signed-off-by: Alexander Sverdlin <alexander.sverd...@siemens.com>
> > ---
> > This patch will not help with 20231030 update, neither 20231111 will work
> > without rdfind. install-nodedup is not yet released as of now.
> >  meta/recipes-kernel/linux-firmware/linux-firmware_20231030.bb | 3 +++
> >  do_install() {
> > +        # Versions 20231030 and 20231111 require rdfind, newer tags will 
> > have new "install-nodedup"
> > +        # make target
> > +        oe_runmake_call 'DESTDIR=${D}' 
> > 'FIRMWAREDIR=${nonarch_base_libdir}/firmware' install-nodedup || \
> >          oe_runmake 'DESTDIR=${D}' 
> > 'FIRMWAREDIR=${nonarch_base_libdir}/firmware' install
> >          cp GPL-2 LICEN[CS]E.* WHENCE ${D}${nonarch_base_libdir}/firmware/
> 
> 20231030 builds fine without rdfind, and doesn't have install-nodedup
> target in its Makefile because that was only introduced yesterday:
> 
> https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/commit/Makefile?id=4124f8f928d51a1437e2fd2636b20d540edc2836
> 
> So what is the purpose of this patch? I understand that we would need
> to use install-nodedup in lockstep with updating to newer
> linux-firmware versions, but until then it's not needed. No?

You are right, even though rdfind is used in 20231030, it doesn't report en 
error.
Error reporting was introduced with commit cf8315ded9b4
("Ensure rdfind is installed") which comes in 20231111.

So you are right, it will actually be only required before update
of linux-firmware to even newer version.

> In general, || in shell scripts should be avoided because it ignores
> the reason for the failure (ignoring some fails may be ok, ignoring
> all fails is not ok, as it will cause silent regressions).

20231111 will be problematic because rdfind will be required, but there is
no make target yet. My patch is at least falling back to "make install",
so it supports both 20231030 and versions after 20231111. It's not ignoring
the errors, falling back to "|| make install" will eventually fail the whole
build.

-- 
Alexander Sverdlin
Siemens AG
www.siemens.com
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#191369): 
https://lists.openembedded.org/g/openembedded-core/message/191369
Mute This Topic: https://lists.openembedded.org/mt/102849939/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to