Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 363697

Summary: openrc should force use bash on Gentoo/FBSD
Product: Gentoo/Alt Reporter: Yuta SATOH <nigoro.dev>
Component: FreeBSDAssignee: Gentoo/BSD Team <bsd+disabled>
Status: RESOLVED INVALID    
Severity: major    
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: FreeBSD   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: patch for openrc-0.8.1.ebuild

Description Yuta SATOH 2011-04-15 12:15:04 UTC
Some init scripts are written on the assumption that the shell is bash.
However, /bin/sh is not a symbolic link of bash but Bourne Shell on Gentoo/FBSD.

As a result, the init script doesn't operate normally. 

Reproducible: Always

Steps to Reproduce:
1. /etc/init.d/mysql start
2.
3.
Actual Results:  
/etc/init.d/mysql: 9: Syntax error: "(" unexpected
 * ERROR: mysql failed to start
Comment 1 Yuta SATOH 2011-04-15 12:21:36 UTC
Created attachment 270055 [details, diff]
patch for openrc-0.8.1.ebuild

This patch is not good.
However, this problem is compulsorily evaded.
Comment 2 Patrick Lauer gentoo-dev 2011-04-15 12:22:40 UTC
No, these init scripts should be fixed. OpenRC assumes Posix SH only.

As far as I know only mysql has bashism left, and those are very hard / impossible to fix without breaking some configurations. So it has been broken for quite a while and no one knows how to fix it.