SHA256
1
0
forked from pool/gswrap

Accepting request 1145407 from Printing

- Allow also abstract X11 socket

OBS-URL: https://build.opensuse.org/request/show/1145407
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/gswrap?expand=0&rev=11
This commit is contained in:
Ana Guerrero 2024-02-09 22:54:14 +00:00 committed by Git OBS Bridge
commit d70beeb42b
3 changed files with 22 additions and 2 deletions

17
gswrap
View File

@ -275,6 +275,18 @@ then
else else
opts[o++]=--unshare-all opts[o++]=--unshare-all
fi fi
for so in /tmp/.X11-unix/*
do
test -s $so && continue
# Abstract sockets only
opts[o++]=--share-net
done
if test -n "${WAYLAND_DISPLAY}"
then
opts[o++]=--ro-bind
opts[o++]="$XDG_RUNTIME_DIR/$WAYLAND_DISPLAY"
opts[o++]="/run/user/$uid/$WAYLAND_DISPLAY"
fi
if test -n "${GHOSTVIEW}" if test -n "${GHOSTVIEW}"
then then
opts[o++]=--setenv opts[o++]=--setenv
@ -330,15 +342,18 @@ set -euo pipefail
--proc /proc \ --proc /proc \
--tmpfs /run \ --tmpfs /run \
--tmpfs /tmp \ --tmpfs /tmp \
--dir /var \
--ro-bind /bin/false /bin/false \ --ro-bind /bin/false /bin/false \
--ro-bind $ghostscript /usr/bin/gs \ --ro-bind $ghostscript /usr/bin/gs \
--ro-bind /usr/share/ghostscript /usr/share/ghostscript \ --ro-bind /usr/share/ghostscript /usr/share/ghostscript \
--ro-bind /usr/share/xml/fontconfig /usr/share/xml/fontconfig \
--ro-bind /usr/share/fontconfig /usr/share/fontconfig \
--ro-bind /usr/share/fonts /usr/share/fonts \ --ro-bind /usr/share/fonts /usr/share/fonts \
--ro-bind /var/cache/fontconfig /var/cache/fontconfig \
--ro-bind /etc/fonts /etc/fonts \ --ro-bind /etc/fonts /etc/fonts \
--ro-bind "$lock" /tmp/.lock \ --ro-bind "$lock" /tmp/.lock \
--lock-file /tmp/.lock \ --lock-file /tmp/.lock \
--dir "/run/user/$uid" \ --dir "/run/user/$uid" \
--dir /var \
--symlink ../run var/run \ --symlink ../run var/run \
--symlink ../tmp var/tmp \ --symlink ../tmp var/tmp \
--dir "$home" \ --dir "$home" \

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Fri Feb 9 12:00:28 UTC 2024 - Dr. Werner Fink <werner@suse.de>
- Allow also abstract X11 socket
------------------------------------------------------------------- -------------------------------------------------------------------
Thu Sep 14 11:56:38 UTC 2023 - Dr. Werner Fink <werner@suse.de> Thu Sep 14 11:56:38 UTC 2023 - Dr. Werner Fink <werner@suse.de>

View File

@ -1,7 +1,7 @@
# #
# spec file for package gswrap # spec file for package gswrap
# #
# Copyright (c) 2023 SUSE LLC # Copyright (c) 2024 SUSE LLC
# #
# All modifications and additions to the file contributed by third parties # All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed # remain the property of their copyright owners, unless otherwise agreed