[GH-ISSUE #3118] Can't load libstdc++.so.6 due to private-etc (Gentoo) #1955

Closed
opened 2026-05-05 08:37:14 -06:00 by gitea-mirror · 5 comments
Owner

Originally created by @reagentoo on GitHub (Jan 3, 2020).
Original GitHub issue: https://github.com/netblue30/firejail/issues/3118

ERROR: ffmpeg: error while loading shared libraries: libstdc++.so.6: cannot open shared object file: No such file or directory

Affected applications: celluloid, evince, youtube-dl

My temporary fix is to remove next lines:
celluloid.profile:

private-etc alternatives,ca-certificates,crypto-policies,dconf,drirc,fonts,gtk-3.0,hosts,libva.conf,localtime,machine-id,pkcs11,pki,resolv.conf,selinux,ssl,xdg

evince.profile:

private-etc alternatives,fonts,group,machine-id,passwd
private-lib evince,gconv,gdk-pixbuf-2.*,gio,gvfs/libgvfscommon.so,libdjvulibre.so.*,libgconf-2.so.*,libgraphite2.so.*,libpoppler-glib.so.*,librsvg-2.so.*,libspectre.so.*

youtube-dl.profile:

private-etc alternatives,ca-certificates,crypto-policies,hostname,hosts,mime.types,pki,resolv.conf,ssl,youtube-dl.conf
Originally created by @reagentoo on GitHub (Jan 3, 2020). Original GitHub issue: https://github.com/netblue30/firejail/issues/3118 `ERROR: ffmpeg: error while loading shared libraries: libstdc++.so.6: cannot open shared object file: No such file or directory` Affected applications: celluloid, evince, youtube-dl My temporary fix is to remove next lines: celluloid.profile: ``` private-etc alternatives,ca-certificates,crypto-policies,dconf,drirc,fonts,gtk-3.0,hosts,libva.conf,localtime,machine-id,pkcs11,pki,resolv.conf,selinux,ssl,xdg ``` evince.profile: ``` private-etc alternatives,fonts,group,machine-id,passwd private-lib evince,gconv,gdk-pixbuf-2.*,gio,gvfs/libgvfscommon.so,libdjvulibre.so.*,libgconf-2.so.*,libgraphite2.so.*,libpoppler-glib.so.*,librsvg-2.so.*,libspectre.so.* ``` youtube-dl.profile: ``` private-etc alternatives,ca-certificates,crypto-policies,hostname,hosts,mime.types,pki,resolv.conf,ssl,youtube-dl.conf ```
Author
Owner

@reagentoo commented on GitHub (Jan 3, 2020):

Adding ld.so.cache to private-etc solve this. But except for "evince":

Warning fldd: cannot find libstdc++.so.6, skipping...
Warning fldd: cannot find libgcc_s.so.1, skipping...

Similar issue: https://github.com/netblue30/firejail/issues/1320

<!-- gh-comment-id:570732587 --> @reagentoo commented on GitHub (Jan 3, 2020): Adding `ld.so.cache` to `private-etc` solve this. But except for "evince": ``` Warning fldd: cannot find libstdc++.so.6, skipping... Warning fldd: cannot find libgcc_s.so.1, skipping... ``` Similar issue: https://github.com/netblue30/firejail/issues/1320
Author
Owner

@ghost commented on GitHub (Jan 4, 2020):

Adding ld.so.cache to private-etc solve this. But except for "evince":
Warning fldd: cannot find libstdc++.so.6, skipping...
Warning fldd: cannot find libgcc_s.so.1, skipping...

@reagentoo Hi, thanks for reporting. The evince profile also has private-lib. Can you try if that works when adding libgcc_s.so.*,libstdc++.so.* to it?

<!-- gh-comment-id:570744834 --> @ghost commented on GitHub (Jan 4, 2020): > Adding `ld.so.cache` to private-etc solve this. But except for "evince": Warning fldd: cannot find libstdc++.so.6, skipping... Warning fldd: cannot find libgcc_s.so.1, skipping... @reagentoo Hi, thanks for reporting. The evince profile also has `private-lib`. Can you try if that works when adding `libgcc_s.so.*,libstdc++.so.*` to it?
Author
Owner

@reagentoo commented on GitHub (Jan 4, 2020):

@glitsj16 Hi.
Adding libgcc_s.so.*,libstdc++.so.* to private-lib does not helps.
I've tried to add ,gcc instead of them (This dir contains this libs). So I can see pdf images in the application after that, but I still see those warnings that I showed above.

<!-- gh-comment-id:570745401 --> @reagentoo commented on GitHub (Jan 4, 2020): @glitsj16 Hi. Adding `libgcc_s.so.*,libstdc++.so.*` to `private-lib` does not helps. I've tried to add `,gcc` instead of them (This dir contains this libs). So I can see pdf images in the application after that, but I still see those warnings that I showed above.
Author
Owner

@ghost commented on GitHub (Jan 4, 2020):

@reagentoo Maybe evince needs more than ld.so.cache in private-etc on gentoo. Try adding ld.so.* to its private-etc too (besides keeping either 'libgcc_s.so.,libstdc++.so.' or 'gcc' in private-lib). That should cover ld.so.cache, ld.so.conf, ld.so.conf.d and ld.so.preload. Also, it's not uncommon to see warnings. As long as all functionality is working as expected those can safely be ignored.

<!-- gh-comment-id:570746122 --> @ghost commented on GitHub (Jan 4, 2020): @reagentoo Maybe evince needs more than ld.so.cache in private-etc on gentoo. Try adding `ld.so.*` to its _private-etc_ too (besides keeping either 'libgcc_s.so.*,libstdc++.so.*' or 'gcc' in _private-lib_). That should cover ld.so.cache, ld.so.conf, ld.so.conf.d and ld.so.preload. Also, it's not uncommon to see warnings. As long as all functionality is working as expected those can safely be ignored.
Author
Owner

@ghost commented on GitHub (Jan 4, 2020):

I've gone ahead and merged https://github.com/netblue30/firejail/pull/3120. If you still have functional issues with evince on gentoo, please feel free to reopen. Thanks again for your cooperiation.

<!-- gh-comment-id:570749630 --> @ghost commented on GitHub (Jan 4, 2020): I've gone ahead and merged https://github.com/netblue30/firejail/pull/3120. If you still have functional issues with evince on gentoo, please feel free to reopen. Thanks again for your cooperiation.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/firejail#1955
No description provided.