All of lore.kernel.org
 help / color / mirror / Atom feed
* RDEPENDS problem
@ 2020-09-21 21:46 Greg Wilson-Lindberg
  2020-09-22  4:54 ` [yocto] " Maciej Pijanowski
  2020-09-22  8:20 ` Quentin Schulz
  0 siblings, 2 replies; 4+ messages in thread
From: Greg Wilson-Lindberg @ 2020-09-21 21:46 UTC (permalink / raw)
  To: Yocto list discussion


 I have a custom recipe that copies a .so, that libMotors.so calls functions in another libcanfestival.so.

When I first added in the copy of the .so
I didn't have an RDEPENDS and Yocto printed out an warning listing the package that it wanted. I added an RDEPENDS_${PN} 
with all of the packages listed, but I'm still getting an error for the first libMotors.so:

ERROR: userconfig-1.0-r0 do_package_qa: QA Issue: /home/sakura/lib/libMotors.so.1.0.0 contained in package userconfig requires libcanfestival.so, but no providers found in RDEPENDS_userconfig? [file-rdeps]

In userdepends I added:

RDEPENDS_${PN} += "canfestival libelf libgcrypt pcsc-lite-lib qtbase qtdeclarative qtserialport zint"

Package canfestival_3-asc in has:

FILES_${PN} = "/usr/lib/libcanfestival.so /usr/lib/libcanfestival_unix.so /usr/lib/libcanfestival_can_socket.so"

which seems to me like it should satisfy the requirements of the RDEPENDS, but it is not. bitbake initially gave me a warning 
that listed canfestival as needing to be added to an RDEPENDS for userconfig. But now it is saying that it can't figure out
what package supplies the libcanfestival.so file.

Can someone help me to understand what is going on? How do I explicitly say that a package supplies a given file?

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [yocto] RDEPENDS problem
  2020-09-21 21:46 RDEPENDS problem Greg Wilson-Lindberg
@ 2020-09-22  4:54 ` Maciej Pijanowski
  2020-09-22  8:20 ` Quentin Schulz
  1 sibling, 0 replies; 4+ messages in thread
From: Maciej Pijanowski @ 2020-09-22  4:54 UTC (permalink / raw)
  To: yocto

