Summary: | net-wireless/bluez init script uses bashisms | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Michał Górny <mgorny> |
Component: | Current packages | Assignee: | Tiziano Müller (RETIRED) <dev-zero> |
Status: | RESOLVED FIXED | ||
Severity: | minor | CC: | betelgeuse, denilsonsa, esigra, gustavo, mobile+disabled, pacho, pda |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | All | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: |
Few fixes in init.d script
Fixes to hidd initscript |
Description
Michał Górny
2009-08-28 18:49:17 UTC
Created attachment 202542 [details, diff]
Few fixes in init.d script
I've made following changes to the init.d script:
* did a retab,
* replaced those ugly tabs within ebegin with eindent,
* removed ${result} changing as even if hid2hci or rfcomm fails, bluetoothd is already running (else user will have to kill the daemon manually to be able to '/etc/init.d/bluetooth start' again),
* replaced final 'eend' with standard 'return' as else we'll get additional '[ok]' with no matching ebegin.
If you want to leave ${result} mangling there, you should use '-eq'; '=' is for strings and '==' is a bashism.
Created attachment 202544 [details, diff]
Fixes to hidd initscript
* moved variable assignments outside 'local' declaration so that fully POSIX-strict shells won't miss them,
* use numerical comparisons for ${result}.
I have an updated version of bluez in my overlay which is using these patches. Thanks This is fixed on ebuild for bluez-4.60 at bug #270859. Do we need to fix it for 4.39 too? What is the status of this one with bluez-4.60 ? (In reply to comment #5) > What is the status of this one with bluez-4.60 ? > I need only to apply the init.d-hidd.diff patch to 4.60. I forgot it, sorry. :-/, commited 4.60 ebuild still uses old scripts for hidd, then, at least that part is still valid The new '4.60/bluetooth-init.d' script once again embeds tab-indent into ebegin instead of using eindent. Package's init scripts not being posix compliant should be fixed, but this is not a blocker for openrc stabilization. +*bluez-4.70 (07 Sep 2010) + + 07 Sep 2010; Pacho Ramos <pacho@gentoo.org> -bluez-4.63.ebuild, + -bluez-4.64.ebuild, -bluez-4.67.ebuild, +bluez-4.70.ebuild, + +files/bluetooth-init.d, +files/init.d-hidd, metadata.xml: + Version bump with updated init.d scripts to make them POSIX compliant + (following Michał Górny suggestions in bug #283057), two new USE flags + for compiling plugins and some upstream bugfixes that allow us to drop old + alsa location patch. Remove old. + |