[ https://jira.codehaus.org/browse/MNG-5423?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jason van Zyl updated MNG-5423: ------------------------------- Fix Version/s: Issues to be reviewed for 4.x > mvn shell script doesn't always export JAVA_HOME > ------------------------------------------------ > > Key: MNG-5423 > URL: https://jira.codehaus.org/browse/MNG-5423 > Project: Maven 2 & 3 > Issue Type: Bug > Components: Command Line > Affects Versions: 3.0.4, 3.1.0-alpha-1 > Reporter: Tom Mueller > Fix For: Issues to be reviewed for 4.x > > > There are code paths through the mvn shell script that do not result in > JAVA_HOME being exported if it is not set when entering the script. > I found this in 3.0.4 on MacOS X. JAVA_HOME gets set at line 117, but then is > never exported, so the java process doesn't get the value. Based on reading > the code, I see other paths through the script where JAVA_HOME is not > exported even though it gets set by the script. > On the head, there are statements like the following (line 65): > export > JAVA_HOME=/System/Library/Java/JavaVirtualMachines/CurrentJDK/Contents/Home > This is not valid /bin/sh syntax. /bin/sh does not allow the export to be on > the same line where the environment variable is set. There are also paths on > the head where JAVA_HOME is not exported when it is set. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira