-
Notifications
You must be signed in to change notification settings - Fork 40
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9e9cca9
commit 592304d
Showing
3 changed files
with
60 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
#!/bin/sh | ||
|
||
# https://github.com/canonical/steam-snap/issues/19#issuecomment-1171984524 | ||
# https://gist.github.com/jhenstridge/425c769949d034033f3d5d90acc2f181 | ||
|
||
set -e | ||
|
||
mkdir -p $SNAP_DATA/etc | ||
|
||
snap_ld_so_conf=$SNAP_DATA/etc/snap-ld.so.conf | ||
snap_ld_so_cache=$SNAP_DATA/etc/snap-ld.so.cache | ||
real_ld_so_cache=$SNAP_DATA/etc/ld.so.cache | ||
|
||
RUNTIME=$SNAP/gnome-platform | ||
|
||
cat > "$snap_ld_so_conf" <<EOF | ||
/var/lib/snapd/lib/gl | ||
/var/lib/snapd/lib/gl32 | ||
$SNAP/lib/x86_64-linux-gnu | ||
$SNAP/lib/i386-linux-gnu | ||
$SNAP/lib | ||
$SNAP/usr/lib/x86_64-linux-gnu | ||
$SNAP/usr/lib/x86_64-linux-gnu/pulseaudio | ||
$SNAP/usr/lib/i386-linux-gnu | ||
$SNAP/usr/lib | ||
$SNAP/usr/lib/x86_64-linux-gnu/dri | ||
$SNAP/usr/lib/i386-linux-gnu/dri | ||
$SNAP/usr/lib/i386-linux-gnu/pulseaudio | ||
$SNAP/graphics/lib | ||
$SNAP/graphics/usr/lib | ||
$SNAP/graphics/usr/lib/i386-linux-gnu | ||
$SNAP/graphics/usr/lib/x86_64-linux-gnu | ||
$SNAP/graphics/usr/lib/i386-linux-gnu/dri | ||
$SNAP/graphics/usr/lib/x86_64-linux-gnu/dri | ||
/lib/x86_64-linux-gnu | ||
/lib/i386-linux-gnu | ||
/usr/lib/x86_64-linux-gnu | ||
/usr/lib/i386-linux-gnu | ||
EOF | ||
|
||
ldconfig -X -f $snap_ld_so_conf -C $snap_ld_so_cache | ||
|
||
# We need to update the real ld.so.cache in place rather than moving | ||
# over the top of it, since it is the source of a bind mount. | ||
cat $snap_ld_so_cache > $real_ld_so_cache |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters