2 # Copyright (C) 2006-2011 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR)/rules.mk
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://bluez.sourceforge.net/download
16 PKG_MD5SUM:=4fc292b635ba7b442c7aaf5680199012
20 include $(INCLUDE_DIR)/package.mk
21 include $(INCLUDE_DIR)/nls.mk
23 define Package/bluez-utils
26 DEPENDS:=+bluez-libs +libpthread +dbus $(INTL_DEPENDS) $(ICONV_DEPENDS)
27 TITLE:=Bluetooth utilities
28 URL:=http://www.bluez.org/
31 define Package/bluez-utils/conffiles
32 /etc/bluetooth/hcid.conf
33 /etc/bluetooth/rfcomm.conf
47 --with-bluez="$(STAGING_DIR)/usr/include" \
51 $(MAKE) -C $(PKG_BUILD_DIR) \
52 LDFLAGS="$(TARGET_LDFLAGS) \
53 -L$(ICONV_PREFIX)/lib \
54 -L$(INTL_PREFIX)/lib -lm" \
55 DESTDIR="$(PKG_INSTALL_DIR)" \
59 define Package/bluez-utils/install
60 $(INSTALL_DIR) $(1)/usr/bin
61 $(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
62 $(INSTALL_DIR) $(1)/usr/sbin
63 $(CP) $(PKG_INSTALL_DIR)/usr/sbin/* $(1)/usr/sbin/
64 $(INSTALL_DIR) $(1)/etc/bluetooth
65 $(CP) $(PKG_INSTALL_DIR)/etc/bluetooth/hcid.conf $(1)/etc/bluetooth/
66 $(CP) $(PKG_INSTALL_DIR)/etc/bluetooth/rfcomm.conf $(1)/etc/bluetooth/
67 $(INSTALL_DIR) $(1)/etc/config
68 $(INSTALL_DATA) ./files/bluetooth.config $(1)/etc/config/bluetooth
69 $(INSTALL_DIR) $(1)/etc/dbus-1/system.d/
70 $(INSTALL_DATA) ./files/bluetooth.dbus $(1)/etc/dbus-1/system.d/bluetooth.conf
71 $(INSTALL_DIR) $(1)/etc/init.d
72 $(INSTALL_BIN) ./files/bluez-utils.init $(1)/etc/init.d/bluez-utils
75 $(eval $(call BuildPackage,bluez-utils))