libnss-resolve not automatically installed
Hi,
I'm currently on branch dunfell and using systemd-resolved.
I want to have glibc's NSS resolver functions using systemd-resolved. I've noticed that the plugin libnss-resolve.so.2 was not in my image by default.
In systemd_244.5.bb, nss-resolve is in PACKAGECONFIG by default. libnss-resolve is build and packaged, but not installed by default.
To install the missing library libnss-resolve.so.2, I've added
IMAGE_INSTALL_append = " libnss-resolve"
to my image recipe, but I wonder, if this is the right place or necessary at all.
My assumption was that having nss-resolve in PACKAGECONFIG will also install the related library, which is obviously not the case.
Furthermore, I had to write an append-file for base-files, such that /etc/nsswitch.conf contains the following line
hosts: resolve [!UNAVAIL=return] files dns myhostname
Possibly, I've overlooked something essential.
I'd be very happy, if someone can shed some light on this issue.
Best regards,
Carsten Stelling
Quoted 11 lines · VIVAVIS AG via lists.yoctoproject.org
Hi,
I'm currently on branch dunfell and using systemd-resolved.
I want to have glibc's NSS resolver functions using systemd-resolved. I've noticed that the plugin libnss-resolve.so.2 was not in my image by default.
In systemd_244.5.bb, nss-resolve is in PACKAGECONFIG by default. libnss-resolve is build and packaged, but not installed by default.
Quoted 8 lines
To install the missing library libnss-resolve.so.2, I've added
IMAGE_INSTALL_append= " libnss-resolve"
to my image recipe, but I wonder, if this is the right place or necessary at all.My assumption was that having nss-resolve in PACKAGECONFIG will also install the related library, which is obviously not the case.
Packageconfigs are about what you would like to build it’s still another step what you would like to bundle in your image which is what IMAGE_INSTALL does. At times this is already done because whatever the packagrconfig is enabling is already part of a output package that’s in your IMAGE_INSTALL dependencies and gets pulled in indirectly but that’s not the case here. Therefore you have to do it in both places
Quoted 23 lines
Furthermore, I had to write an append-file for base-files, such that
/etc/nsswitch.confcontains the following line
hosts: resolve [!UNAVAIL=return] files dns myhostnamePossibly, I've overlooked something essential.
I'd be very happy, if someone can shed some light on this issue.Best regards,
Carsten Stelling
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
You automatically follow any topics you start or reply to. View/Reply Online (#57772):
https://lists.yoctoproject.org/g/yocto/message/57772
Mute This Topic: https://lists.yoctoproject.org/mt/92797309/1997914
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [ [email protected]]
-=-=-=-=-=-=-=-=-=-=-=-
Hi Khem,
Quoted 8 lines
Von: Khem Raj <[email protected]>
Gesendet: Donnerstag, 4. August 2022 13:20Quoted 6 lines
To install the missing library libnss-resolve.so.2, I've added
IMAGE_INSTALL_append= " libnss-resolve"
to my image recipe, but I wonder, if this is the right place or necessary at all.
Quoted 10 lines
Quoted 2 lines
My assumption was that having nss-resolve in PACKAGECONFIG will also install the related library, which is obviously not the case.
Packageconfigs are about what you would like to build it’s still another step what you would like to bundle in your image which is what
IMAGE_INSTALLdoes. At times this is already done because whatever the packagrconfig is enabling is already part of a output package that’s in yourIMAGE_INSTALLdependencies and gets pulled in indirectly but that’s not the case here. Therefore you have to do it in both placesQuoted 5 lines
Furthermore, I had to write an append-file for base-files, such that
/etc/nsswitch.confcontains the following line
hosts: resolve [!UNAVAIL=return] files dns myhostname
Ok, there's nothing to worry about.
Adding libnss-resolve to IMAGE_INSTALL and overwriting nsswitch.conf in the append-file ist he correct procedure here.
Thanks for clarification.
Carsten
Quoted 22 lines · embedded (VIVAVIS AG)
Hi Khem,
Quoted 6 lines
Von: Khem Raj <[email protected]>
Gesendet: Donnerstag, 4. August 2022 13:20Quoted 4 lines
To install the missing library libnss-resolve.so.2, I've added
IMAGE_INSTALL_append= " libnss-resolve"
to my image recipe, but I wonder, if this is the right place ornecessary
Quoted 6 lines
Quoted 4 lines
at all.
My assumption was that having nss-resolve in PACKAGECONFIG will also install the related library, which is obviously not the case.
Packageconfigs are about what you would like to build it’s still another
step what you would like to bundle in your image which is what
IMAGE_INSTALLdoes. At times this is already done because whatever the packagrconfig is enabling is already part of a output package that’s in yourIMAGE_INSTALLdependencies and gets pulled in indirectly but that’s not the case here. Therefore you have to do it in both placesQuoted 2 lines
Quoted 2 lines
Quoted 9 lines
Quoted 4 lines
Quoted 4 lines
Furthermore, I had to write an append-file for base-files, such that
/etc/nsswitch.confcontains the following line
hosts: resolve [!UNAVAIL=return] files dns myhostnameOk, there's nothing to worry about.
Adding libnss-resolve toIMAGE_INSTALLand overwriting nsswitch.conf in the append-file ist he correct procedure here.
Yes
Quoted 4 lines
Thanks for clarification.
Carsten