aboutsummaryrefslogtreecommitdiff
path: root/packages/bslock/pkg.nix
blob: 98ae7b554a2d5d4e309afd0e9768aee8ca623706 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
{ stdenv, xorgproto, libX11, libXinerama, libXext, libXrandr }:
with stdenv.lib;

let
  user = "imsohexy";
  group = "users";
in stdenv.mkDerivation rec {
  name = "local-bslock-${version}";
  version = "0.0.1";

  src = ./source;

  buildInputs = [ xorgproto libX11 libXinerama libXext libXrandr ];

  unpackPhase = ''cp -r $src/* .'';

  postPatch = "
    # sed -e 's/@@user/${user}/' -e 's/@@group/${group}/' -i config.def.h;
    sed -i '/chmod u+s/d' Makefile;
  ";

  buildPhase = ''make'';

  installPhase = ''make PREFIX=$out DESTDIR="" install'';
}