[PATCH 1/1] build: static libwpa_client supported

Konstantin Menyaev viper at landau.one
Sun Aug 9 02:33:49 PDT 2026


On 8/1/26 21:39, viper at landau.one wrote:
> From: Konstantin Menyaev <viper at landau.one>
> 
> CONFIG_BUILD_WPA_CLIENT_STATIC option added to build the static
> libwpa_client library.
> 
> This is useful for applications that statically link against the
> wpa_supplicant client API.
> 
> Signed-off-by: Konstantin Menyaev <viper at landau.one>
> ---
>   wpa_supplicant/Makefile | 10 ++++++++++
>   1 file changed, 10 insertions(+)
> 
> diff --git a/wpa_supplicant/Makefile b/wpa_supplicant/Makefile
> index 2b82c42c8..4ab7ae512 100644
> --- a/wpa_supplicant/Makefile
> +++ b/wpa_supplicant/Makefile
> @@ -24,6 +24,12 @@ ifdef CONFIG_BUILD_WPA_CLIENT_SO
>   _all: libwpa_client.so
>   endif
>   
> +ifdef CONFIG_BUILD_WPA_CLIENT_STATIC
> +# add the dependency this way to allow CONFIG_BUILD_WPA_CLIENT_STATIC
> +# being set in the config which is read by build.rules
> +_all: libwpa_client.a
> +endif
> +
>   ifndef CONFIG_NO_WPA_PASSPHRASE
>   # add the dependency this way to allow CONFIG_NO_WPA_PASSPHRASE
>   # being set in the config which is read by build.rules
> @@ -91,6 +97,10 @@ endif
>   ifdef CONFIG_BUILD_WPA_CLIENT_SO
>   	install -m 0644 -D libwpa_client.so $(DESTDIR)/$(LIBDIR)/libwpa_client.so
>   	install -m 0644 -D ../src/common/wpa_ctrl.h $(DESTDIR)/$(INCDIR)/wpa_ctrl.h
> +endif
> +ifdef CONFIG_BUILD_WPA_CLIENT_STATIC
> +	install -m 0644 -D libwpa_client.a $(DESTDIR)/$(LIBDIR)/libwpa_client.a
> +	install -m 0644 -D ../src/common/wpa_ctrl.h $(DESTDIR)/$(INCDIR)/wpa_ctrl.h
>   endif
>   	if ls eap_*.so >/dev/null 2>&1; then \
>   		install -d $(DESTDIR)$(LIBDIR)/wpa_supplicant && \

kindly remind



More information about the Hostap mailing list