Package request: wpa_supplicant
drygdryg opened this issue · 7 comments
Package description
wpa_supplicant is a WPA Supplicant for Linux, BSD, Mac OS X, and Windows with support for WPA and WPA2 (IEEE 802.11i / RSN). It is suitable for both desktop/laptop computers and embedded systems. Supplicant is the IEEE 802.1X/WPA component that is used in the client stations. It implements key negotiation with a WPA Authenticator and it controls the roaming and IEEE 802.11 authentication/association of the wlan driver.
Link to home page and sources
- Home page: https://www.w1.fi/wpa_supplicant/
- Source code: latest: https://www.w1.fi/releases/wpa_supplicant-2.9.tar.gz
Additional information
Estimated requirements: openssl openssl-static dbus dbus-glib dbus-glib-static dbus-static readline readline-static ncurses ncurses-static libnl libnl-static
I tried to compile wpa_supplicant 2.9 on device by following commands:
pkg install wget build-essential pkg-config openssl openssl-static dbus dbus-glib dbus-glib-static dbus-static readline readline-static ncurses ncurses-static libnl libnl-static
wget https://www.w1.fi/releases/wpa_supplicant-2.9.tar.gz && tar xvf wpa_supplicant-2.9.tar.gz
cd wpa_supplicant-2.9/wpa_supplicant/
cp defconfig .config
make
But got the following error (full build log: https://pastebin.com/rr1fG1Zk):
In file included from ../src/drivers/driver_wext.c:28:
../src/drivers/priv_netlink.h:76:8: error: redefinition of 'sockaddr_nl'
struct sockaddr_nl
^
/data/data/com.termux/files/usr/include/linux/netlink.h:48:8: note: previous definition is here
struct sockaddr_nl {
^
In file included from ../src/drivers/driver_wext.c:28:
../src/drivers/priv_netlink.h:84:8: error: redefinition of 'nlmsghdr'
struct nlmsghdr
^
/data/data/com.termux/files/usr/include/linux/netlink.h:54:8: note: previous definition is here
struct nlmsghdr {
^
Your ROM doesn't have /system/bin/wpa_supplicant
or /system/vendor/bin/hw/wpa_supplicant
(really, it must have) ?
My ROM (AOSP 9 based) have wpa_supplicant (/system/vendor/bin/hw/wpa_supplicant), but I can't run it with custom options (because it modified by Google for Android). So I need for original not moded wpa_supplicant.
I need to run wpa_supplicant with following options: -K -dd -i[interface] -c[path]. My system wpa_supplicant (and many wpa_supplicant on other devices) do not support running with custom options.
I successfully launched wpa_supplicant from Ubuntu 18.04 environment with my options (via Linux Deploy). Also I successfully builded wpa_supplicant 2.9 in Ubuntu 18.04 environment with GCC.
I managed to build and run wpa_supplicant 2.9 (Termux 0.92, Android 10, Xiaomi Redmi 5A)
pkg install wget build-essential pkg-config libnl openssl
wget https://www.w1.fi/releases/wpa_supplicant-2.9.tar.gz && tar xvf wpa_supplicant-2.9.tar.gz
cd wpa_supplicant-2.9/wpa_supplicant/
cp defconfig .config
After that open .config
and comment following lines:
CONFIG_DRIVER_WEXT=y
CONFIG_CTRL_IFACE_DBUS_NEW=y
CONFIG_DEBUG_FILE=y
CONFIG_DEBUG_SYSLOG=y
make
cp wpa_supplicant wpa_cli wpa_passphrase $PREFIX/bin/
chmod +x $PREFIX/bin/wpa_*