2022-03-29 11:05:01 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, libX11 }:
|
2014-05-30 15:56:05 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation {
|
2021-08-27 14:47:49 +00:00
|
|
|
pname = "disk-indicator";
|
2022-05-13 20:03:00 +00:00
|
|
|
version = "unstable-2018-12-18";
|
2014-05-30 15:56:05 +00:00
|
|
|
|
2022-03-29 11:05:01 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "MeanEYE";
|
|
|
|
repo = "Disk-Indicator";
|
2022-05-13 20:03:00 +00:00
|
|
|
rev = "ec2d2f6833f038f07a72d15e2d52625c23e10b12";
|
|
|
|
sha256 = "sha256-cRqgIxF6H1WyJs5hhaAXVdWAlv6t22BZLp3p/qRlCSM=";
|
2014-05-30 15:56:05 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ libX11 ];
|
|
|
|
|
2022-05-13 20:03:00 +00:00
|
|
|
postPatch = ''
|
|
|
|
# avoid -Werror
|
|
|
|
substituteInPlace Makefile --replace "-Werror" ""
|
|
|
|
# avoid host-specific options
|
|
|
|
substituteInPlace Makefile --replace "-march=native" ""
|
2014-05-30 15:56:05 +00:00
|
|
|
'';
|
|
|
|
|
2022-05-13 20:03:00 +00:00
|
|
|
postConfigure = ''
|
|
|
|
patchShebangs ./configure.sh
|
|
|
|
./configure.sh --all
|
|
|
|
'';
|
2016-02-26 17:38:15 +00:00
|
|
|
|
2022-05-13 20:03:00 +00:00
|
|
|
makeFlags = [
|
|
|
|
"COMPILER=${stdenv.cc.targetPrefix}cc"
|
|
|
|
];
|
2014-11-28 17:40:19 +00:00
|
|
|
|
2014-05-30 15:56:05 +00:00
|
|
|
installPhase = ''
|
2022-05-13 20:03:00 +00:00
|
|
|
runHook preInstall
|
|
|
|
|
2014-05-30 15:56:05 +00:00
|
|
|
mkdir -p "$out/bin"
|
|
|
|
cp ./disk_indicator "$out/bin/"
|
2022-05-13 20:03:00 +00:00
|
|
|
|
|
|
|
runHook postInstall
|
2014-05-30 15:56:05 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://github.com/MeanEYE/Disk-Indicator";
|
2014-05-30 15:56:05 +00:00
|
|
|
description = "A program that will turn a LED into a hard disk indicator";
|
|
|
|
longDescription = ''
|
|
|
|
Small program for Linux that will turn your Scroll, Caps or Num Lock LED
|
|
|
|
or LED on your ThinkPad laptop into a hard disk activity indicator.
|
|
|
|
'';
|
2021-01-15 14:45:37 +00:00
|
|
|
license = lib.licenses.gpl3;
|
|
|
|
platforms = lib.platforms.linux;
|
2014-05-30 15:56:05 +00:00
|
|
|
};
|
|
|
|
}
|