Make it work even with different hwcaps versions
OBS-URL: https://build.opensuse.org/package/show/Printing/gswrap?expand=0&rev=21
This commit is contained in:
parent
e58491dade
commit
4f83c2c1fd
14
gswrap
14
gswrap
@ -1,8 +1,9 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
#
|
#
|
||||||
# Copyright (c) 2019 SuSE GmbH Nuernberg, Germany.
|
# Copyright (c) 2019 SUSE GmbH Nuernberg, Germany.
|
||||||
# Copyright (c) 2021 SuSE SUSE Software Solutions Germany GmbH.
|
# Copyright (c) 2021 SUSE Software Solutions Germany GmbH.
|
||||||
# Copyright (c) 2019,2021 Werner Fink
|
# Copyright (c) 2023 SUSE Software Solutions Germany GmbH.
|
||||||
|
# Copyright (c) 2019,2021,2023 Werner Fink
|
||||||
#
|
#
|
||||||
# Wrapper script for ghostscript based on bwrap, the container setup
|
# Wrapper script for ghostscript based on bwrap, the container setup
|
||||||
# utility, which does use e.g. unshare(2) system call to create a
|
# utility, which does use e.g. unshare(2) system call to create a
|
||||||
@ -80,7 +81,8 @@ do
|
|||||||
opts[o++]="$lib"
|
opts[o++]="$lib"
|
||||||
opts[o++]="$lib"
|
opts[o++]="$lib"
|
||||||
done
|
done
|
||||||
for dir in /lib/tls /lib64/tls /lib64/x86_64 /usr/lib/ghostscript /usr/lib64/ghostscript /etc/ghostscript
|
arch=$(uname -i)
|
||||||
|
for dir in /lib/tls /lib64/tls /lib64/${arch} /usr/lib/ghostscript /usr/lib64/ghostscript /etc/ghostscript /lib64/glibc-hwcaps/${arch/_/[_-]}-v*
|
||||||
do
|
do
|
||||||
test -d "$dir" || continue
|
test -d "$dir" || continue
|
||||||
opts[o++]=--ro-bind
|
opts[o++]=--ro-bind
|
||||||
@ -304,7 +306,7 @@ fi
|
|||||||
# Clearly the `false´ should then changed to `true´
|
# Clearly the `false´ should then changed to `true´
|
||||||
if false
|
if false
|
||||||
then
|
then
|
||||||
for bin in /usr/bin/strace
|
for bin in /usr/bin/strace /bin/ls
|
||||||
do
|
do
|
||||||
opts[o++]=--ro-bind
|
opts[o++]=--ro-bind
|
||||||
opts[o++]="$bin"
|
opts[o++]="$bin"
|
||||||
@ -343,8 +345,6 @@ set -euo pipefail
|
|||||||
--chdir "$home" \
|
--chdir "$home" \
|
||||||
"${opts[@]}" \
|
"${opts[@]}" \
|
||||||
--new-session \
|
--new-session \
|
||||||
--sync-fd 0 \
|
|
||||||
--sync-fd 1 \
|
|
||||||
--sync-fd 2 \
|
--sync-fd 2 \
|
||||||
--setenv XDG_RUNTIME_DIR "/run/user/$uid" \
|
--setenv XDG_RUNTIME_DIR "/run/user/$uid" \
|
||||||
--setenv USER "$user" \
|
--setenv USER "$user" \
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Sep 14 11:56:38 UTC 2023 - Dr. Werner Fink <werner@suse.de>
|
||||||
|
|
||||||
|
- Make it work even with different hwcaps versions
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Dec 8 07:00:33 UTC 2021 - Dr. Werner Fink <werner@suse.de>
|
Wed Dec 8 07:00:33 UTC 2021 - Dr. Werner Fink <werner@suse.de>
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package gswrap
|
# spec file for package gswrap
|
||||||
#
|
#
|
||||||
# Copyright (c) 2021 SUSE LLC
|
# Copyright (c) 2023 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
|
||||||
|
Loading…
x
Reference in New Issue
Block a user