blob: 758e38c91d6255ec2a1ff929d3006bf8589c20b2 [file] [log] [blame]
# Copyright (c) 2012 The Chromium OS Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
description "Start the bluetooth daemon"
author "chromium-os-dev@chromium.org"
start on started boot-services
stop on stopping boot-services
limit memlock unlimited unlimited
env BLUETOOTH_DAEMON_OPTION=""
env BLUETOOTH_WANT_FILE=/var/lib/bluetooth/bluetooth-daemon.current
pre-start script
# Check if we want to start bluez. If "floss" is wanted instead, exit early
# without starting bluez.
want_daemon="$(cat $BLUETOOTH_WANT_FILE)"
if [ "$want_daemon" = "floss" ]; then
exit 1
fi
end script
respawn
exec /usr/bin/start_bluetoothd.sh