From dbb6796cd4a8e6df5d9da30853e920fe0528ae9a Mon Sep 17 00:00:00 2001 From: Pol Dellaiera Date: Tue, 26 Mar 2024 07:50:40 +0100 Subject: tetrio-desktop: move to `pkgs/by-name` --- pkgs/games/tetrio-desktop/default.nix | 98 ------------------------------- pkgs/games/tetrio-desktop/tetrio-plus.nix | 27 --------- 2 files changed, 125 deletions(-) delete mode 100644 pkgs/games/tetrio-desktop/default.nix delete mode 100644 pkgs/games/tetrio-desktop/tetrio-plus.nix (limited to 'pkgs/games') diff --git a/pkgs/games/tetrio-desktop/default.nix b/pkgs/games/tetrio-desktop/default.nix deleted file mode 100644 index 97d73cddbb070..0000000000000 --- a/pkgs/games/tetrio-desktop/default.nix +++ /dev/null @@ -1,98 +0,0 @@ -{ stdenv -, lib -, fetchurl -, dpkg -, autoPatchelfHook -, wrapGAppsHook -, alsa-lib -, cups -, libGL -, libX11 -, libXScrnSaver -, libXtst -, mesa -, nss -, gtk3 -, libpulseaudio -, systemd -, callPackage -, withTetrioPlus ? false -, tetrio-plus ? callPackage ./tetrio-plus.nix { } -}: - -stdenv.mkDerivation rec { - pname = "tetrio-desktop"; - version = "9.0.0"; - - src = fetchurl { - url = "https://web.archive.org/web/20240309215118if_/https://tetr.io/about/desktop/builds/9/TETR.IO%20Setup.deb"; - name = "tetrio-desktop.deb"; - sha256 = "UriLwMB8D+/T32H4rPbkJAy/F/FFhNpd++0AR1lwEfs="; - }; - - nativeBuildInputs = [ - dpkg - autoPatchelfHook - wrapGAppsHook - ]; - - dontWrapGApps = true; - - buildInputs = [ - alsa-lib - cups - libX11 - libXScrnSaver - libXtst - mesa - nss - gtk3 - ]; - - libPath = lib.makeLibraryPath [ - libGL - libpulseaudio - systemd - ]; - - unpackCmd = "dpkg -x $curSrc src"; - - installPhase = '' - runHook preInstall - - mkdir $out - cp -r opt/ usr/share/ $out - - mkdir $out/bin - ln -s $out/opt/TETR.IO/TETR.IO $out/bin/ - - substituteInPlace $out/share/applications/TETR.IO.desktop \ - --replace-fail "Exec=/opt/TETR.IO/TETR.IO" "Exec=\"$out/opt/TETR.IO/TETR.IO\"" - - runHook postInstall - ''; - - postInstall = lib.strings.optionalString withTetrioPlus '' - cp ${tetrio-plus} $out/opt/TETR.IO/resources/app.asar - ''; - - postFixup = '' - wrapProgram $out/opt/TETR.IO/TETR.IO \ - --prefix LD_LIBRARY_PATH : ${libPath}:$out/opt/TETR.IO \ - ''${gappsWrapperArgs[@]} - ''; - - meta = with lib; { - homepage = "https://tetr.io"; - downloadPage = "https://tetr.io/about/desktop/"; - description = "TETR.IO desktop client"; - longDescription = '' - TETR.IO is a modern yet familiar online stacker. - Play against friends and foes all over the world, or claim a spot on the leaderboards - the stacker future is yours! - ''; - platforms = [ "x86_64-linux" ]; - license = licenses.unfree; - maintainers = with maintainers; [ wackbyte ]; - mainProgram = "TETR.IO"; - }; -} diff --git a/pkgs/games/tetrio-desktop/tetrio-plus.nix b/pkgs/games/tetrio-desktop/tetrio-plus.nix deleted file mode 100644 index 64f5dd5d85cc7..0000000000000 --- a/pkgs/games/tetrio-desktop/tetrio-plus.nix +++ /dev/null @@ -1,27 +0,0 @@ -{ lib, stdenv, fetchzip }: - -stdenv.mkDerivation rec { - pname = "tetrio-plus"; - version = "0.25.3"; - - src = fetchzip { - url = "https://gitlab.com/UniQMG/tetrio-plus/uploads/684477053451cd0819e2c84e145966eb/tetrio-plus_0.25.3_app.asar.zip"; - sha256 = "sha256-GQgt4GZNeKx/uzmVsuKppW2zg8AAiGqsk2JYJIkqfVE="; - }; - - installPhase = '' - runHook preInstall - - install app.asar $out - - runHook postInstall - ''; - - meta = with lib; { - description = "TETR.IO customization toolkit"; - homepage = "https://gitlab.com/UniQMG/tetrio-plus"; - license = licenses.mit; - maintainers = with maintainers; [ huantian ]; - platforms = [ "x86_64-linux" ]; - }; -} -- cgit 1.4.1