You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Jason van Zyl (JIRA)" <ji...@apache.org> on 2015/05/01 01:59:06 UTC
[jira] [Closed] (MNG-5423) mvn shell script doesn't always export
JAVA_HOME
[ https://issues.apache.org/jira/browse/MNG-5423?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jason van Zyl closed MNG-5423.
------------------------------
Resolution: Fixed
> mvn shell script doesn't always export JAVA_HOME
> ------------------------------------------------
>
> Key: MNG-5423
> URL: https://issues.apache.org/jira/browse/MNG-5423
> Project: Maven
> Issue Type: Bug
> Components: Command Line
> Affects Versions: 3.0.4, 3.1.0-alpha-1
> Reporter: Thomas 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 was sent by Atlassian JIRA
(v6.3.4#6332)