2015-03-08 15:36:37 +00:00
|
|
|
{ stdenv, ghcWithPackages, xmessage, makeWrapper, packages }:
|
2015-02-02 22:05:23 +00:00
|
|
|
|
|
|
|
let
|
|
|
|
xmonadEnv = ghcWithPackages (self: [ self.xmonad ] ++ packages self);
|
2015-03-08 15:36:37 +00:00
|
|
|
in stdenv.mkDerivation {
|
2015-02-02 22:05:23 +00:00
|
|
|
name = "xmonad-with-packages";
|
|
|
|
|
2015-03-08 15:36:37 +00:00
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
2015-02-02 22:05:23 +00:00
|
|
|
|
2015-03-08 15:36:37 +00:00
|
|
|
buildCommand = ''
|
2016-06-17 12:13:05 +01:00
|
|
|
mkdir -p $out/bin $out/share
|
2016-06-17 12:18:26 +01:00
|
|
|
ln -s ${xmonadEnv}/share/man $out/share/man
|
2015-03-08 15:36:37 +00:00
|
|
|
makeWrapper ${xmonadEnv}/bin/xmonad $out/bin/xmonad \
|
|
|
|
--set NIX_GHC "${xmonadEnv}/bin/ghc" \
|
2015-02-02 22:05:23 +00:00
|
|
|
--set XMONAD_XMESSAGE "${xmessage}/bin/xmessage"
|
|
|
|
'';
|
2015-09-01 08:42:08 +01:00
|
|
|
|
|
|
|
# trivial derivation
|
|
|
|
preferLocalBuild = true;
|
|
|
|
allowSubstitutes = false;
|
2015-03-08 15:36:37 +00:00
|
|
|
}
|