Merge pull request #307288 from TomaSajt/wrapper-variable-expansion

koodo-reader: fix wrapper variable expansion
This commit is contained in:
éclairevoyant 2024-04-28 12:14:53 +00:00 committed by GitHub
commit e82b22bf8d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -7,6 +7,7 @@
fetchYarnDeps,
makeDesktopItem,
copyDesktopItems,
makeWrapper,
wrapGAppsHook,
electron,
}:
@ -37,6 +38,7 @@ mkYarnPackage rec {
nativeBuildInputs = [
copyDesktopItems
makeWrapper
wrapGAppsHook
];
@ -77,8 +79,9 @@ mkYarnPackage rec {
runHook postInstall
'';
# we use makeShellWrapper instead of the makeBinaryWrapper provided by wrapGAppsHook for proper shell variable expansion
postFixup = ''
makeWrapper ${electron}/bin/electron $out/bin/koodo-reader \
makeShellWrapper ${electron}/bin/electron $out/bin/koodo-reader \
--add-flags $out/share/lib/koodo-reader/resources/app.asar \
"''${gappsWrapperArgs[@]}" \
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}" \