about summary refs log tree commit diff
path: root/pkgs/os-specific/linux/google-authenticator
diff options
context:
space:
mode:
authorRob Vermaas <rob.vermaas@gmail.com>2014-02-20 12:30:49 +0100
committerRob Vermaas <rob.vermaas@gmail.com>2014-02-20 12:30:49 +0100
commitcf00cd5e36920533f213d5087b7658d292dad428 (patch)
tree61a9497ef383803192506f81e05ed8e48de7511d /pkgs/os-specific/linux/google-authenticator
parent94591762fed83447e68548bd4da281070ae2f865 (diff)
Add support for printing qr code for google-authenticator.
Diffstat (limited to 'pkgs/os-specific/linux/google-authenticator')
-rw-r--r--pkgs/os-specific/linux/google-authenticator/default.nix6
1 files changed, 5 insertions, 1 deletions
diff --git a/pkgs/os-specific/linux/google-authenticator/default.nix b/pkgs/os-specific/linux/google-authenticator/default.nix
index d7acc6778b4d5..a9278f0c7ce0d 100644
--- a/pkgs/os-specific/linux/google-authenticator/default.nix
+++ b/pkgs/os-specific/linux/google-authenticator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pam }:
+{ stdenv, fetchurl, pam, qrencode }:
 
 stdenv.mkDerivation rec {
   name = "google-authenticator-1.0";
@@ -10,6 +10,10 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ pam ];
 
+  preConfigure = ''
+    sed -i 's|libqrencode.so.3|${qrencode}/lib/libqrencode.so.3|' google-authenticator.c
+  '';
+
   installPhase = ''
     ensureDir $out/bin $out/lib/security
     cp pam_google_authenticator.so $out/lib/security