2021-01-15 13:21:58 +00:00
|
|
|
{ lib, stdenv, ghcWithPackages, makeWrapper, packages ? (x: []) }:
|
2015-06-30 16:11:43 +01:00
|
|
|
|
|
|
|
let
|
|
|
|
taffybarEnv = ghcWithPackages (self: [ self.taffybar ] ++ packages self);
|
|
|
|
in stdenv.mkDerivation {
|
2018-07-19 20:49:33 +01:00
|
|
|
name = "taffybar-with-packages-${taffybarEnv.version}";
|
2015-06-30 16:11:43 +01:00
|
|
|
|
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
|
|
|
|
buildCommand = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
makeWrapper ${taffybarEnv}/bin/taffybar $out/bin/taffybar \
|
|
|
|
--set NIX_GHC "${taffybarEnv}/bin/ghc"
|
|
|
|
'';
|
2016-08-02 17:06:29 +01:00
|
|
|
|
|
|
|
meta = {
|
2021-01-15 13:21:58 +00:00
|
|
|
platforms = lib.platforms.unix;
|
|
|
|
license = lib.licenses.bsd3;
|
2016-08-02 17:06:29 +01:00
|
|
|
};
|
2015-06-30 16:11:43 +01:00
|
|
|
}
|