From: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
To: buildroot@buildroot.org
Subject: [Buildroot] [git commit branch/next] package/bluez5_utils: make tools optional
Date: Mon, 2 Aug 2021 17:06:51 +0200 [thread overview]
Message-ID: <20210803211027.67BC7878C2@busybox.osuosl.org> (raw)
commit: https://git.buildroot.net/buildroot/commit/?id=2245000fed43a53f35b8348441a7814d309adbdc
branch: https://git.buildroot.net/buildroot/commit/?id=refs/heads/next
The tools are currently always build and installed. In many cases
those tools are not needed in a production system. So make this
step optional. This saves up to 2MB on the target.
Further tweak the deprecated option. It has effects when the --enable-tools
is set as well as when --enable-client is set. So explain this in the
options description and update the install step for gatttool to only be
added when client is enabled.
Signed-off-by: Michael Nosthoff <buildroot@heine.tech>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
---
package/bluez5_utils/Config.in | 16 +++++++++++++---
package/bluez5_utils/bluez5_utils.mk | 13 +++++++++++--
2 files changed, 24 insertions(+), 5 deletions(-)
diff --git a/package/bluez5_utils/Config.in b/package/bluez5_utils/Config.in
index 40973e13cd..30e70fa03f 100644
--- a/package/bluez5_utils/Config.in
+++ b/package/bluez5_utils/Config.in
@@ -43,13 +43,23 @@ config BR2_PACKAGE_BLUEZ5_UTILS_MONITOR
help
Build monitor utility btmon.
+config BR2_PACKAGE_BLUEZ5_UTILS_TOOLS
+ bool "build tools"
+ help
+ Build tools like bluemoon, btattach, hex2hcd, l2test,
+ l2ping, mpris-proxy, rctest.
+
config BR2_PACKAGE_BLUEZ5_UTILS_DEPRECATED
bool "install deprecated tools"
- depends on BR2_PACKAGE_BLUEZ5_UTILS_CLIENT
+ depends on BR2_PACKAGE_BLUEZ5_UTILS_CLIENT || BR2_PACKAGE_BLUEZ5_UTILS_TOOLS
help
- Build deprecated tools. These currently include:
+ Build deprecated tools.
+
+ When "build tools" is selected these tools are installed:
hciattach, hciconfig, hcitool, hcidump, rfcomm, sdptool,
- ciptool, gatttool.
+ ciptool.
+
+ When CLI client is enabled "gatttool" is installed.
config BR2_PACKAGE_BLUEZ5_UTILS_EXPERIMENTAL
bool "build experimental tools"
diff --git a/package/bluez5_utils/bluez5_utils.mk b/package/bluez5_utils/bluez5_utils.mk
index 3551b14a69..5f5a7f44c9 100644
--- a/package/bluez5_utils/bluez5_utils.mk
+++ b/package/bluez5_utils/bluez5_utils.mk
@@ -20,7 +20,6 @@ BLUEZ5_UTILS_DEPENDENCIES = \
libglib2
BLUEZ5_UTILS_CONF_OPTS = \
- --enable-tools \
--enable-library \
--disable-cups \
--disable-manpages \
@@ -46,6 +45,12 @@ else
BLUEZ5_UTILS_CONF_OPTS += --disable-monitor
endif
+ifeq ($(BR2_PACKAGE_BLUEZ5_UTILS_TOOLS),y)
+BLUEZ5_UTILS_CONF_OPTS += --enable-tools
+else
+BLUEZ5_UTILS_CONF_OPTS += --disable-tools
+endif
+
# experimental plugins
ifeq ($(BR2_PACKAGE_BLUEZ5_UTILS_EXPERIMENTAL),y)
BLUEZ5_UTILS_CONF_OPTS += --enable-experimental
@@ -125,12 +130,16 @@ else
BLUEZ5_UTILS_CONF_OPTS += --disable-sixaxis
endif
-# install gatttool (For some reason upstream choose not to do it by default)
ifeq ($(BR2_PACKAGE_BLUEZ5_UTILS_DEPRECATED),y)
+# install gatttool (For some reason upstream choose not to do it by default)
+# gattool depends on the client for readline
+ifeq ($(BR2_PACKAGE_BLUEZ5_UTILS_CLIENT),y)
define BLUEZ5_UTILS_INSTALL_GATTTOOL
$(INSTALL) -D -m 0755 $(@D)/attrib/gatttool $(TARGET_DIR)/usr/bin/gatttool
endef
BLUEZ5_UTILS_POST_INSTALL_TARGET_HOOKS += BLUEZ5_UTILS_INSTALL_GATTTOOL
+endif
+
# hciattach_bcm43xx defines default firmware path in `/etc/firmware`, but
# Broadcom firmware blobs are usually located in `/lib/firmware`.
BLUEZ5_UTILS_CONF_ENV += \
_______________________________________________
buildroot mailing list
buildroot@busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
reply other threads:[~2021-08-04 1:12 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210803211027.67BC7878C2@busybox.osuosl.org \
--to=arnout@mind.be \
--cc=buildroot@buildroot.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.