[blfs-book] r10385 - in trunk: BOOK BOOK/introduction/welcome bootscripts bootscripts/blfs/init.d bootscripts/blfs/sysconfig

krejzi at linuxfromscratch.org krejzi at linuxfromscratch.org
Sun Jul 1 15:14:59 PDT 2012


Author: krejzi
Date: 2012-07-01 16:14:55 -0600 (Sun, 01 Jul 2012)
New Revision: 10385

Added:
   trunk/bootscripts/blfs/init.d/bluetooth
   trunk/bootscripts/blfs/sysconfig/bluetooth
Modified:
   trunk/BOOK/general.ent
   trunk/BOOK/introduction/welcome/changelog.xml
   trunk/bootscripts/ChangeLog
   trunk/bootscripts/Makefile
Log:
BlueZ bootscript.

Modified: trunk/BOOK/general.ent
===================================================================
--- trunk/BOOK/general.ent	2012-07-01 19:48:58 UTC (rev 10384)
+++ trunk/BOOK/general.ent	2012-07-01 22:14:55 UTC (rev 10385)
@@ -3,13 +3,13 @@
 $Date$
 -->
 
-<!ENTITY day          "01">                   <!-- Always 2 digits -->
+<!ENTITY day          "02">                   <!-- Always 2 digits -->
 <!ENTITY month        "07">                   <!-- Always 2 digits -->
 <!ENTITY year         "2012">
 <!ENTITY copyrightdate "2001-&year;">
 <!ENTITY copyholder   "The BLFS Development Team">
 <!ENTITY version      "&year;-&month;-&day;">
