---- On Thu, 22 Jul 2021 21:00:15 +0200 Andre McCurdy <armccu...@gmail.com> 
wrote ----
 > On Thu, Jul 22, 2021 at 2:48 AM Damian Wrobel
 > <dwro...@ertelnet.rybnik.pl> wrote:
 > >
 > > Removes the /var/cache/ldconfig auxiliary cache directory from
 > > the rootfs when:
 > >  - read-only-rootfs is in DISTRO_FEATURES,
 > >  - ldconfig is not in DISTRO_FEATURES.
 > >
 > > In both cases the /var/cache/ldconfig/aux-cache is useless.
 > 
 > Should there be a test for package management being supported in the
 > image too? A read-only rootfs is one case where it's not possible to
 > install ldconfig support at run time but a writeable rootfs without
 > package management support would seem to be another?

It seems to be perfectly fine to use the ldconfig without having any package 
management system.

--
Regards,
Damian

 > 
 > > Signed-off-by: Damian Wrobel <dwro...@ertelnet.rybnik.pl>
 > > ---
 > >  meta/lib/oe/rootfs.py | 9 +++++++++
 > >  1 file changed, 9 insertions(+)
 > >
 > > diff --git a/meta/lib/oe/rootfs.py b/meta/lib/oe/rootfs.py
 > > index ad9fd77c8b..80673fab3f 100644
 > > --- a/meta/lib/oe/rootfs.py
 > > +++ b/meta/lib/oe/rootfs.py
 > > @@ -302,6 +302,15 @@ class Rootfs(object, metaclass=ABCMeta):
 > >              self._exec_shell_cmd(['ldconfig', '-r', self.image_rootfs, 
 > > '-c',
 > >                                    'new', '-v', '-X'])
 > >
 > > +        image_rorfs = bb.utils.contains("IMAGE_FEATURES", 
 > > "read-only-rootfs",
 > > +                                        True, False, self.d)
 > > +        ldconfig_in_features = bb.utils.contains("IMAGE_FEATURES", 
 > > "ldconfig",
 > > +                                                 True, False, self.d)
 > > +        if image_rorfs or not ldconfig_in_features:
 > > +            ldconfig_cache_dir = os.path.join(self.image_rootfs, 
 > > "var/cache/ldconfig")
 > > +            bb.note("Removing ldconfig auxiliary cache...")
 > > +            shutil.rmtree(ldconfig_cache_dir)
 > > +
 > >      def _check_for_kernel_modules(self, modules_dir):
 > >          for root, dirs, files in os.walk(modules_dir, topdown=True):
 > >              for name in files:
 > > --
 > > 2.31.1
 > >
 > >
 > > 
 > >
 > 
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#154107): 
https://lists.openembedded.org/g/openembedded-core/message/154107
Mute This Topic: https://lists.openembedded.org/mt/84375612/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