From patchwork Tue Sep 25 12:55:22 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sven Neumann X-Patchwork-Id: 186801 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ozlabs.org (Postfix) with ESMTP id 5E4082C0080 for ; Tue, 25 Sep 2012 22:56:08 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 467948BD94; Tue, 25 Sep 2012 12:56:05 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id IkztXHR-jDSB; Tue, 25 Sep 2012 12:56:00 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id 2D2C88BBB6; Tue, 25 Sep 2012 12:55:58 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id DB3598F782 for ; Tue, 25 Sep 2012 12:55:39 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id E39CA8BBB6 for ; Tue, 25 Sep 2012 12:55:37 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aUDFQdu8lVhr for ; Tue, 25 Sep 2012 12:55:36 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from mail.zonque.de (svenfoo.org [82.94.215.22]) by whitealder.osuosl.org (Postfix) with ESMTPS id 135528BB06 for ; Tue, 25 Sep 2012 12:55:36 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail.zonque.de (Postfix) with ESMTP id 5836FC0221; Tue, 25 Sep 2012 14:55:33 +0200 (CEST) Received: from mail.zonque.de ([127.0.0.1]) by localhost (rambrand.bugwerft.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id mhpd8G0J3YKx; Tue, 25 Sep 2012 14:55:33 +0200 (CEST) Received: from localhost.localdomain (port-87-234-241-131.static.qsc.de [87.234.241.131]) (using TLSv1.1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.zonque.de (Postfix) with ESMTPSA id A9B0BC0220; Tue, 25 Sep 2012 14:55:32 +0200 (CEST) From: Sven Neumann To: buildroot@busybox.net Date: Tue, 25 Sep 2012 14:55:22 +0200 Message-Id: <1348577725-12647-2-git-send-email-s.neumann@raumfeld.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1348577725-12647-1-git-send-email-s.neumann@raumfeld.com> References: <1348577725-12647-1-git-send-email-s.neumann@raumfeld.com> Subject: [Buildroot] [PATCH 1/4] wpa-supplicant: add options to enable the new DBus interface X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net Allow to configure the DBus interfaces that the wpa_supplicant binary should support (old or new or both). Also allow to enable introspection support on the new DBus interface. Signed-off-by: Sven Neumann Acked-by: Arnout Vandecappelle (Essensium/Mind) --- package/wpa_supplicant/Config.in | 19 ++++++++++++++ package/wpa_supplicant/wpa_supplicant.mk | 42 ++++++++++++++++++++++++++---- 2 files changed, 56 insertions(+), 5 deletions(-) diff --git a/package/wpa_supplicant/Config.in b/package/wpa_supplicant/Config.in index d7cefe3..8b0b366 100644 --- a/package/wpa_supplicant/Config.in +++ b/package/wpa_supplicant/Config.in @@ -30,6 +30,25 @@ config BR2_PACKAGE_WPA_SUPPLICANT_AP_SUPPORT (optionally, with WPS); this links in parts of hostapd functionality into wpa_supplicant. +config BR2_PACKAGE_WPA_SUPPLICANT_DBUS_OLD + bool "Enable support for old DBus control interface" + depends on BR2_PACKAGE_DBUS + help + Enable support for old DBus control interface + (fi.epitest.hostap.WPASupplicant). + +config BR2_PACKAGE_WPA_SUPPLICANT_DBUS_NEW + bool "Enable support for new DBus control interface" + depends on BR2_PACKAGE_DBUS + help + Enable support for new DBus control interface (fi.w1.wpa_supplicant1). + +config BR2_PACKAGE_WPA_SUPPLICANT_DBUS_INTROSPECTION + bool "Introspection support" + depends on BR2_PACKAGE_WPA_SUPPLICANT_DBUS_NEW + help + Add introspection support for new DBus control interface. + config BR2_PACKAGE_WPA_SUPPLICANT_WPS bool "Enable support for WPS" help diff --git a/package/wpa_supplicant/wpa_supplicant.mk b/package/wpa_supplicant/wpa_supplicant.mk index d8c916b..207eec1 100644 --- a/package/wpa_supplicant/wpa_supplicant.mk +++ b/package/wpa_supplicant/wpa_supplicant.mk @@ -10,7 +10,8 @@ WPA_SUPPLICANT_LICENSE = GPLv2/BSD-3c WPA_SUPPLICANT_LICENSE_FILES = README WPA_SUPPLICANT_CONFIG = $(WPA_SUPPLICANT_DIR)/wpa_supplicant/.config WPA_SUPPLICANT_SUBDIR = wpa_supplicant -WPA_SUPPLICANT_DBUS_SERVICE = fi.epitest.hostap.WPASupplicant +WPA_SUPPLICANT_DBUS_OLD_SERVICE = fi.epitest.hostap.WPASupplicant +WPA_SUPPLICANT_DBUS_NEW_SERVICE = fi.w1.wpa_supplicant1 WPA_SUPPLICANT_CFLAGS = $(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include/libnl3/ WPA_SUPPLICANT_LDFLAGS = $(TARGET_LDFLAGS) @@ -84,9 +85,41 @@ ifeq ($(BR2_PACKAGE_DBUS),y) WPA_SUPPLICANT_MAKE_ENV = \ PKG_CONFIG_SYSROOT_DIR="$(STAGING_DIR)" \ PKG_CONFIG_PATH="$(STAGING_DIR)/usr/lib/pkgconfig" -define WPA_SUPPLICANT_DBUS_CONFIG + +ifeq ($(BR2_PACKAGE_WPA_SUPPLICANT_DBUS_OLD),y) +define WPA_SUPPLICANT_DBUS_OLD_CONFIG $(SED) 's/\(#\)\(CONFIG_CTRL_IFACE_DBUS=\)/\2/' $(WPA_SUPPLICANT_CONFIG) endef +define WPA_SUPPLICANT_INSTALL_DBUS_OLD + $(INSTALL) -D \ + $(@D)/wpa_supplicant/dbus/$(WPA_SUPPLICANT_DBUS_OLD_SERVICE).service \ + $(TARGET_DIR)/usr/share/dbus-1/system-services/$(WPA_SUPPLICANT_DBUS_OLD_SERVICE).service +endef +endif + +ifeq ($(BR2_PACKAGE_WPA_SUPPLICANT_DBUS_NEW),y) +define WPA_SUPPLICANT_DBUS_NEW_CONFIG + $(SED) 's/\(#\)\(CONFIG_CTRL_IFACE_DBUS_NEW=\)/\2/' $(WPA_SUPPLICANT_CONFIG) +endef +define WPA_SUPPLICANT_INSTALL_DBUS_NEW + $(INSTALL) -D \ + $(@D)/wpa_supplicant/dbus/$(WPA_SUPPLICANT_DBUS_NEW_SERVICE).service \ + $(TARGET_DIR)/usr/share/dbus-1/system-services/$(WPA_SUPPLICANT_DBUS_NEW_SERVICE).service +endef +endif + +ifeq ($(BR2_PACKAGE_WPA_SUPPLICANT_DBUS_INTROSPECTION),y) +define WPA_SUPPLICANT_DBUS_INTROSPECTION_CONFIG + $(SED) 's/\(#\)\(CONFIG_CTRL_IFACE_DBUS_INTRO=\)/\2/' $(WPA_SUPPLICANT_CONFIG) +endef +endif + +define WPA_SUPPLICANT_DBUS_CONFIG + $(WPA_SUPPLICANT_DBUS_OLD_CONFIG) + $(WPA_SUPPLICANT_DBUS_NEW_CONFIG) + $(WPA_SUPPLICANT_DBUS_INTROSPECTION_CONFIG) +endef + endif define WPA_SUPPLICANT_CONFIGURE_CMDS @@ -131,9 +164,8 @@ define WPA_SUPPLICANT_INSTALL_DBUS $(INSTALL) -D \ $(@D)/wpa_supplicant/dbus/dbus-wpa_supplicant.conf \ $(TARGET_DIR)/etc/dbus-1/system.d/wpa_supplicant.conf - $(INSTALL) -D \ - $(@D)/wpa_supplicant/dbus/$(WPA_SUPPLICANT_DBUS_SERVICE).service \ - $(TARGET_DIR)/usr/share/dbus-1/system-services/$(WPA_SUPPLICANT_DBUS_SERVICE).service + $(WPA_SUPPLICANT_INSTALL_DBUS_OLD) + $(WPA_SUPPLICANT_INSTALL_DBUS_NEW) endef endif