2010-09-28 14:30:42 +00:00
|
|
|
SUMMARY = "A daemon for managing internet connections within embedded devices"
|
|
|
|
DESCRIPTION = "The ConnMan project provides a daemon for managing \
|
|
|
|
internet connections within embedded devices running the Linux \
|
|
|
|
operating system. The Connection Manager is designed to be slim and \
|
|
|
|
to use as few resources as possible, so it can be easily integrated. \
|
|
|
|
It is a fully modular system that can be extended, through plug-ins, \
|
|
|
|
to support all kinds of wired or wireless technologies. Also, \
|
|
|
|
configuration methods, like DHCP and domain name resolving, are \
|
|
|
|
implemented using plug-ins."
|
2010-08-26 05:37:52 +00:00
|
|
|
HOMEPAGE = "http://connman.net/"
|
|
|
|
BUGTRACKER = "http://bugs.meego.com/buglist.cgi?quicksearch=connman"
|
|
|
|
LICENSE = "GPLv2"
|
|
|
|
LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \
|
2012-06-20 11:27:20 +00:00
|
|
|
file://src/main.c;beginline=1;endline=20;md5=d6a1ac98a6791c5294e8a7f176ecd66d"
|
2009-12-03 16:15:26 +00:00
|
|
|
|
2011-12-08 18:30:52 +00:00
|
|
|
# we need to define the depends here, the dynamic stuff is too late
|
2011-12-09 18:54:02 +00:00
|
|
|
DEPENDS = "dbus glib-2.0 ppp iptables gnutls \
|
2011-12-08 18:30:52 +00:00
|
|
|
${@base_contains('DISTRO_FEATURES', 'bluetooth','bluez4', '', d)} \
|
|
|
|
${@base_contains('DISTRO_FEATURES', 'wifi','wpa-supplicant', '', d)} \
|
2012-06-07 23:37:04 +00:00
|
|
|
${@base_contains('DISTRO_FEATURES', '3g','ofono', '', d)} \
|
2011-12-08 18:30:52 +00:00
|
|
|
"
|
|
|
|
|
2012-07-11 15:39:43 +00:00
|
|
|
INC_PR = "r12"
|
2012-06-12 14:11:24 +00:00
|
|
|
|
2012-05-07 09:50:03 +00:00
|
|
|
TIST = "--enable-tist"
|
|
|
|
TIST_powerpc = ""
|
|
|
|
|
2011-12-08 18:30:52 +00:00
|
|
|
EXTRA_OECONF += "\
|
|
|
|
ac_cv_path_WPASUPPLICANT=${sbindir}/wpa_supplicant \
|
|
|
|
ac_cv_path_PPPD=${sbindir}/pppd \
|
|
|
|
--disable-gtk-doc \
|
|
|
|
--enable-debug \
|
|
|
|
--enable-threads \
|
|
|
|
--enable-loopback \
|
|
|
|
--enable-ethernet \
|
2012-05-07 09:50:03 +00:00
|
|
|
${@base_contains('DISTRO_FEATURES', 'wifi','--enable-wifi ${TIST}', '--disable-wifi', d)} \
|
|
|
|
${@base_contains('DISTRO_FEATURES', 'bluetooth','--enable-bluetooth ${TIST}', '--disable-bluetooth', d)} \
|
2012-06-07 23:37:04 +00:00
|
|
|
${@base_contains('DISTRO_FEATURES', '3g', '', '--disable-ofono', d)} \
|
2011-12-08 18:30:52 +00:00
|
|
|
--enable-tools \
|
|
|
|
--enable-test \
|
|
|
|
--disable-polkit \
|
2012-06-20 11:27:18 +00:00
|
|
|
--disable-client \
|
2011-12-08 18:30:52 +00:00
|
|
|
--enable-fake \
|
|
|
|
"
|
2009-12-03 16:15:26 +00:00
|
|
|
|
|
|
|
INITSCRIPT_NAME = "connman"
|
2010-09-28 01:47:18 +00:00
|
|
|
INITSCRIPT_PARAMS = "start 05 5 2 3 . stop 22 0 1 6 ."
|
2009-12-03 16:15:26 +00:00
|
|
|
|
2012-06-12 14:11:24 +00:00
|
|
|
# IMPORTANT: because xuser is shared with rootless X, please make sure the
|
|
|
|
# USERADD_PARAM is in sync with the one in xserver-nodm-init.bb
|
2011-10-27 14:15:36 +00:00
|
|
|
USERADD_PACKAGES = "${PN}"
|
2012-06-12 15:17:52 +00:00
|
|
|
USERADD_PARAM_${PN} = "--create-home \
|
|
|
|
--groups video,tty,audio \
|
2011-10-27 14:15:36 +00:00
|
|
|
--user-group xuser"
|
|
|
|
|
|
|
|
inherit autotools pkgconfig update-rc.d useradd
|
2009-12-03 16:15:26 +00:00
|
|
|
|
2012-06-07 23:37:05 +00:00
|
|
|
# This allows *everyone* to access ConnMan over DBus, without any access
|
|
|
|
# control. Really the at_console flag should work, which would mean that
|
|
|
|
# both this and the xuser patch can be dropped.
|
2011-12-08 18:30:52 +00:00
|
|
|
do_compile_append() {
|
|
|
|
sed -i -e s:deny:allow:g src/connman-dbus.conf
|
2009-12-03 16:15:26 +00:00
|
|
|
}
|
|
|
|
|
2011-12-08 18:30:52 +00:00
|
|
|
do_install_append() {
|
|
|
|
install -d ${D}${sysconfdir}/init.d
|
|
|
|
install -m 0755 ${WORKDIR}/connman ${D}${sysconfdir}/init.d/connman
|
2009-12-03 16:15:26 +00:00
|
|
|
|
2011-12-08 18:30:52 +00:00
|
|
|
install -d ${D}${bindir}
|
|
|
|
install -m 0755 ${S}/tools/*-test ${D}${bindir}
|
|
|
|
install -m 0755 ${S}/tools/wispr ${D}${bindir}
|
2011-12-13 10:41:14 +00:00
|
|
|
|
|
|
|
# We don't need to package an empty directory
|
|
|
|
rmdir ${D}${libdir}/connman/scripts
|
2012-07-11 15:39:43 +00:00
|
|
|
|
|
|
|
# Automake 1.12 won't install empty directories, but we need the
|
|
|
|
# plugins directory to be present for ownership
|
|
|
|
mkdir -p ${D}${libdir}/connman/plugins
|
2011-12-08 18:30:52 +00:00
|
|
|
}
|
2011-07-05 21:29:01 +00:00
|
|
|
|
2012-06-20 11:27:19 +00:00
|
|
|
# These used to be plugins, but now they are core
|
|
|
|
RPROVIDES_${PN} = "\
|
|
|
|
connman-plugin-loopback \
|
|
|
|
connman-plugin-ethernet \
|
|
|
|
${@base_contains('DISTRO_FEATURES', 'bluetooth','connman-plugin-bluetooth', '', d)} \
|
|
|
|
${@base_contains('DISTRO_FEATURES', 'wifi','connman-plugin-wifi', '', d)} \
|
|
|
|
${@base_contains('DISTRO_FEATURES', '3g','connman-plugin-ofono', '', d)} \
|
|
|
|
"
|
|
|
|
|
|
|
|
RDEPENDS_${PN} = "\
|
|
|
|
${@base_contains('DISTRO_FEATURES', 'bluetooth', 'bluez4', '', d)} \
|
|
|
|
${@base_contains('DISTRO_FEATURES', 'wifi','wpa-supplicant', '', d)} \
|
|
|
|
${@base_contains('DISTRO_FEATURES', '3g','ofono', '', d)} \
|
|
|
|
"
|
|
|
|
|
2011-12-08 18:30:52 +00:00
|
|
|
PACKAGES_DYNAMIC = "${PN}-plugin-*"
|
2011-11-04 01:40:21 +00:00
|
|
|
|
2009-12-03 16:15:26 +00:00
|
|
|
python populate_packages_prepend() {
|
2011-12-08 18:30:52 +00:00
|
|
|
depmap = dict( pppd="ppp",
|
2012-06-20 11:27:19 +00:00
|
|
|
)
|
2011-06-28 07:58:40 +00:00
|
|
|
packages = []
|
2011-12-08 18:30:52 +00:00
|
|
|
multilib_prefix = (d.getVar("MLPREFIX", True) or "")
|
2011-06-28 07:58:40 +00:00
|
|
|
hook = lambda file,pkg,b,c,d:packages.append((file,pkg))
|
2012-03-03 11:21:22 +00:00
|
|
|
plugin_dir = d.expand('${libdir}/connman/plugins/')
|
|
|
|
plugin_name = d.expand('${PN}-plugin-%s')
|
2012-07-06 11:05:42 +00:00
|
|
|
do_split_packages(d, plugin_dir, '^(.*).so$', plugin_name, '${PN} plugin for %s', extra_depends='', hook=hook, prepend=True )
|
2011-06-28 07:58:40 +00:00
|
|
|
for (file, package) in packages:
|
|
|
|
plugintype = package.split( '-' )[-1]
|
|
|
|
if plugintype in depmap:
|
2011-12-08 18:30:52 +00:00
|
|
|
rdepends = map(lambda x: multilib_prefix + x, depmap[plugintype].split())
|
|
|
|
bb.note( "Adding rdependency on %s to %s" % ( rdepends, package ) )
|
|
|
|
d.setVar("RDEPENDS_%s" % package, " ".join(rdepends))
|
2010-08-26 05:37:52 +00:00
|
|
|
}
|
2011-12-08 18:30:52 +00:00
|
|
|
|
2011-12-13 10:41:14 +00:00
|
|
|
PACKAGES =+ "${PN}-tools ${PN}-tests"
|
2011-12-08 18:30:52 +00:00
|
|
|
|
|
|
|
FILES_${PN}-tools = "${bindir}/wispr"
|
|
|
|
|
2012-04-05 11:43:28 +00:00
|
|
|
FILES_${PN}-tests = "${bindir}/*-test ${libdir}/${BPN}/test/*"
|
2011-12-13 10:41:14 +00:00
|
|
|
RDEPENDS_${PN}-tests = "python-dbus"
|
2011-12-08 18:30:52 +00:00
|
|
|
|
|
|
|
FILES_${PN} = "${bindir}/* ${sbindir}/* ${libexecdir}/* ${libdir}/lib*.so.* \
|
2012-07-06 11:05:42 +00:00
|
|
|
${libdir}/connman/plugins \
|
2011-12-08 18:30:52 +00:00
|
|
|
${sysconfdir} ${sharedstatedir} ${localstatedir} \
|
|
|
|
${base_bindir}/* ${base_sbindir}/* ${base_libdir}/*.so* ${datadir}/${PN} \
|
|
|
|
${datadir}/dbus-1/system-services/*"
|
|
|
|
|
|
|
|
FILES_${PN}-dbg += "${libdir}/connman/*/.debug"
|
|
|
|
|
|
|
|
FILES_${PN}-dev += "${libdir}/connman/*/*.la"
|