-<!ENTITY releasedate  "July 1st, &year;">
+<!ENTITY releasedate  "July 2st, &year;">
 <!-- <!ENTITY releasedate  "November &day;st, &year;"> -->
 <!ENTITY pubdate      "&year;-&month;-&day;"> <!-- metadata req. by TLDP -->
 <!ENTITY blfs-version "svn">                  <!-- svn|[release #] -->
@@ -59,7 +59,7 @@
 <!ENTITY lfs-vim-version              "7.3">
 <!-- End LFS versions -->
 
-<!ENTITY blfs-bootscripts-version     "20120620">
+<!ENTITY blfs-bootscripts-version     "20120702">
 <!ENTITY blfs-bootscripts-download    "&downloads-root;/blfs-bootscripts-&blfs-bootscripts-version;.tar.bz2">
 
 <!ENTITY blfs-wiki                    "http://wiki.&lfs-domainname;/blfs/wiki">

Modified: trunk/BOOK/introduction/welcome/changelog.xml
===================================================================
--- trunk/BOOK/introduction/welcome/changelog.xml	2012-07-01 19:48:58 UTC (rev 10384)
+++ trunk/BOOK/introduction/welcome/changelog.xml	2012-07-01 22:14:55 UTC (rev 10385)
@@ -42,6 +42,15 @@
 
 -->
     <listitem>
+      <para>July 2nd, 2012</para>
+      <itemizedlist>
+        <listitem>
+          <para>[krejzi] - Bump bootscripts to 20120702 for BlueZ addition.</para>
+        </listitem>
+      </itemizedlist>
+    </listitem>
+
+    <listitem>
       <para>July 1st, 2012</para>
       <itemizedlist>
 	<listitem>

Modified: trunk/bootscripts/ChangeLog
===================================================================
--- trunk/bootscripts/ChangeLog	2012-07-01 19:48:58 UTC (rev 10384)
+++ trunk/bootscripts/ChangeLog	2012-07-01 22:14:55 UTC (rev 10385)
@@ -1,3 +1,6 @@
+2012-06-02 Armin K. <krejzi at email.com>
+   * Added BlueZ bootscript
+
 2012-06-17 DJ Lucas <dj at linuxfromscratch.org>
    * Fix sshd return value when stopping without running.
 

Modified: trunk/bootscripts/Makefile
===================================================================
--- trunk/bootscripts/Makefile	2012-07-01 19:48:58 UTC (rev 10384)
+++ trunk/bootscripts/Makefile	2012-07-01 22:14:55 UTC (rev 10385)
@@ -86,6 +86,17 @@
 	ln -sf  ../init.d/bind ${EXTDIR}/rc.d/rc5.d/S22bind
 	ln -sf  ../init.d/bind ${EXTDIR}/rc.d/rc6.d/K49bind
 
+install-bluetooth: create-dirs
+	install -m ${MODE} blfs/init.d/bluetooth ${EXTDIR}/rc.d/init.d/bluetooth
+	install -m ${CONFMODE} blfs/sysconfig/bluetooth ${EXTDIR}/sysconfig/bluetooth
+	ln -sf  ../init.d/bluetooth ${EXTDIR}/rc.d/rc0.d/K27bluetooth
+	ln -sf  ../init.d/bluetooth ${EXTDIR}/rc.d/rc1.d/K27bluetooth
+	ln -sf  ../init.d/bluetooth ${EXTDIR}/rc.d/rc2.d/S35bluetooth
+	ln -sf  ../init.d/bluetooth ${EXTDIR}/rc.d/rc3.d/S35bluetooth
+	ln -sf  ../init.d/bluetooth ${EXTDIR}/rc.d/rc4.d/S35bluetooth
+	ln -sf  ../init.d/bluetooth ${EXTDIR}/rc.d/rc5.d/S35bluetooth
+	ln -sf  ../init.d/bluetooth ${EXTDIR}/rc.d/rc6.d/K27bluetooth
+
 install-cups: create-dirs
 	install -m ${MODE} blfs/init.d/cups       ${EXTDIR}/rc.d/init.d/
 	rm -f ${EXTDIR}/rc.d/rc0.d/K36cups
@@ -104,8 +115,8 @@
 	ln -sf  ../init.d/cups ${EXTDIR}/rc.d/rc6.d/K00cups
 
 install-cyrus-sasl: create-dirs
-	install -m ${MODE} blfs/init.d/cyrus-sasl ${EXTDIR}/rc.d/init.d/
-	install -m ${CONFMODE} blfs/sysconfig/cyrus-sasl ${EXTDIR}/sysconfig/
+	install -m ${MODE} blfs/init.d/cyrus-sasl ${EXTDIR}/rc.d/init.d/cyrus-sasl
+	install -m ${CONFMODE} blfs/sysconfig/cyrus-sasl ${EXTDIR}/sysconfig/cyrus-sasl
 	ln -sf  ../init.d/cyrus-sasl ${EXTDIR}/rc.d/rc0.d/K49cyrus-sasl
 	ln -sf  ../init.d/cyrus-sasl ${EXTDIR}/rc.d/rc1.d/K49cyrus-sasl
 	ln -sf  ../init.d/cyrus-sasl ${EXTDIR}/rc.d/rc2.d/S24cyrus-sasl
@@ -241,7 +252,7 @@
 	ln -sf  ../init.d/netfs ${EXTDIR}/rc.d/rc6.d/K47netfs
 
 install-networkmanager: create-dirs
-	install -m ${MODE} blfs/init.d/networkmanager ${EXTDIR}/rc.d/init.d/
+	install -m ${MODE} blfs/init.d/networkmanager ${EXTDIR}/rc.d/init.d/networkmanager
 	ln -sf  ../init.d/networkmanager ${EXTDIR}/rc.d/rc0.d/K28networkmanager
 	ln -sf  ../init.d/networkmanager ${EXTDIR}/rc.d/rc1.d/K28networkmanager
 	ln -sf  ../init.d/networkmanager ${EXTDIR}/rc.d/rc2.d/S33networkmanager
@@ -282,10 +293,10 @@
 
 install-openldap: create-dirs
 	install -m ${MODE} blfs/init.d/openldap ${EXTDIR}/rc.d/init.d/openldap
-	install -m ${CONFMODE} blfs/sysconfig/openldap ${EXTDIR}/sysconfig/
+	install -m ${CONFMODE} blfs/sysconfig/openldap ${EXTDIR}/sysconfig/openldap
 	ln -sf  ../init.d/openldap ${EXTDIR}/rc.d/rc0.d/K46openldap
 	ln -sf  ../init.d/openldap ${EXTDIR}/rc.d/rc1.d/K46openldap
-	ln -sf  ../init.d/openldap ${EXTDIR}/rc.d/rc2.d/K46openldap
+	ln -sf  ../init.d/openldap ${EXTDIR}/rc.d/rc2.d/S25openldap
 	ln -sf  ../init.d/openldap ${EXTDIR}/rc.d/rc3.d/S25openldap
 	ln -sf  ../init.d/openldap ${EXTDIR}/rc.d/rc4.d/S25openldap
 	ln -sf  ../init.d/openldap ${EXTDIR}/rc.d/rc5.d/S25openldap
@@ -505,6 +516,17 @@
 	rm -f ${EXTDIR}/rc.d/rc5.d/S22bind
 	rm -f ${EXTDIR}/rc.d/rc6.d/K49bind
 
+uninstall-bluetooth:
+	rm -f ${EXTDIR}/rc.d/init.d/bluetooth
+	rm -f ${EXTDIR}/sysconfig/bluetooth
+	rm -f ${EXTDIR}/rc.d/rc0.d/K27bluetooth
+	rm -f ${EXTDIR}/rc.d/rc1.d/K27bluetooth
+	rm -f ${EXTDIR}/rc.d/rc2.d/S35bluetooth
+	rm -f ${EXTDIR}/rc.d/rc3.d/S35bluetooth
+	rm -f ${EXTDIR}/rc.d/rc4.d/S35bluetooth
+	rm -f ${EXTDIR}/rc.d/rc5.d/S35bluetooth
+	rm -f ${EXTDIR}/rc.d/rc6.d/K27bluetooth
+
 uninstall-cups:
 	rm -f ${EXTDIR}/rc.d/init.d/cups
 	rm -f ${EXTDIR}/rc.d/rc0.d/K00cups
@@ -517,6 +539,7 @@
 
 uninstall-cyrus-sasl:
 	rm -f ${EXTDIR}/rc.d/init.d/cyrus-sasl
+	rm -f ${EXTDIR}/sysconfig/cyrus-sasl
 	rm -f ${EXTDIR}/rc.d/rc0.d/K49cyrus-sasl
 	rm -f ${EXTDIR}/rc.d/rc1.d/K49cyrus-sasl
 	rm -f ${EXTDIR}/rc.d/rc2.d/S24cyrus-sasl
@@ -671,11 +694,12 @@
 	rm -f ${EXTDIR}/rc.d/rc5.d/S26ntp
 	rm -f ${EXTDIR}/rc.d/rc6.d/K46ntp
 
-uninstall-openldap1:
+uninstall-openldap:
 	rm -f ${EXTDIR}/rc.d/init.d/openldap
+	rm -f ${EXTDIR}/sysconfig/openldap
 	rm -f ${EXTDIR}/rc.d/rc0.d/K46openldap
 	rm -f ${EXTDIR}/rc.d/rc1.d/K46openldap
-	rm -f ${EXTDIR}/rc.d/rc2.d/K46openldap
+	rm -f ${EXTDIR}/rc.d/rc2.d/S25openldap
 	rm -f ${EXTDIR}/rc.d/rc3.d/S25openldap
 	rm -f ${EXTDIR}/rc.d/rc4.d/S25openldap
 	rm -f ${EXTDIR}/rc.d/rc5.d/S25openldap
@@ -815,6 +839,7 @@
 	install-avahi \
 	install-httpd \
 	install-bind \
+	install-bluetooth \
 	install-cups \
 	install-cyrus-sasl \
 	install-dhcp \
@@ -828,10 +853,11 @@
 	install-lprng \
 	install-mysql \
 	install-netfs \
+	install-networkmanager \
 	install-nfs-client \
 	install-nfs-server \
 	install-ntp \
-	install-openldap1 \
+	install-openldap \
 	install-postfix \
 	install-postgresql \
 	install-proftpd \
@@ -851,6 +877,7 @@
 	uninstall-avahi \
 	uninstall-httpd \
 	uninstall-bind \
+	uninstall-bluetooth \
 	uninstall-cups \
 	uninstall-cyrus-sasl \
 	uninstall-dhcp \
@@ -864,10 +891,11 @@
 	uninstall-lprng \
 	uninstall-mysql \
 	uninstall-netfs \
+	uninstall-networkmanager \
 	uninstall-nfs-client \
 	uninstall-nfs-server \
 	uninstall-ntp \
-	uninstall-openldap1 \
+	uninstall-openldap \
 	uninstall-postfix \
 	uninstall-postgresql \
 	uninstall-proftpd \
@@ -881,4 +909,4 @@
 	uninstall-svn \
 	uninstall-sysstat \
 	uninstall-virtuoso \
-	uninstall-vsftpd \
+	uninstall-vsftpd

Added: trunk/bootscripts/blfs/init.d/bluetooth
===================================================================
--- trunk/bootscripts/blfs/init.d/bluetooth	                        (rev 0)
+++ trunk/bootscripts/blfs/init.d/bluetooth	2012-07-01 22:14:55 UTC (rev 10385)
@@ -0,0 +1,130 @@
+#!/bin/sh
+########################################################################
+# Begin bluetooth
+#
+# Description : BlueZ Boot Script
+#
+# Authors     : Armin K. <krejzi at email.com>
+#
+# Version     : BLFS SVN
+#
+# Notes       : Configurable through /etc/sysconfig/bluetooth
+#
+########################################################################
+
+### BEGIN INIT INFO
+# Provides:            bluetooth
+# Required-Start:      $local_fs $syslog dbus
+# Required-Stop:       $local_fs $syslog
+# Default-Start:       2 3 4 5
+# Default-Stop:        0 1 6
+# Short-Description:   Starts bluetooth daemons
+# X-LFS-Provided-By:   BLFS
+### END INIT INFO
+
+. /lib/lsb/init-functions
+
+HIDD_ENABLE="false"
+PAND_ENABLE="false"
+DUND_ENABLE="false"
+
+RFCOMM_ENABLE="false"
+
+HIDD_OPTIONS=""
+PAND_OPTIONS=""
+DUND_OPTIONS=""
+
+if [ -f "/etc/sysconfig/bluetooth" ]; then
+   . /etc/sysconfig/bluetooth
+fi
+
+case "${1}" in
+   start)
+
+      log_info_msg "Starting Bluetooth daemon bluetooth \n"
+      start_daemon /usr/sbin/bluetoothd
+
+      if [ "$HIDD_ENABLE" = "true" ]; then
+        log_info_msg "Starting Bluetooth HID daemon hidd \n"
+        start_daemon /usr/sbin/hidd "$HIDD_OPTIONS"
+      fi
+
+      if [ "$RFCOMM_ENABLE" = "true" ]; then
+        /usr/bin/rfcomm -f /etc/bluetooth/rfcomm.conf bind all || true
+      fi
+
+      if [ "$PAND_ENABLE" = "true" ]; then
+        log_info_msg "Starting Bluetooth PAN daemon pand \n"
+        start_daemon /usr/bin/pand "$PAND_OPTIONS"
+      fi
+
+      if [ "$DUND_ENABLE" = "true" ]; then
+        log_info_msg "Starting Bluetooth DUN daemon dund \n"
+        start_daemon /usr/bin/dund "$DUND_OPTIONS"
+      fi
+
+      ;;
+
+   stop)
+
+      if [ "$DUND_ENABLE" = "true" ]; then
+        log_info_msg "Stopping Bluetooth DUN daemon dund \n"
+        killproc /usr/bin/dund
+      fi
+
+      if [ "$PAND_ENABLE" = "true" ]; then
+        log_info_msg "Stopping Bluetooth PAN daemon pand \n"
+        killproc /usr/bin/pand
+      fi
+
+      if [ "$RFCOMM_ENABLE" = "true" ]; then
+        /usr/bin/rfcomm release all || true
+      fi
+
+      if [ "$HIDD_ENABLE" = "true" ]; then
+        log_info_msg "Stopping Bluetooth HID daemon hidd \n"
+        killproc /usr/sbin/hidd
+      fi
+
+      log_info_msg "Stopping Bluetooth daemon bluetoothd \n"
+      killproc /usr/sbin/bluetoothd
+
+      ;;
+
+   restart)
+
+      ${0} stop
+      sleep 1
+      ${0} start
+
+      ;;
+
+   status)
+
+      statusproc /usr/sbin/bluetoothd
+
+      if [ "$HIDD_ENABLE" = "true" ]; then
+        statusproc /usr/sbin/hidd
+      fi
+
+      if [ "$PAND_ENABLE" = "true" ]; then
+        statusproc /usr/bin/pand
+      fi
+
+      if [ "$DUND_ENABLE" = "true" ]; then
+        statusproc /usr/bin/dund
+      fi
+
+      ;;
+
+   *)
+
+      echo "Usage: ${0} {start|stop|restart|status}"
+      exit 1
+
+      ;;
+esac
+
+exit 0
+
+# End bluetooth