[-- Attachment #1: Type: text/plain, Size: 1602 bytes --]


On 21.09.2020 23:46, Greg Wilson-Lindberg wrote:
>   I have a custom recipe that copies a .so, that libMotors.so calls functions in another libcanfestival.so.
>
> When I first added in the copy of the .so
> I didn't have an RDEPENDS and Yocto printed out an warning listing the package that it wanted. I added an RDEPENDS_${PN}
> with all of the packages listed, but I'm still getting an error for the first libMotors.so:
>
> ERROR: userconfig-1.0-r0 do_package_qa: QA Issue: /home/sakura/lib/libMotors.so.1.0.0 contained in package userconfig requires libcanfestival.so, but no providers found in RDEPENDS_userconfig? [file-rdeps]
>
> In userdepends I added:
>
> RDEPENDS_${PN} += "canfestival libelf libgcrypt pcsc-lite-lib qtbase qtdeclarative qtserialport zint"
>
> Package canfestival_3-asc in has:
>
> FILES_${PN} = "/usr/lib/libcanfestival.so /usr/lib/libcanfestival_unix.so /usr/lib/libcanfestival_can_socket.so"
>
> which seems to me like it should satisfy the requirements of the RDEPENDS, but it is not. bitbake initially gave me a warning
> that listed canfestival as needing to be added to an RDEPENDS for userconfig. But now it is saying that it can't figure out
> what package supplies the libcanfestival.so file.
>
> Can someone help me to understand what is going on? How do I explicitly say that a package supplies a given file?
You could try with PROVIDES: 
https://www.yoctoproject.org/docs/latest/ref-manual/ref-manual.html#var-PROVIDES
>
> 
>
-- 
Maciej Pijanowski
Embedded Systems Engineer
GPG: 9963C36AAC3B2B46
https://3mdeb.com | @3mdeb_com


[-- Attachment #2: Type: text/html, Size: 2413 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [yocto] RDEPENDS problem
  2020-09-21 21:46 RDEPENDS problem Greg Wilson-Lindberg
  2020-09-22  4:54 ` [yocto] " Maciej Pijanowski
@ 2020-09-22  8:20 ` Quentin Schulz
  2020-09-22 21:11   ` Greg Wilson-Lindberg
  1 sibling, 1 reply; 4+ messages in thread
From: Quentin Schulz @ 2020-09-22  8:20 UTC (permalink / raw)
  To: Greg Wilson-Lindberg; +Cc: Yocto list discussion

Hi Greg,

On Mon, Sep 21, 2020 at 09:46:51PM +0000, Greg Wilson-Lindberg wrote:
> 
>  I have a custom recipe that copies a .so, that libMotors.so calls functions in another libcanfestival.so.
> 
> When I first added in the copy of the .so
> I didn't have an RDEPENDS and Yocto printed out an warning listing the package that it wanted. I added an RDEPENDS_${PN} 
> with all of the packages listed, but I'm still getting an error for the first libMotors.so:
> 
> ERROR: userconfig-1.0-r0 do_package_qa: QA Issue: /home/sakura/lib/libMotors.so.1.0.0 contained in package userconfig requires libcanfestival.so, but no providers found in RDEPENDS_userconfig? [file-rdeps]
> 
> In userdepends I added:
> 
> RDEPENDS_${PN} += "canfestival libelf libgcrypt pcsc-lite-lib qtbase qtdeclarative qtserialport zint"
> 
> Package canfestival_3-asc in has:
> 
> FILES_${PN} = "/usr/lib/libcanfestival.so /usr/lib/libcanfestival_unix.so /usr/lib/libcanfestival_can_socket.so"
> 

.so files are installed in the -dev package even with the line above.

Please have a look here: https://wiki.yoctoproject.org/wiki/TipsAndTricks/Packaging_Prebuilt_Libraries#Non-versioned_Libraries
if there is really no way for you to avoid having a non-versioned library.

You can check if .so files are part of a package by using
`oe-pkgdata-util find-path /usr/lib/libcanfestival.so`

Cheers,
Quentin

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [yocto] RDEPENDS problem
  2020-09-22  8:20 ` Quentin Schulz
@ 2020-09-22 21:11   ` Greg Wilson-Lindberg
  0 siblings, 0 replies; 4+ messages in thread
From: Greg Wilson-Lindberg @ 2020-09-22 21:11 UTC (permalink / raw)
  To: Quentin Schulz; +Cc: Yocto list discussion

Hi Quentin,
It turns out that there was a problem in the build of the libcanfestival.so library that was adding in a reference to ../bin/....
This caused the failure that I asked about initially.

Thank you for your suggestions that then led me to figuring out the problem with the canfestival build.

Greg

> -----Original Message-----
> From: Quentin Schulz <quentin.schulz@streamunlimited.com>
> Sent: Tuesday, September 22, 2020 1:20 AM
> To: Greg Wilson-Lindberg <GWilson@sakuraus.com>
> Cc: Yocto list discussion <yocto@yoctoproject.org>
> Subject: Re: [yocto] RDEPENDS problem
> 
> Hi Greg,
> 
> On Mon, Sep 21, 2020 at 09:46:51PM +0000, Greg Wilson-Lindberg wrote:
> >
> >  I have a custom recipe that copies a .so, that libMotors.so calls functions in
> another libcanfestival.so.
> >
> > When I first added in the copy of the .so I didn't have an RDEPENDS
> > and Yocto printed out an warning listing the package that it wanted. I
> > added an RDEPENDS_${PN} with all of the packages listed, but I'm still
> getting an error for the first libMotors.so:
> >
> > ERROR: userconfig-1.0-r0 do_package_qa: QA Issue:
> > /home/sakura/lib/libMotors.so.1.0.0 contained in package userconfig
> > requires libcanfestival.so, but no providers found in
> > RDEPENDS_userconfig? [file-rdeps]
> >
> > In userdepends I added:
> >
> > RDEPENDS_${PN} += "canfestival libelf libgcrypt pcsc-lite-lib qtbase
> qtdeclarative qtserialport zint"
> >
> > Package canfestival_3-asc in has:
> >
> > FILES_${PN} = "/usr/lib/libcanfestival.so /usr/lib/libcanfestival_unix.so
> /usr/lib/libcanfestival_can_socket.so"
> >
> 
> .so files are installed in the -dev package even with the line above.
> 
> Please have a look here:
> https://wiki.yoctoproject.org/wiki/TipsAndTricks/Packaging_Prebuilt_Librarie
> s#Non-versioned_Libraries
> if there is really no way for you to avoid having a non-versioned library.

First, the canfestival package that I have doesn't create versioned libraries, only the non-versioned .so's.

I changed the canfestival .bb to:

SOLIBS = ".so.*"
SOLIBSDEV = ".so"

FILES_${PN} = " ${libdir}/lib*${SOLIBSDEV}"
FILES_SOLIBSDEV ?= " ${libdir}/lib*${SOLIBSDEV}"
FILES_${PN}-dev = " /usr/include/canfestival/*.h  ${FILES_SOLIBSDEV}"

And I get the following error:

ERROR: canfestival-3-asc-r01 do_package_qa: QA Issue: -dev package contains non-symlink .so: canfestival-dev path '/work/cortexa7t2hf-neon-vfpv4-poky-linux-gnueabi/canfestival/3-asc-r01/packages-split/canfestival-dev/usr/lib/libcanfestival_unix.so'
-dev package contains non-symlink .so: canfestival-dev path '/work/cortexa7t2hf-neon-vfpv4-poky-linux-gnueabi/canfestival/3-asc-r01/packages-split/canfestival-dev/usr/lib/libcanfestival.so'
-dev package contains non-symlink .so: canfestival-dev path '/work/cortexa7t2hf-neon-vfpv4-poky-linux-gnueabi/canfestival/3-asc-r01/packages-split/canfestival-dev/usr/lib/libcanfestival_can_socket.so' [dev-elf]
ERROR: canfestival-3-asc-r01 do_package_qa: QA run found fatal errors. Please consider fixing them.

I removed the ${FILES_SOLIBSDEV} from the FILES_${PN}-dev  and then I get:
WARNING: canfestival-3-asc-r01 do_package: canfestival-dev-3-asc was registered as shlib provider for ../bin/libcanfestival.so, changing it to canfestival-3-asc because it was built later
WARNING: canfestival-3-asc-r01 do_package: canfestival-dev-3-asc was registered as shlib provider for libcanfestival_can_socket.so, changing it to canfestival-3-asc because it was built later
WARNING: canfestival-3-asc-r01 do_package: canfestival-dev-3-asc was registered as shlib provider for libcanfestival_unix.so, changing it to canfestival-3-asc because it was built later
ERROR: userconfig-1.0-r0 do_package_qa: QA Issue: /home/sakura/lib/libMotors.so.1.0.0 contained in package userconfig requires libcanfestival.so, but no providers found in RDEPENDS_userconfig? [file-rdeps]
ERROR: userconfig-1.0-r0 do_package_qa: QA run found fatal errors. Please consider fixing them.

It looks like the first warning is the key to the ERROR of not finding libcanfestival.so, but not getting errors for the other 2 libraries.

I looked in the build for canfestival and nowhere is there a bin/libcanfestival.so. Any ideas of how this could be created or referenced?



> 
> You can check if .so files are part of a package by using `oe-pkgdata-util find-
> path /usr/lib/libcanfestival.so`
> 
> Cheers,
> Quentin

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-09-22 21:11 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-21 21:46 RDEPENDS problem Greg Wilson-Lindberg
2020-09-22  4:54 ` [yocto] " Maciej Pijanowski
2020-09-22  8:20 ` Quentin Schulz
2020-09-22 21:11   ` Greg Wilson-Lindberg

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.