mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-17 15:22:59 +01:00
wpa_supplicant: refactor settings, readline support (on by default)
This commit is contained in:
parent
ecee1be7f1
commit
0072c44255
1 changed files with 16 additions and 7 deletions
|
@ -1,4 +1,7 @@
|
|||
{ stdenv, fetchurl, openssl, dbus_libs, pkgconfig, libnl }:
|
||||
{ stdenv, fetchurl, lib, openssl, dbus_libs, pkgconfig, libnl
|
||||
, readlineSupport ? true, readline
|
||||
}:
|
||||
assert readlineSupport -> readline!=null;
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "1.1";
|
||||
|
@ -9,20 +12,26 @@ stdenv.mkDerivation rec {
|
|||
url = "http://hostap.epitest.fi/releases/${name}.tar.gz";
|
||||
sha256 = "00lyifj8cz7qyal6dy1dxbpk3g3bywvdarik8gbj9ds7zmfbwkd5";
|
||||
};
|
||||
extraConfig = lib.concatStringsSep "\n" (
|
||||
[ "CONFIG_DEBUG_SYSLOG=y"
|
||||
"CONFIG_CTRL_IFACE_DBUS=y"
|
||||
"CONFIG_CTRL_IFACE_DBUS_NEW=y"
|
||||
"CONFIG_CTRL_IFACE_DBUS_INTRO=y"
|
||||
"CONFIG_DRIVER_NL80211=y"
|
||||
"CONFIG_LIBNL32=y"
|
||||
] ++ lib.optional readlineSupport "CONFIG_READLINE=y"
|
||||
);
|
||||
|
||||
preBuild = ''
|
||||
cd wpa_supplicant
|
||||
cp -v defconfig .config
|
||||
echo CONFIG_DEBUG_SYSLOG=y | tee -a .config
|
||||
echo CONFIG_CTRL_IFACE_DBUS=y | tee -a .config
|
||||
echo CONFIG_CTRL_IFACE_DBUS_NEW=y | tee -a .config
|
||||
echo CONFIG_CTRL_IFACE_DBUS_INTRO=y | tee -a .config
|
||||
echo CONFIG_DRIVER_NL80211=y | tee -a .config
|
||||
echo ${extraConfig} | tee -a .config
|
||||
echo CONFIG_LIBNL32=y | tee -a .config
|
||||
substituteInPlace Makefile --replace /usr/local $out
|
||||
'';
|
||||
|
||||
buildInputs = [ openssl dbus_libs libnl ];
|
||||
buildInputs = [ openssl dbus_libs libnl ]
|
||||
++ lib.optional readlineSupport readline;
|
||||
|
||||
buildNativeInputs = [ pkgconfig ];
|
||||
|
||||
|
|
Loading…
Reference in a new issue