3
0
Fork 0
forked from mirrors/nixpkgs

gnupg: Variable path to pinentry

This is needed for pinentry-mac which has the pinentry binary
at an OS X-ish path.
This commit is contained in:
Kirill Elagin 2016-06-17 12:27:59 +03:00
parent 62d9edb9b9
commit 213dc21443
3 changed files with 8 additions and 2 deletions

View file

@ -35,7 +35,8 @@ stdenv.mkDerivation rec {
patch gl/stdint_.h < ${./clang.patch}
'';
configureFlags = optional guiSupport "--with-pinentry-pgm=${pinentry}/bin/pinentry";
pinentryBinaryPath = pinentry.binaryPath or "bin/pinentry";
configureFlags = optional guiSupport "--with-pinentry-pgm=${pinentry}/${pinentryBinaryPath}";
postConfigure = "substituteAllInPlace tools/gpgkey2ssh.c";

View file

@ -32,7 +32,8 @@ stdenv.mkDerivation rec {
sed -i 's,"libpcsclite\.so[^"]*","${pcsclite}/lib/libpcsclite.so",g' scd/scdaemon.c
''; #" fix Emacs syntax highlighting :-(
configureFlags = optional guiSupport "--with-pinentry-pgm=${pinentry}/bin/pinentry";
pinentryBinaryPath = pinentry.binaryPath or "bin/pinentry";
configureFlags = optional guiSupport "--with-pinentry-pgm=${pinentry}/${pinentryBinaryPath}";
meta = with stdenv.lib; {
homepage = http://gnupg.org;

View file

@ -17,6 +17,10 @@ stdenv.mkDerivation rec {
mv build/Release/pinentry-mac.app $out/Applications
'';
passthru = {
binaryPath = "Applications/pinentry-mac.app/Contents/MacOS/pinentry-mac";
};
meta = {
description = "Pinentry for GPG on Mac";
license = stdenv.lib.licenses.gpl2Plus;