diff --git a/pkgs/development/embedded/tytools/default.nix b/pkgs/development/embedded/tytools/default.nix index 76ff17c0b6fe..0d18346cf53a 100644 --- a/pkgs/development/embedded/tytools/default.nix +++ b/pkgs/development/embedded/tytools/default.nix @@ -5,34 +5,58 @@ cmake, pkg-config, wrapQtAppsHook, - qtbase, + qt6, }: stdenv.mkDerivation rec { pname = "tytools"; - version = "0.9.8"; + version = "0.9.9"; src = fetchFromGitHub { owner = "Koromix"; - repo = pname; - rev = "v${version}"; - sha256 = "sha256-MKhh0ooDZI1Ks8vVuPRiHhpOqStetGaAhE2ulvBstxA="; + repo = "rygel"; + tag = "tytools/${version}"; + hash = "sha256-nQZaNYOTkx79UC0RHencKIQFSYUnQ9resdmmWTmgQxA="; }; nativeBuildInputs = [ - cmake pkg-config - wrapQtAppsHook - ]; - buildInputs = [ - qtbase + qt6.wrapQtAppsHook ]; - meta = with lib; { + buildInputs = [ + qt6.qtbase + ]; + + buildPhase = '' + runHook preBuild + + ./bootstrap.sh + ./felix -p Fast tyuploader + ./felix -p Fast tycmd + ./felix -p Fast tycommander + + runHook postBuild + ''; + + installPhase = '' + runHook preInstall + + mkdir -p $out/bin $out/share/applications + cp bin/Fast/tyuploader $out/bin/ + cp bin/Fast/tycmd $out/bin/ + cp bin/Fast/tycommander $out/bin/ + cp src/tytools/tycommander/tycommander_linux.desktop $out/share/applications/tycommander.desktop + cp src/tytools/tyuploader/tyuploader_linux.desktop $out/share/applications/tyuploader.desktop + + runHook postInstall + ''; + + meta = { description = "Collection of tools to manage Teensy boards"; homepage = "https://koromix.dev/tytools"; - license = licenses.unlicense; - platforms = platforms.unix; - maintainers = with maintainers; [ ahuzik ]; + license = lib.licenses.unlicense; + platforms = lib.platforms.unix; + maintainers = with lib.maintainers; [ ahuzik ]; }; }