Property changes on: trunk/bootscripts/blfs/init.d/bluetooth
___________________________________________________________________
Added: svn:keywords
   + LastChangedBy Date

Added: trunk/bootscripts/blfs/sysconfig/bluetooth
===================================================================
--- trunk/bootscripts/blfs/sysconfig/bluetooth	                        (rev 0)
+++ trunk/bootscripts/blfs/sysconfig/bluetooth	2012-07-01 22:14:55 UTC (rev 10385)
@@ -0,0 +1,30 @@
+# Begin /etc/sysconfig/bluetooth
+
+# Run the bluetooth HID daemon (default: false)
+#HIDD_ENABLE="true"
+
+# Activate rfcomm ports (default: false)
+#RFCOMM_ENABLE="true"
+
+# Run bluetooth dial-up networking daemon (default: false)
+# Note: You need to pass coressponding options to the daemon
+# since it does not run without any options.
+#DUND_ENABLE="true"
+
+# Run bluetooth PAN daemon (default: false)
+# Note: You need to pass coressponding options to the daemon
+# since it does not run without any options.
+#PAND_ENABLE="true"
+
+# Options for hidd, dund and pand (default: none)
+
+# See man 1 hidd for available options.
+#HIDD_OPTIONS=""
+
+# See man 1 dund for available options.
+#DUND_OPTIONS=""
+
+# See man 1 pand for available options.
+#PAND_OPTIONS=""
+
+# End /etc/sysconfig/bluetooth


Property changes on: trunk/bootscripts/blfs/sysconfig/bluetooth
___________________________________________________________________
Added: svn:keywords
   + LastChangedBy Date




More information about the blfs-book mailing list