8ac5e011d6
GitOrigin-RevId: 2c3273caa153ee8eb5786bc8141b85b859e7efd7
20 lines
609 B
Nix
20 lines
609 B
Nix
{ stdenv, ghcWithPackages, xmessage, makeWrapper, packages }:
|
|
|
|
let
|
|
xmonadEnv = ghcWithPackages (self: [ self.xmonad ] ++ packages self);
|
|
in stdenv.mkDerivation {
|
|
name = "xmonad-with-packages-${xmonadEnv.version}";
|
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
buildCommand = ''
|
|
install -D ${xmonadEnv}/share/man/man1/xmonad.1.gz $out/share/man/man1/xmonad.1.gz
|
|
makeWrapper ${xmonadEnv}/bin/xmonad $out/bin/xmonad \
|
|
--set NIX_GHC "${xmonadEnv}/bin/ghc" \
|
|
--set XMONAD_XMESSAGE "${xmessage}/bin/xmessage"
|
|
'';
|
|
|
|
# trivial derivation
|
|
preferLocalBuild = true;
|
|
allowSubstitutes = false;
|
|
}
|