Adds -X option to ldconfig to not create symlinks
as part of the ldconfig cache creation process.

It is much better to keep all needed symlinks as part of
of the package then let ldconfig do the job.

In the case symlink was created by ldconfig and later on the
package got removed the dangling link will remain on the
filesystem. Not to mention that such a symlink is orphaned
(e.g. rpm -qf <file-path> will not show the package the symlink
is part of).

It also align the behaviour with libc-musl where the ldconfig
is not invoked by default.

Signed-off-by: Damian Wrobel <dwro...@ertelnet.rybnik.pl>
---
 meta/lib/oe/rootfs.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/meta/lib/oe/rootfs.py b/meta/lib/oe/rootfs.py
index a0ac33ada6..0e05f1f75e 100644
--- a/meta/lib/oe/rootfs.py
+++ b/meta/lib/oe/rootfs.py
@@ -297,9 +297,9 @@ class Rootfs(object, metaclass=ABCMeta):

     def _run_ldconfig(self):
         if self.d.getVar('LDCONFIGDEPEND'):
-            bb.note("Executing: ldconfig -r " + self.image_rootfs + " -c new 
-v")
+            bb.note("Executing: ldconfig -r " + self.image_rootfs + " -c new 
-v -X")
             self._exec_shell_cmd(['ldconfig', '-r', self.image_rootfs, '-c',
-                                  'new', '-v'])
+                                  'new', '-v', '-X'])

     def _check_for_kernel_modules(self, modules_dir):
         for root, dirs, files in os.walk(modules_dir, topdown=True):
--
2.25.4

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#140223): 
https://lists.openembedded.org/g/openembedded-core/message/140223
Mute This Topic: https://lists.openembedded.org/mt/75254681/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