VR/zh: Difference between revisions

Ardenet (talk | contribs)
Created page with "=== 修补 bubblewrap 以允许启用能力(capabilities) ==="
Tags: Mobile edit Mobile web edit
Ardenet (talk | contribs)
Tags: Mobile edit Mobile web edit
 
(7 intermediate revisions by the same user not shown)
Line 188: Line 188:
=== 修补 bubblewrap 以允许启用能力(capabilities) ===
=== 修补 bubblewrap 以允许启用能力(capabilities) ===


<div lang="en" dir="ltr" class="mw-content-ltr">
通过修改用于运行 Steam 的 bubblewrap 二进制文件,您可以允许该 FHS 环境中的进程获取能力。这样就无需直接修补内核了。
By modifying the bubblewrap binary used for running Steam, you can allow processes in that FHS environment to acquire capabilities. This removes the need for patching the kernel directly.
</div>


{{Warning|<span lang="en" dir="ltr" class="mw-content-ltr">This circumvents an intended security mechanism in bubblewrap, and allows all other software launched by steam, or running via steam-run to acquire these capabilities as well.</span>}}
{{Warning|这绕过了 bubblewrap 中预设的安全机制,并允许所有其他由 steam 启动或通过 steam-run 运行的软件也获得这些能力。}}


{{file|/etc/nixos/configuration.nix|nix|3=programs.steam = let
{{file|/etc/nixos/configuration.nix|nix|3=programs.steam = let
Line 231: Line 229:
}}
}}


<div lang="en" dir="ltr" class="mw-content-ltr">
作为额外的更改,您可能还需要用指向修改后的 bwrap 二进制文件的符号链接替换 ​​Steam 自己的 bwrap 二进制文件,该链接位于 <code>~/.local/share/Steam/ubuntu12_32/steam-runtime/usr/libexec/steam-runtime-tools-0/srt-bwrap</code>
as an additional change, you may also need to replace Steam's own bwrap binary with a symbolic link to this modified bwrap binary, found at <code>~/.local/share/Steam/ubuntu12_32/steam-runtime/usr/libexec/steam-runtime-tools-0/srt-bwrap</code>.
</div>


<div lang="en" dir="ltr" class="mw-content-ltr">
steam-runtime 更新时,Steam 会定期用自己的二进制文件替换此修改,因此您可能需要在功能异常时,重新应用此修改。
Steam will periodically replace this modification with its own binary when steam-runtime updates, so you may need to re-apply this change if it breaks.
</div>


== wlx-overlay-s ==
== wlx-overlay-s ==
Line 246: Line 240:
==== SteamVR 自动启动 ====
==== SteamVR 自动启动 ====


<div class="mw-translate-fuzzy">
在 SteamVR(或任何 OpenVR 合成器)中启动 wlx-overlay-s 时,它会注册一个自动启动清单。目前,此清单将引用 wlx-overlay-s 的 Nix 存储路径,该路径可能会在重建 NixOS/Nix 配置文件后被垃圾回收。一种解决方法是定期运行以下命令来更新清单的存储路径:
在 SteamVR(或任何 OpenVR 合成器)中启动 wlx-overlay-s 时,它会注册一个自动启动清单。目前,此清单将引用 wlx-overlay-s 的 Nix 存储路径,该路径可能会在重建 NixOS/Nix 配置文件后被垃圾回收。一种解决方法是定期运行以下命令来更新清单的存储路径:{{Commands|
# 运行 wlx-overlay-s 并替换任何正在运行的实例
$ wlx-overlay-s --replace}}
</div>


{{Commands|
{{Commands|
# <span lang="en" dir="ltr" class="mw-content-ltr">Run wlx-overlay-s and replace any running instance</span>
# 运行 wlx-overlay-s 并替换任何正在运行的实例
$ wlx-overlay-s --replace}}
$ wlx-overlay-s --replace}}


Line 259: Line 249:
== 另见 ==
== 另见 ==


<div class="mw-translate-fuzzy">
* [https://lvra.gitlab.io Linux VR Adventures Wiki]
* [https://lvra.gitlab.io Linux VR Adventures Wiki]
[[Category:Video/zh|分类:视频]]
[[Category:Video/zh|分类:视频]]
[[Category:Hardware/zh|分类:硬件]]
[[Category:Hardware/zh|分类:硬件]]
[[Category:Desktop/zh|分类:桌面]]
[[Category:Desktop/zh|分类:桌面]]
[[Category:Gaming/zh|分类:游戏]]
[[Category:Gaming/zh|分类:游戏]]
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
[[Category:Video]]
[[Category:Hardware]]
[[Category:Desktop]]
[[Category:Gaming]]
</div>