about summary refs log tree commit diff
path: root/pkgs/applications/window-managers/i3/blocks.nix
diff options
context:
space:
mode:
authorKier Davis <kierdavis@gmail.com>2017-01-12 20:15:15 +0000
committerKier Davis <kierdavis@gmail.com>2017-01-12 20:15:15 +0000
commit90b3648f9c36f4f078ed6d0ff3682fe88ddf663a (patch)
tree97820fd65ad25da0c1404c361db59706090fbbc2 /pkgs/applications/window-managers/i3/blocks.nix
parent05bb3fe22e2cfa47a77fa44e278b78e6f21e988f (diff)
downloadnixlib-90b3648f9c36f4f078ed6d0ff3682fe88ddf663a.tar
nixlib-90b3648f9c36f4f078ed6d0ff3682fe88ddf663a.tar.gz
nixlib-90b3648f9c36f4f078ed6d0ff3682fe88ddf663a.tar.bz2
nixlib-90b3648f9c36f4f078ed6d0ff3682fe88ddf663a.tar.lz
nixlib-90b3648f9c36f4f078ed6d0ff3682fe88ddf663a.tar.xz
nixlib-90b3648f9c36f4f078ed6d0ff3682fe88ddf663a.tar.zst
nixlib-90b3648f9c36f4f078ed6d0ff3682fe88ddf663a.zip
i3blocks: search for config in correct system directory
The SYSCONFDIR variable used in the Makefile servers two purposes:

1) During buildPhase, it is hardcoded into the executable as one of
   the locations that will be searched for the i3blocks.conf config
   file. We want this set to "/etc", so that "/etc/i3blocks.conf"
   will be automatically loaded if it exists, as specified in the
   manpage.

2) During installPhase, it specifies the location that the sample
   i3blocks.conf should be installed to. We want this to be "$out/etc".

Case 2 was already handled correctly, but case 1 was not. This resulted
in i3blocks instead searching for i3blocks.conf in the default value of
SYSCONFDIR, which is "/usr/local/etc", a directory which generally does
not exist on NixOS. This commit remedies this problem by setting
SYSCONFDIR=/etc during buildPhase.

A minor stylistic fix (correcting a usage of "makeFlags" to "buildFlags"
in the expression) has also been applied in this commit.
Diffstat (limited to 'pkgs/applications/window-managers/i3/blocks.nix')
-rw-r--r--pkgs/applications/window-managers/i3/blocks.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/pkgs/applications/window-managers/i3/blocks.nix b/pkgs/applications/window-managers/i3/blocks.nix
index c3880b92bdf8..496da4232a40 100644
--- a/pkgs/applications/window-managers/i3/blocks.nix
+++ b/pkgs/applications/window-managers/i3/blocks.nix
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "c64720057e22cc7cac5e8fcd58fd37e75be3a7d5a3cb8995841a7f18d30c0536";
   };
 
-  makeFlags = "all";
+  buildFlags = "SYSCONFDIR=/etc all";
   installFlags = "PREFIX=\${out} VERSION=${version}";
 
   meta = with stdenv.lib; {