Don't use flake but a simple package
This commit is contained in:
parent
e866dd7a81
commit
29f3d5eed5
3 changed files with 96 additions and 11 deletions
85
default.nix
Normal file
85
default.nix
Normal file
|
@ -0,0 +1,85 @@
|
||||||
|
{ lib
|
||||||
|
, stdenv
|
||||||
|
, fetchFromGitea
|
||||||
|
, nix-update-script
|
||||||
|
, meson
|
||||||
|
, ninja
|
||||||
|
, gettext
|
||||||
|
, desktop-file-utils
|
||||||
|
, cargo
|
||||||
|
, rustPlatform
|
||||||
|
, rustc
|
||||||
|
, pkg-config
|
||||||
|
, glib
|
||||||
|
, libadwaita
|
||||||
|
, libhandy
|
||||||
|
, gtk4
|
||||||
|
, openssl
|
||||||
|
, alsa-lib
|
||||||
|
, libpulseaudio
|
||||||
|
, wrapGAppsHook4
|
||||||
|
, blueprint-compiler
|
||||||
|
, gst_all_1
|
||||||
|
}:
|
||||||
|
|
||||||
|
stdenv.mkDerivation rec {
|
||||||
|
pname = "spot";
|
||||||
|
version = "0.6.0";
|
||||||
|
|
||||||
|
src = fetchFromGitea {
|
||||||
|
domain = "git.le43.eu";
|
||||||
|
owner = "tbarnouin";
|
||||||
|
repo = "spot";
|
||||||
|
rev = "main";
|
||||||
|
hash = "sha256-C/HeqN1Y/bNYWx3WsqIKf6rjLBI3TPs5h+kLClvurYQ=";
|
||||||
|
};
|
||||||
|
|
||||||
|
cargoDeps = rustPlatform.fetchCargoTarball {
|
||||||
|
inherit src;
|
||||||
|
name = "${pname}-${version}";
|
||||||
|
hash = "sha256-HIjA+oDFegsnnV3EViaWfsNhmqPB1yl8rIVS5LbTu/A=";
|
||||||
|
};
|
||||||
|
|
||||||
|
nativeBuildInputs = [
|
||||||
|
gettext
|
||||||
|
meson
|
||||||
|
ninja
|
||||||
|
pkg-config
|
||||||
|
gtk4 # for gtk-update-icon-cache
|
||||||
|
glib # for glib-compile-schemas
|
||||||
|
desktop-file-utils
|
||||||
|
cargo
|
||||||
|
rustPlatform.cargoSetupHook
|
||||||
|
rustc
|
||||||
|
wrapGAppsHook4
|
||||||
|
blueprint-compiler
|
||||||
|
];
|
||||||
|
|
||||||
|
buildInputs = [
|
||||||
|
glib
|
||||||
|
gtk4
|
||||||
|
libadwaita
|
||||||
|
libhandy
|
||||||
|
openssl
|
||||||
|
alsa-lib
|
||||||
|
libpulseaudio
|
||||||
|
gst_all_1.gst-plugins-base
|
||||||
|
gst_all_1.gstreamer
|
||||||
|
];
|
||||||
|
|
||||||
|
# https://github.com/xou816/spot/issues/313
|
||||||
|
mesonBuildType = "release";
|
||||||
|
|
||||||
|
passthru = {
|
||||||
|
updateScript = nix-update-script { };
|
||||||
|
};
|
||||||
|
|
||||||
|
meta = with lib; {
|
||||||
|
description = "Native Spotify client for the GNOME desktop";
|
||||||
|
mainProgram = "spot";
|
||||||
|
homepage = "https://github.com/xou816/spot";
|
||||||
|
license = licenses.mit;
|
||||||
|
maintainers = [ ];
|
||||||
|
platforms = platforms.linux;
|
||||||
|
};
|
||||||
|
}
|
12
flake.lock
12
flake.lock
|
@ -35,16 +35,16 @@
|
||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731245184,
|
"lastModified": 1731386116,
|
||||||
"narHash": "sha256-vmLS8+x+gHRv1yzj3n+GTAEObwmhxmkkukB2DwtJRdU=",
|
"narHash": "sha256-lKA770aUmjPHdTaJWnP3yQ9OI1TigenUqVC3wweqZuI=",
|
||||||
"owner": "nixos",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "aebe249544837ce42588aa4b2e7972222ba12e8f",
|
"rev": "689fed12a013f56d4c4d3f612489634267d86529",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nixos",
|
"owner": "NixOS",
|
||||||
"ref": "nixpkgs-unstable",
|
"ref": "nixos-24.05",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
|
|
10
flake.nix
10
flake.nix
|
@ -1,9 +1,9 @@
|
||||||
{
|
{
|
||||||
description = "A GUI for yt-dlp written in Rust";
|
description = "A Spotify client for Gnome";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
flake-utils.url = "github:numtide/flake-utils";
|
flake-utils.url = "github:numtide/flake-utils";
|
||||||
nixpkgs.url = "github:nixos/nixpkgs?ref=nixpkgs-unstable";
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05";
|
||||||
rust-overlay.url = "github:oxalica/rust-overlay";
|
rust-overlay.url = "github:oxalica/rust-overlay";
|
||||||
crane = {
|
crane = {
|
||||||
url = "github:ipetkov/crane";
|
url = "github:ipetkov/crane";
|
||||||
|
@ -52,6 +52,9 @@
|
||||||
gst_all_1.gstreamer
|
gst_all_1.gstreamer
|
||||||
];
|
];
|
||||||
|
|
||||||
|
cargoLock = {
|
||||||
|
lockFile = "./Cargo.lock";
|
||||||
|
};
|
||||||
|
|
||||||
cargoArtifacts = craneLib.buildDepsOnly ({
|
cargoArtifacts = craneLib.buildDepsOnly ({
|
||||||
src = craneLib.cleanCargoSource (craneLib.path ./.);
|
src = craneLib.cleanCargoSource (craneLib.path ./.);
|
||||||
|
@ -62,10 +65,7 @@
|
||||||
packages = rec {
|
packages = rec {
|
||||||
spot = craneLib.buildPackage {
|
spot = craneLib.buildPackage {
|
||||||
src = craneLib.path ./.;
|
src = craneLib.path ./.;
|
||||||
cargoHash = "";
|
|
||||||
|
|
||||||
inherit buildInputs nativeBuildInputs cargoArtifacts;
|
inherit buildInputs nativeBuildInputs cargoArtifacts;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
default = spot;
|
default = spot;
|
||||||
|
|
Loading…
Reference in a new issue