2023-02-09 11:40:11 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
2023-05-24 13:37:59 +00:00
|
|
|
, cargo
|
2023-02-09 11:40:11 +00:00
|
|
|
, pkg-config
|
2023-05-24 13:37:59 +00:00
|
|
|
, rustc
|
2023-02-09 11:40:11 +00:00
|
|
|
, openssl
|
|
|
|
, udev
|
|
|
|
, gtk3
|
|
|
|
, wrapGAppsHook
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2020-09-25 04:45:31 +00:00
|
|
|
pname = "firmware-manager";
|
2023-05-24 13:37:59 +00:00
|
|
|
version = "0.1.5";
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "pop-os";
|
|
|
|
repo = pname;
|
2023-05-24 13:37:59 +00:00
|
|
|
rev = version;
|
|
|
|
hash = "sha256-Q+LJJ4xK583fAcwuOFykt6GKT0rVJgmTt+zUX4o4Tm4=";
|
2020-09-25 04:45:31 +00:00
|
|
|
};
|
|
|
|
|
2023-03-27 19:17:25 +00:00
|
|
|
cargoDeps = rustPlatform.importCargoLock {
|
|
|
|
lockFile = ./Cargo.lock;
|
|
|
|
outputHashes = {
|
|
|
|
"ecflash-0.1.0" = "sha256-W613wbW54R65/rs6oiPAH/qov2OVEjMMszpUJdX4TxI=";
|
2023-05-24 13:37:59 +00:00
|
|
|
"system76-firmware-1.0.51" = "sha256-+GPz7uKygGnFUptQEGYWkEdHgxBc65kLZqpwZqtwets=";
|
2023-03-27 19:17:25 +00:00
|
|
|
};
|
2023-02-09 11:40:11 +00:00
|
|
|
};
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
postPatch = ''
|
2023-02-09 11:40:11 +00:00
|
|
|
substituteInPlace Makefile --replace '$(DESTDIR)/etc' '$(DESTDIR)$(prefix)/etc'
|
2020-09-25 04:45:31 +00:00
|
|
|
'';
|
|
|
|
|
2023-05-24 13:37:59 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
cargo
|
|
|
|
rustc
|
2023-02-09 11:40:11 +00:00
|
|
|
pkg-config
|
2023-05-24 13:37:59 +00:00
|
|
|
rustPlatform.cargoSetupHook
|
2023-02-09 11:40:11 +00:00
|
|
|
wrapGAppsHook
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
openssl
|
|
|
|
gtk3
|
|
|
|
udev
|
|
|
|
];
|
|
|
|
|
|
|
|
makeFlags = [ "prefix=$(out)" ];
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Graphical frontend for firmware management";
|
|
|
|
homepage = "https://github.com/pop-os/firmware-manager";
|
|
|
|
license = lib.licenses.gpl3;
|
|
|
|
maintainers = [ lib.maintainers.shlevy ];
|
|
|
|
platforms = lib.platforms.linux;
|
|
|
|
};
|
|
|
|
}
|