Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 185112 - x11-apps/xinit-1.0.3-r3 /etc/X11/startDM.sh in xinit requires bash
Summary: x11-apps/xinit-1.0.3-r3 /etc/X11/startDM.sh in xinit requires bash
Status: RESOLVED WORKSFORME
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High minor (vote)
Assignee: Gentoo X packagers
URL: http://sources.gentoo.org/viewcvs.py/...
Whiteboard:
Keywords:
: 190525 (view as bug list)
Depends on:
Blocks:
 
Reported: 2007-07-12 21:37 UTC by Jason Lai
Modified: 2007-08-28 21:12 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jason Lai 2007-07-12 21:37:34 UTC
/etc/X11/startDM.sh (part of sys-apps/xinit) uses /etc/init.d/functions.sh, which depends on bash syntax, but startDM.sh uses #!/bin/sh.

Therefore, if #!/bin/sh is linked to something else (e.g. dash) then running startDM.sh will fail.

Reproducible: Always

Steps to Reproduce:
1. Link /bin/sh to /bin/dash (install dash first)
2. Run /etc/init.d/xdm start
3.

Actual Results:  
/etc/init.d/functions.sh: 7: [[: not found
/etc/init.d/functions.sh: 10: declare: not found
/etc/init.d/functions.sh: 11: declare: not found
/etc/init.d/functions.sh: 87: [[: not found
/etc/init.d/functions.sh: 87: [[: not found
/etc/init.d/functions.sh: 96: [[: not found
/etc/init.d/functions.sh: 104: [[: not found
/etc/init.d/functions.sh: 306: Syntax error: Bad substitution



xinit-1.0.3-r3, regression from at least 1.0.2-r6
Comment 1 Roy Marples (RETIRED) gentoo-dev 2007-07-13 09:31:43 UTC
The URL you reference compares cvs versions 1.2 vs 1.3

1.2 enforces bash, 1.3 uses /bin/sh and has no bash specific code.
However, it does require bash if you're using baselayout-1 as the scripts referenced are bash. baselayout-2 has no bash specific scripts.
Comment 2 Jason Lai 2007-07-13 17:05:23 UTC
baselayout-2 is still in alpha and hard-masked, but using a non-bash shell for /bin/sh is currently at-your-own risk anyhow.
Comment 3 Jakub Moc (RETIRED) gentoo-dev 2007-08-28 14:00:46 UTC
*** Bug 190525 has been marked as a duplicate of this bug. ***
Comment 4 Philipp Kern 2007-08-28 21:12:33 UTC
Oh please, I really don't like to rant. It's clear that I am on unsupported grounds when I use dash as my /bin/sh, but well, I was up to report and debug the bugs I find.

But now I see that you are reluctant to do the one-line fix in stable just because "baselayout-2" will fix it magically, which is even hardmasked.