starsector: add missing runtime dependency xrandr

The starsector game is made using LWJGL, which depends on xrandr. The
library runs `xrandr -q` and parses its output to get screen
resolutions. Thus, if the binary is missing, the game will crash on
startup.

https://github.com/LWJGL/lwjgl/blob/master/src/java/org/lwjgl/opengl/XRandR.java#L72
This commit is contained in:
rafaelrc7 2024-01-06 00:27:33 -03:00
parent 24869f05da
commit df68e79bcf
No known key found for this signature in database
GPG key ID: A2E6A1C9A59514A5

View file

@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
ln -s $out/graphics/ui/s_icon64.png $out/share/icons/hicolor/64x64/apps/starsector.png
wrapProgram $out/share/starsector/starsector.sh \
--prefix PATH : ${lib.makeBinPath [ openjdk ]} \
--prefix PATH : ${lib.makeBinPath [ openjdk xorg.xrandr ]} \
--prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath buildInputs} \
--run 'mkdir -p ''${XDG_DATA_HOME:-~/.local/share}/starsector' \
--chdir "$out/share/starsector"