Bug 678064

Summary: Electra profile.d include fails for ksh
Product: [Fedora] Fedora Reporter: Elliott Forney <elliott.forney>
Component: elektraAssignee: Nicolas Chauvet (kwizart) <kwizart>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: unspecified    
Version: 14CC: kwizart, pertusus
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: elektra-0.7.0-6.fc15 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-03-22 03:45:30 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description Elliott Forney 2011-02-16 16:29:39 UTC
Description of problem:
With Korn Shell, sourcing /etc/kshrc throws errors when calling /etc/profile.d/elektra-elektraenv.sh if Elektra is installed.

Version-Release number of selected component (if applicable):
elektra-0.7.0-3

How reproducible:
Always.

Steps to Reproduce:
1.  Install Elektra

2.  Start Korn Shell
  ksh

3.  Source /etc/kshrc if your .kshrc doesn't already do this.  It is in /etc/skel/.kshrc by default.
  . /etc/kshrc
  
Actual results:
$ . /etc/kshrc
ksh: .[17]: .[46]: local: not found [No such file or directory]
ksh: .[17]: .[47]: local: not found [No such file or directory]
ksh: .[17]: .[48]: local: not found [No such file or directory]
ksh: .[17]: .[46]: local: not found [No such file or directory]
ksh: .[17]: .[47]: local: not found [No such file or directory]
ksh: .[17]: .[48]: local: not found [No such file or directory]

Expected results:
Clean ksh startup.

Additional info:
The "local" keyword is bash specific and includes in /etc/profile.d/*.sh should be Bourne Shell compliant.  Unfortunately, I don't believe there is any way to declare local variables that is universal to all Bourne-like Shells.  The best solution is probably to avoid them.

Comment 1 Nicolas Chauvet (kwizart) 2011-02-16 16:46:16 UTC
Can you suggest a patch that will either conditionalize or remove the local command and that work for your case ?

Comment 2 Fedora Update System 2011-03-17 15:58:22 UTC
elektra-0.7.0-6.fc15 has been submitted as an update for Fedora 15.
https://admin.fedoraproject.org/updates/elektra-0.7.0-6.fc15

Comment 3 Fedora Update System 2011-03-22 03:45:25 UTC
elektra-0.7.0-6.fc15 has been pushed to the Fedora 15 stable repository.  If problems still persist, please make note of it in this bug report.