sftool: init at 0.1.13; sftool-gui: init at 1.0.2 (#440026)
This commit is contained in:
@@ -0,0 +1,75 @@
|
||||
{
|
||||
lib,
|
||||
stdenv,
|
||||
rustPlatform,
|
||||
cargo-tauri,
|
||||
glib-networking,
|
||||
nodejs,
|
||||
libgudev,
|
||||
systemdLibs,
|
||||
pnpm,
|
||||
openssl,
|
||||
nix-update-script,
|
||||
pkg-config,
|
||||
webkitgtk_4_1,
|
||||
wrapGAppsHook4,
|
||||
autoPatchelfHook,
|
||||
fetchFromGitHub,
|
||||
}:
|
||||
rustPlatform.buildRustPackage (finalAttrs: {
|
||||
pname = "sftool-gui";
|
||||
version = "1.0.2";
|
||||
src = fetchFromGitHub {
|
||||
owner = "OpenSiFli";
|
||||
repo = "sftool-gui";
|
||||
tag = "v${finalAttrs.version}";
|
||||
hash = "sha256-FD3eQN4Uto4q7gdyfK5KUyZJ5ZiIJeUKkqaCZRWdQNo=";
|
||||
};
|
||||
|
||||
cargoHash = "sha256-XAU3ru+TxUo99OQwcXNLJ8gzBOZUkC8UCAApz7M/QTM=";
|
||||
cargoRoot = "src-tauri";
|
||||
|
||||
pnpmDeps = pnpm.fetchDeps {
|
||||
fetcherVersion = 2;
|
||||
inherit (finalAttrs) pname version src;
|
||||
hash = "sha256-gamgu9koBf+JLDswi3eGXRZybF8UiYE8CoifpQCgLaI=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
cargo-tauri.hook
|
||||
pnpm.configHook
|
||||
nodejs
|
||||
pkg-config
|
||||
]
|
||||
++ lib.optionals stdenv.hostPlatform.isLinux [
|
||||
wrapGAppsHook4
|
||||
autoPatchelfHook
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
openssl
|
||||
]
|
||||
++ lib.optionals stdenv.hostPlatform.isLinux [
|
||||
glib-networking # Most Tauri apps need networking
|
||||
webkitgtk_4_1
|
||||
libgudev
|
||||
systemdLibs
|
||||
];
|
||||
|
||||
# Set our Tauri source directory
|
||||
# And make sure we build there too
|
||||
buildAndTestSubdir = finalAttrs.cargoRoot;
|
||||
|
||||
passthru = {
|
||||
inherit (finalAttrs) pnpmDeps;
|
||||
updateScript = nix-update-script { };
|
||||
};
|
||||
|
||||
meta = {
|
||||
description = "Download tool for the SiFli family of chips";
|
||||
homepage = "https://github.com/OpenSiFli/sftool-gui";
|
||||
license = lib.licenses.asl20;
|
||||
maintainers = with lib.maintainers; [ eihqnh ];
|
||||
mainProgram = "sftool";
|
||||
};
|
||||
})
|
||||
@@ -0,0 +1,40 @@
|
||||
{
|
||||
lib,
|
||||
pkg-config,
|
||||
rustPlatform,
|
||||
stdenv,
|
||||
systemdLibs,
|
||||
fetchFromGitHub,
|
||||
nix-update-script,
|
||||
}:
|
||||
|
||||
rustPlatform.buildRustPackage (finalAttrs: {
|
||||
pname = "sftool";
|
||||
version = "0.1.13";
|
||||
src = fetchFromGitHub {
|
||||
owner = "OpenSiFli";
|
||||
repo = "sftool";
|
||||
tag = finalAttrs.version;
|
||||
hash = "sha256-/5RVBWHrZpPK2R4khnvZAnFyMfSZStCnQO5g7Ao9Ck4=";
|
||||
};
|
||||
|
||||
cargoHash = "sha256-fteBYld3JzsTn/KMy5w/6Ts7x1PsYmi8zhBvgYVw5os=";
|
||||
|
||||
nativeBuildInputs = [
|
||||
pkg-config
|
||||
];
|
||||
|
||||
buildInputs = lib.optionals stdenv.hostPlatform.isLinux [
|
||||
systemdLibs # libudev-sys
|
||||
];
|
||||
|
||||
passthru.updateScript = nix-update-script { };
|
||||
|
||||
meta = {
|
||||
description = "Download tool for the SiFli family of chips";
|
||||
homepage = "https://github.com/OpenSiFli/sftool";
|
||||
license = lib.licenses.asl20;
|
||||
maintainers = with lib.maintainers; [ eihqnh ];
|
||||
mainProgram = "sftool";
|
||||
};
|
||||
})
|
||||
Reference in New Issue
Block a user