diff --git a/pkgs/opengl/insert-virtualgl.sh b/pkgs/opengl/insert-virtualgl.sh index bd68de1..22dc89a 100755 --- a/pkgs/opengl/insert-virtualgl.sh +++ b/pkgs/opengl/insert-virtualgl.sh @@ -240,6 +240,8 @@ EOF # Find all executables that depend on libGL and replace with a wrapper script that either executes the original # executable or a copy with an added libvglfaker.so dependency depending on whether VGL_DISPLAY is set or not. # +# Only run when we are a runtime dependency (i.e., our host matches). +# VGL_autoAddVGL() { declare opts=$(shopt -p) output set +o pipefail @@ -255,4 +257,7 @@ VGL_autoAddVGL() { eval "$opts" } -postFixupHooks+=(VGL_autoAddVGL) + +if (( hostOffset == 0 )); then + fixupOutputHooks+=(VGL_autoAddVGL) +fi