On Tue, May 6, 2025 at 11:26 AM Pavol Sloboda <pslob...@redhat.com> wrote:
>
> Hi,
>
> I am currently working on rebasing a package that creates a shared library 
> and I want to place it in %{_libdir}/x/y/z. I am using the 
> /etc/ld.so.conf.d/%[name}.conf file to do so. My question is:
> Do I have to call ldconfig in %post and %postun?
> Because the wiki seems to be conflicted about this.
> On one hand it says: "It is not necessary to call ldconfig when installing 
> shared libraries."
> Here: 
> https://docs.fedoraproject.org/en-US/packaging-guidelines/#_shared_libraries
> But on the other hand it says ldconfing MUST be called: "Packages which place 
> linker configuration files in /etc/ld.so.conf.d MUST call ldconfig in %post 
> and %postun (on all Fedora releases) even if they install no actual 
> libraries."
> Here: 
> https://docs.fedoraproject.org/en-US/packaging-guidelines/Scriptlets/#_snippets

The documentation is correct (if a bit confusing):

- In general, it is not necessary to call ldconfig after installing
shared libraries (because that is handled by a file trigger in RPM).
- However, that file trigger only handles the case where libraries are
installed in %_libdir, so if you install somewhere else, you still
need to call ldconfig.

Fabio
-- 
_______________________________________________
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue

Reply via email to