mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-23 15:33:13 +00:00
gnupg: take libusb include path from pkg-config
This makes smartcards (like the Nitrokey) usable again.
This commit is contained in:
parent
a4e43841a2
commit
dace6a176d
@ -27,6 +27,7 @@ stdenv.mkDerivation rec {
|
||||
readline libusb gnutls adns openldap zlib bzip2
|
||||
];
|
||||
|
||||
patches = [ ./fix-libusb-include-path.patch ];
|
||||
postPatch = stdenv.lib.optionalString stdenv.isLinux ''
|
||||
sed -i 's,"libpcsclite\.so[^"]*","${pcsclite}/lib/libpcsclite.so",g' scd/scdaemon.c
|
||||
''; #" fix Emacs syntax highlighting :-(
|
||||
|
11
pkgs/tools/security/gnupg/fix-libusb-include-path.patch
Normal file
11
pkgs/tools/security/gnupg/fix-libusb-include-path.patch
Normal file
@ -0,0 +1,11 @@
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -8872,7 +8872,7 @@
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking libusb include dir" >&5
|
||||
$as_echo_n "checking libusb include dir... " >&6; }
|
||||
usb_incdir_found="no"
|
||||
- for _incdir in "" "/usr/include/libusb-1.0" "/usr/local/include/libusb-1.0"; do
|
||||
+ for _incdir in "$($PKG_CONFIG --variable=includedir libusb-1.0)/libusb-1.0"; do
|
||||
_libusb_save_cppflags=$CPPFLAGS
|
||||
if test -n "${_incdir}"; then
|
||||
CPPFLAGS="-I${_incdir} ${CPPFLAGS}"
|
Loading…
Reference in New Issue
Block a user