Skip to content

Commit

Permalink
plex-desktop: add libdrm to buildFHSEnv, update sqlite write permissi…
Browse files Browse the repository at this point in the history
…ons (#357108)
  • Loading branch information
SuperSandro2000 authored Dec 18, 2024
2 parents 13fe27f + e1a323a commit 532a90f
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion pkgs/by-name/pl/plex-desktop/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
libGL,
libapparmor,
libbsd,
libdrm,
libedit,
libffi_3_3,
libgcrypt,
Expand Down Expand Up @@ -122,7 +123,10 @@ let
in
buildFHSEnv {
inherit pname version meta;
targetPkgs = pkgs: [ xkeyboard_config ];
targetPkgs = pkgs: [
libdrm
xkeyboard_config
];

extraInstallCommands = ''
mkdir -p $out/share/applications $out/share/icons/hicolor/scalable/apps
Expand All @@ -136,6 +140,17 @@ buildFHSEnv {
runScript = writeShellScript "plex-desktop.sh" ''
# Widevine won't download unless this directory exists.
mkdir -p $HOME/.cache/plex/
# Copy the sqlite plugin database on first run.
PLEX_DB="$HOME/.local/share/plex/Plex Media Server/Plug-in Support/Databases"
if [[ ! -d "$PLEX_DB" ]]; then
mkdir -p "$PLEX_DB"
cp "${plex-desktop}/resources/com.plexapp.plugins.library.db" "$PLEX_DB"
fi
# db files should have write access.
chmod --recursive 750 "$PLEX_DB"
PLEX_USR_PATH=${lib.makeSearchPath "usr/lib/x86_64-linux-gnu" [ plex-desktop ]}
set -o allexport
Expand Down

0 comments on commit 532a90f

Please sign in to comment.