hey again

i've cleaned up the bluez-util make file. the size of the ipk file is still arround 250kb.

about the --disable-all parameter, i guess this will leave bluez utils rather useless, as i think sdpd, hcid is needed.

perhaps i could split the package up and remove the hciconfig binary to a seperate package - the binary is 100k uncompressed and the bluez util would shrink to 210kb. what do you think?

i think it better to use (or waste..) 250kb of diskspace for a working bluetooth package, instead to waste 150kb diskspace for a non working bluetooth package.

as soon as this bluetooth package is commited, ill release bemusedserver - this is a bluetooth app, which connects to the mpd musicplayer. with this app and a java client on your mobile phone, you would be able to controll your mpd with you mobile phone...

cheers
michu

Signed-off-by: Michael Vogt <michu at neophob.com>

I've fixed the dbus ticket and committed all the bluez updates in my local repo, but I'm reluctant to commit the entire set of changes to the OpenWrt svn as the size of the bluez-utils package is jumping from ~140k to ~250k. I've been playing with the configure opts and can drop the size down to ~110k by passing --disable-all, but haven't figured out exactly which "extra" options are causing the massive size increase.

If there are major improvements between 2.24 and 3.24 -- or the modified configure args -- that warrant the extra size increase I'll commit the changesets, otherwise I wonder if staying up to date is worth the potential bloat.

-Andy

_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
http://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel



Index: package/utils/bluez-utils/files/bluez-utils.init
===================================================================
--- package/utils/bluez-utils/files/bluez-utils.init	(revision 10204)
+++ package/utils/bluez-utils/files/bluez-utils.init	(working copy)
@@ -1,7 +1,8 @@
 #!/bin/sh /etc/rc.common
 # Copyright (C) 2007 OpenWrt.org
 
-START=60
+#start after dbus (60)
+START=62
 
 append_bool() {
 	local section="$1"
@@ -107,6 +108,16 @@
 	config_foreach rfcomm_config rfcomm
 	config_foreach dund_config dund
 	config_foreach pand_config pand
+	
+        #start passkey agent with default pin 1234
+        passkey-agent --default 1234&
+
+        hcitool hci0 up
+        rfcomm release 0
+
+        #set up serial conenction
+        #rfcomm connect /dev/rfcomm0 00:11:22:33:44:55&
+
 }
 
 stop() {
Index: package/utils/bluez-utils/patches/100-enokey1.patch
===================================================================
--- package/utils/bluez-utils/patches/100-enokey1.patch	(revision 0)
+++ package/utils/bluez-utils/patches/100-enokey1.patch	(revision 0)
@@ -0,0 +1,11 @@
+--- bluez-utils-3.24/input/device.orig	2007-12-08 20:04:42.000000000 +0100
++++ bluez-utils-3.24/input/device.c	2008-01-16 09:20:41.000000000 +0100
+@@ -25,6 +25,8 @@
+ #include <config.h>
+ #endif
+ 
++#define ENOKEY          161     /* Required key not available */
++
+ #include <stdlib.h>
+ #include <errno.h>
+ #include <fcntl.h>
Index: package/utils/bluez-utils/patches/101-enokey1.patch
===================================================================
--- package/utils/bluez-utils/patches/101-enokey1.patch	(revision 0)
+++ package/utils/bluez-utils/patches/101-enokey1.patch	(revision 0)
@@ -0,0 +1,11 @@
+--- bluez-utils-3.24/input/storage.orig	2007-10-05 09:17:06.000000000 +0200
++++ bluez-utils-3.24/input/storage.c	2008-01-16 09:26:23.000000000 +0100
+@@ -25,6 +25,8 @@
+ #include <config.h>
+ #endif
+ 
++#define ENOKEY          161     /* Required key not available */
++
+ #include <stdio.h>
+ #include <errno.h>
+ #include <ctype.h>
Index: package/utils/bluez-utils/Makefile
===================================================================
--- package/utils/bluez-utils/Makefile	(revision 10204)
+++ package/utils/bluez-utils/Makefile	(working copy)
@@ -9,12 +9,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=bluez-utils
-PKG_VERSION:=2.24
-PKG_RELEASE:=3
+PKG_VERSION:=3.24
+PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=http://bluez.sourceforge.net/download
-PKG_MD5SUM:=5f5488ff3d31bdb9cd36b7991fe68408
+PKG_MD5SUM:=cc3582da827bc4c468147af1afaa5aff
 
 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
@@ -24,35 +24,25 @@
 define Package/bluez-utils
   SECTION:=utils
   CATEGORY:=Utilities
-  DEPENDS:=+bluez-libs +libpthread
+  DEPENDS:=+bluez-libs +libpthread +dbus
   TITLE:=Bluetooth utilities
   URL:=http://www.bluez.org/
 endef
 
 define Package/bluez-utils/conffiles
-/etc/bluetooth/givepin
 /etc/bluetooth/hcid.conf
 /etc/bluetooth/rfcomm.conf
 /etc/config/bluetooth
 endef
 
+
 define Build/Configure
 	$(call Build/Configure/Default, \
-		--disable-dbus \
-		--disable-fuse \
-		--disable-obex \
-		--disable-alsa \
-		--disable-cups \
-		--disable-pcmcia \
-		--disable-initscripts \
-		--disable-bccmd \
-		--disable-avctrl \
-		--disable-hid2hci \
-		--disable-dfutool \
-		--disable-bcm203x \
-		--disable-bluepin \
+		--enable-debug \
+		--enable-usb \
+		--enable-input \
+		--enable-serial \
 		--with-bluez="$(STAGING_DIR)/usr/include" \
-		--with-usb=no \
 	)
 endef
 
@@ -67,12 +57,14 @@
 	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
 	$(INSTALL_DIR) $(1)/usr/sbin
 	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/* $(1)/usr/sbin/
+	$(INSTALL_BIN) $(PKG_INSTALL_DIR)/../daemon/passkey-agent $(1)/usr/sbin/	
 	$(INSTALL_DIR) $(1)/etc/bluetooth
 	$(CP) $(PKG_INSTALL_DIR)/../hcid/hcid.conf $(1)/etc/bluetooth/
 	$(CP) $(PKG_INSTALL_DIR)/../rfcomm/rfcomm.conf $(1)/etc/bluetooth/
-	install -m0700 ./files/givepin $(1)/etc/bluetooth/
 	$(INSTALL_DIR) $(1)/etc/config
-	$(INSTALL_DATA) ./files/bluetooth.conf $(1)/etc/config/bluetooth
+	$(INSTALL_DATA) ./files/bluetooth.conf $(1)/etc/config/bluetooth	
+	$(INSTALL_DIR) $(1)/etc/dbus-1/system.d/
+	$(INSTALL_DATA) $(PKG_INSTALL_DIR)/../daemon/bluetooth.conf $(1)/etc/dbus-1/system.d/
 	$(INSTALL_DIR) $(1)/etc/init.d
 	$(INSTALL_BIN) ./files/bluez-utils.init $(1)/etc/init.d/bluez-utils
 endef
_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
http://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel

Reply via email to