You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Carlos Sanchez (JIRA)" <ji...@codehaus.org> on 2006/04/03 16:04:44 UTC

[jira] Created: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Compiler fork executable fails when the path has spaces
-------------------------------------------------------

         Key: MCOMPILER-30
         URL: http://jira.codehaus.org/browse/MCOMPILER-30
     Project: Maven 2.x Compiler Plugin
        Type: Bug

    Versions: 2.0.1    
    Reporter: Carlos Sanchez
     Fix For: 2.0.2


JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18

        <plugin>
          <artifactId>maven-compiler-plugin</artifactId>
          <configuration>
            <fork>true</fork>
            <compilerVersion>1.3</compilerVersion>
            <executable>${JAVA_1_3_HOME}/bin/javac</executable>
          </configuration>
        </plugin>

Fails with

Failure executing javac,  but could not parse the error:
'C:\Program' is not recognized as an internal or external command,
operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Issue Comment Edited: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Jakob Magiera (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=209238#action_209238 ] 

Jakob Magiera edited comment on MCOMPILER-30 at 2/5/10 7:38 AM:
----------------------------------------------------------------

@Hilal Ram
This doesn't solve the issue, because maven is not actually executing the javac you specified but the internal compiler of the jdk that is set in your java_home. Think about it, it doesn't make sense to specify an executable if you are not going to fork a new process.

      was (Author: jmagiera):
    @Hilal Ram
This doesn't solve the issue, because maven is not actually executing the javac you specified but whatever is set in your java_home. Think about it, it doesn't make sense to specify an executable if you are not going to fork a new process.
  
> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Dan Rollo (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=144318#action_144318 ] 

Dan Rollo commented on MCOMPILER-30:
------------------------------------

I too am seeing this problem (using maven 2.0.9). I believe this issue is not fixed and will open a new jira issue to track it.

help:effective-pom shows maven-compiler-plugin, version 2.0.2.

Dan Rollo

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>            Assignee: Carlos Sanchez
>             Fix For: 2.0.2
>
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Philip Schwarz (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=147671#action_147671 ] 

Philip Schwarz commented on MCOMPILER-30:
-----------------------------------------

I am using Maven 2.0.9 and I have the problem even though there are no spaces in the path to the JDK :

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-compiler-plugin</artifactId>
				<version>2.0.2</version>
				<configuration>
					<verbose>true</verbose>
					<fork>true</fork>
					<source>1.5</source>
					<target>1.5</target>
					<compilerVersion>1.5</compilerVersion>
					<executable>C:/Views/KFL_1_0/vendors/etc/solaris/jdk1.5.0_05/bin/javac</executable>
					<meminitial>128m</meminitial>
					<maxmem>512m</maxmem>
				</configuration>				
			</plugin>


[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Compilation failure
Failure executing javac,  but could not parse the error:
'C:\Views\KFL_1_0\vendors\etc\solaris\jdk1.5.0_05\bin\javac' is not recognized as an internal or external command,
operable program or batch file.

Failure executing javac,  but could not parse the error:
'C:\Views\KFL_1_0\vendors\etc\solaris\jdk1.5.0_05\bin\javac' is not recognized as an internal or external command,
operable program or batch file.


[INFO] ------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.BuildFailureException: Compilation failure
Failure executing javac,  but could not parse the error:
'C:\Views\KFL_1_0\vendors\etc\solaris\jdk1.5.0_05\bin\javac' is not recognized as an internal or external command,
operable program or batch file.


        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:579)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:499)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:478)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:330)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:291)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:287)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
        at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
        at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
        at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.CompilationFailureException: Compilation failure
Failure executing javac,  but could not parse the error:
'C:\Views\KFL_1_0\vendors\etc\solaris\jdk1.5.0_05\bin\javac' is not recognized as an internal or external command,
operable program or batch file.


        at org.apache.maven.plugin.AbstractCompilerMojo.execute(AbstractCompilerMojo.java:516)
        at org.apache.maven.plugin.CompilerMojo.execute(CompilerMojo.java:114)
        at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:451)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:558)
        ... 16 more
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2 seconds
[INFO] Finished at: Thu Sep 11 15:15:57 BST 2008
[INFO] Final Memory: 2M/9M
[INFO] ------------------------------------------------------------------------

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>             Fix For: 2.0.2
>
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Carlos Sanchez (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MCOMPILER-30?page=all ]

