qq: use makewrapper instead of setting gappsWrapperArgs
This commit is contained in:
parent
ee6873bdbb
commit
4abe534795
@ -19,7 +19,6 @@
|
||||
, at-spi2-core
|
||||
, autoPatchelfHook
|
||||
, wrapGAppsHook
|
||||
, makeWrapper
|
||||
}:
|
||||
|
||||
let
|
||||
@ -43,8 +42,7 @@ stdenv.mkDerivation {
|
||||
|
||||
nativeBuildInputs = [
|
||||
autoPatchelfHook
|
||||
# makeBinaryWrapper not support shell wrapper specifically for `NIXOS_OZONE_WL`.
|
||||
(wrapGAppsHook.override { inherit makeWrapper; })
|
||||
wrapGAppsHook
|
||||
dpkg
|
||||
];
|
||||
|
||||
@ -76,7 +74,9 @@ stdenv.mkDerivation {
|
||||
substituteInPlace $out/share/applications/qq.desktop \
|
||||
--replace "/opt/QQ/qq" "$out/bin/qq" \
|
||||
--replace "/usr/share" "$out/share"
|
||||
ln -s $out/opt/QQ/qq $out/bin/qq
|
||||
makeWrapper $out/opt/QQ/qq $out/bin/qq \
|
||||
--prefix PATH : "${lib.makeBinPath [ gjs ]}" \
|
||||
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}"
|
||||
|
||||
# Remove bundled libraries
|
||||
rm -r $out/opt/QQ/resources/app/sharp-lib
|
||||
@ -91,13 +91,6 @@ stdenv.mkDerivation {
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
preFixup = ''
|
||||
gappsWrapperArgs+=(
|
||||
--prefix PATH : "${lib.makeBinPath [ gjs ]}"
|
||||
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}"
|
||||
)
|
||||
'';
|
||||
|
||||
passthru.updateScript = ./update.sh;
|
||||
|
||||
meta = with lib; {
|
||||
|
Loading…
Reference in New Issue
Block a user