2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
15 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_NAME
)-$(PKG_VERSION
)
16 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
17 PKG_SOURCE_URL
:=http
://bluez.sourceforge.net
/download
21 PKG_INSTALL_DIR
:=$(PKG_BUILD_DIR
)/ipkg-install
23 include $(INCLUDE_DIR
)/package.mk
25 define Package
/bluez-utils
28 DEPENDS
:=+bluez-libs
+libpthread
29 TITLE
:=Bluetooth utilities
30 DESCRIPTION
:=Bluetooth utilities.
31 URL
:=http
://www.bluez.org
/
34 define Package
/bluez-utils
/conffiles
35 /etc
/bluetooth
/givepin
36 /etc
/bluetooth
/hcid.conf
37 /etc
/bluetooth
/rfcomm.conf
40 define Build
/Configure
41 (cd
$(PKG_BUILD_DIR
); rm -f config.cache
; \
42 $(TARGET_CONFIGURE_OPTS
) \
43 CFLAGS
="$(TARGET_CFLAGS)" \
44 CPPFLAGS
="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
45 LDFLAGS
="-L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
47 --target
=$(GNU_TARGET_NAME
) \
48 --host
=$(GNU_TARGET_NAME
) \
49 --build
=$(GNU_HOST_NAME
) \
55 --datadir=/usr
/share \
56 --includedir=/usr
/include \
57 --infodir=/usr
/share
/info \
59 --libexecdir
=/usr
/lib \
60 --localstatedir
=/var \
61 --mandir=/usr
/share
/man \
64 $(DISABLE_LARGEFILE
) \
75 --disable-initscripts \
82 --with-bluez
=$(STAGING_DIR
)/usr
/include \
83 --with-usb
=$(STAGING_DIR
)/usr
/include \
88 rm -rf
$(PKG_INSTALL_DIR
)
89 mkdir
-p
$(PKG_INSTALL_DIR
)
90 $(MAKE
) -C
$(PKG_BUILD_DIR
) \
91 DESTDIR
="$(PKG_INSTALL_DIR)" \
95 define Package
/bluez-utils
/install
96 install -d
-m0755
$(1)/usr
/bin
97 $(CP
) $(PKG_INSTALL_DIR
)/usr
/bin
/* $(1)/usr
/bin
/
98 install -d
-m0755
$(1)/usr
/sbin
99 $(CP
) $(PKG_INSTALL_DIR
)/usr
/sbin
/* $(1)/usr
/sbin
/
100 install -d
-m0755
$(1)/etc
/bluetooth
101 $(CP
) $(PKG_INSTALL_DIR
)/..
/hcid
/hcid.conf
$(1)/etc
/bluetooth
/
102 $(CP
) $(PKG_INSTALL_DIR
)/..
/rfcomm
/rfcomm.conf
$(1)/etc
/bluetooth
/
103 install -m0700 .
/files
/givepin
$(1)/etc
/bluetooth
/
106 $(eval
$(call BuildPackage
,bluez-utils
))