Carlos Sanchez updated MCOMPILER-30:
------------------------------------

    Fix Version/s:     (was: 2.1)

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>         Assigned To: Carlos Sanchez
>             Fix For: 2.0.2
>
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Dan Rollo (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=147758#action_147758 ] 

Dan Rollo commented on MCOMPILER-30:
------------------------------------

He he. But how cool would that have been if it had worked?! ;)

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>             Fix For: 2.0.2
>
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Greg Hengeli (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=135447#action_135447 ] 

Greg Hengeli commented on MCOMPILER-30:
---------------------------------------

I too am encountering this error.  As (what I consider) a temporary solution, you can declare the dependency on plexus-utils to be version 1.5.1 in the plugin.  My question is why isn't this version of the dependency declared in the maven-compiler-plugin's pom?!  Is there another solution I am missing?

<plugin>
  <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-compiler-plugin</artifactId>
    <version>2.0.2</version>
    <configuration>
      <source>1.5</source>
      <target>1.5</target>
      <fork>true</fork>
      <executable>${JAVA5_HOME}/bin/javac</executable>
      <compilerVersion>1.5</compilerVersion>
    </configuration>
    <dependencies>
      <!-- required to allow spaces in the executable path -->
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.5.1</version>
      </dependency>
    </dependencies>
</plugin>

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>            Assignee: Carlos Sanchez
>             Fix For: 2.0.2
>
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Carlos Sanchez (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MCOMPILER-30?page=all ]

Carlos Sanchez updated MCOMPILER-30:
------------------------------------

    Fix Version: 2.1

Merged to branch 2.0.x

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>          Key: MCOMPILER-30
>          URL: http://jira.codehaus.org/browse/MCOMPILER-30
>      Project: Maven 2.x Compiler Plugin
>         Type: Bug

>     Versions: 2.0.1
>     Reporter: Carlos Sanchez
>     Assignee: Carlos Sanchez
>      Fix For: 2.1, 2.0.2

>
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Philip Schwarz (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=147672#action_147672 ] 

Philip Schwarz commented on MCOMPILER-30:
-----------------------------------------

Apologies to everyone, the previous comment was a false alarm (loser error): I was asking Maven to run a solaris jdk on a Windows box!!!

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>             Fix For: 2.0.2
>
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Bill (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_113984 ] 

Bill commented on MCOMPILER-30:
-------------------------------

I am try to use this feature by plug-in version 2.0.2 (Maven 2.0.7). I still got  the error:

Failure executing javac, but could not parse the error:
'C:\Program' is not recognized as an internal or external command,

I have tried to put  " " to enclose the value but still not working? 

I checked my plugin version (2.0.2). Is this issue has been addressed in this version?

Thank you.


> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>            Assignee: Carlos Sanchez
>             Fix For: 2.0.2
>
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Hilal Ram (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=182221#action_182221 ] 

Hilal Ram commented on MCOMPILER-30:
------------------------------------

HOW TO FIX THIS ISSUE
====================
 This is how you can Quick Fix this issue...

Go to your compile plugin -- Remove the <fork>true</fork> Element ; the build works fine.....

			<plugin>
				<artifactId>maven-compiler-plugin</artifactId>
				<configuration>
					<!-- <fork>true</fork> -->
					<executable>
						${JAVA_HOME_1.5}/bin/javac.exe
					</executable>
					<compilerVersion>1.5</compilerVersion>
					<source>1.5</source>
					<target>1.5</target>
				</configuration>
			</plugin>
			<plugin>

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Brett Porter updated MCOMPILER-30:
----------------------------------

    Fix Version/s:     (was: 2.0.2)

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Hilal Ram (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=209242#action_209242 ] 

Hilal Ram commented on MCOMPILER-30:
------------------------------------

This is the solution for windws (and not unix) and fork tag has no significance.

I think this is why it works Windws platforms : when you say fork = true, mvn thinks you are on unix and expect and executable path in Unix format..( I'm not sure of it, may be mvn experts can comment) and when you say fork=false (or comment it out to default to false) you are back in windws.

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Closed: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Carlos Sanchez (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MCOMPILER-30?page=all ]
     
Carlos Sanchez closed MCOMPILER-30:
-----------------------------------

     Assign To: Carlos Sanchez
    Resolution: Fixed

Fixed upgrading plexus-compiler versions

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>          Key: MCOMPILER-30
>          URL: http://jira.codehaus.org/browse/MCOMPILER-30
>      Project: Maven 2.x Compiler Plugin
>         Type: Bug

>     Versions: 2.0.1
>     Reporter: Carlos Sanchez
>     Assignee: Carlos Sanchez
>      Fix For: 2.0.2

>
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Reopened: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Carlos Sanchez (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Carlos Sanchez reopened MCOMPILER-30:
-------------------------------------

      Assignee:     (was: Carlos Sanchez)

reopened per user comments

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>             Fix For: 2.0.2
>
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Hilal Ram (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=182201#action_182201 ] 

Hilal Ram commented on MCOMPILER-30:
------------------------------------

I'm also facing this issue. Simply Because I have the Oracle installed on Program files and it's PATH is causing the build to fai
--- Any Quick Fix on this ???



[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Compilation failure
Failure executing javac,  but could not parse the error:
'C:\Program' is not recognized as an internal or external command,
operable program or batch file.


[INFO] ------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.BuildFailureException: Compilation failure
Failure executing javac,  but could not parse the error:
'C:\Program' is not recognized as an internal or external command,
operable program or batch file.


        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa
ultLifecycleExecutor.java:699)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLi
fecycle(DefaultLifecycleExecutor.java:540)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(Defau
ltLifecycleExecutor.java:519)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHan
dleFailures(DefaultLifecycleExecutor.java:371)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmen
ts(DefaultLifecycleExecutor.java:332)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLi
fecycleExecutor.java:181)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:356)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:137)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
        at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:4
1)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.


> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MCOMPILER-30) Compiler fork executable fails when the path has spaces

Posted by "Jakob Magiera (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MCOMPILER-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=209238#action_209238 ] 

Jakob Magiera commented on MCOMPILER-30:
----------------------------------------

@Hilal Ram
This doesn't solve the issue, because maven is not actually executing the javac you specified but whatever is set in your java_home. Think about it, it doesn't make sense to specify an executable if you are not going to fork a new process.

> Compiler fork executable fails when the path has spaces
> -------------------------------------------------------
>
>                 Key: MCOMPILER-30
>                 URL: http://jira.codehaus.org/browse/MCOMPILER-30
>             Project: Maven 2.x Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0.1
>            Reporter: Carlos Sanchez
>
> JAVA_1_3_HOME=C:\Program Files\Java\jdk1.3.1_18
>         <plugin>
>           <artifactId>maven-compiler-plugin</artifactId>
>           <configuration>
>             <fork>true</fork>
>             <compilerVersion>1.3</compilerVersion>
>             <executable>${JAVA_1_3_HOME}/bin/javac</executable>
>           </configuration>
>         </plugin>
> Fails with
> Failure executing javac,  but could not parse the error:
> 'C:\Program' is not recognized as an internal or external command,
> operable program or batch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira