Ah, sorry, I meant to include version info in my original mail.

$ mvn --version
Apache Maven 3.0.4
Maven home: /usr/share/maven
Java version: 1.7.0_13, vendor: Oracle Corporation
Java home: /usr/lib/jvm/jdk1.7.0_13/jre
Default locale: en_IE, platform encoding: UTF-8
OS name: "linux", version: "3.5.0-23-generic", arch: "amd64", family: "unix"

I've placed the pom contents at https://gist.github.com/brk3/4981471
(unsure which field represents the plugin version...)

-Paul

On 18 February 2013 22:26, Anders Hammar <and...@hammar.net> wrote:
> If you use version 3.0 of maven-compiler-plugin it should give you better
> info if you use JDK 1.6+. You need to pin down the version of the plugin in
> the pom.
>
> /Anders
>
>
> On Mon, Feb 18, 2013 at 11:18 PM, Paul Bourke <pauldbou...@gmail.com> wrote:
>
>> Hi,
>>
>> I'm having trouble where Maven is not showing compiler errors as one
>> would expect.
>>
>> Take the following:
>>
>> ```
>> # Create a basic 'hello world' project
>> $ mvn archetype:generate -DgroupId=com.mycompany.app
>> -DartifactId=my-app -DarchetypeArtifactId=maven-archetype-quickstart
>> -DinteractiveMode=false
>>
>> $ cd my-app/
>>
>> # Add a syntax error
>> $ sed -i 's/println/printl/g' src/main/java/com/mycompany/app/App.java
>>
>> # Try to compile
>> $ mvn package
>> ```
>>
>> I get the following:
>>
>> ...
>> [ERROR] Failed to execute goal
>> org.apache.maven.plugins:maven-compiler-plugin:2.0.2:compile
>> (default-compile) on project my-app: Compilation failure
>> [ERROR]
>> /home/bourke/tmp/my-app/src/main/java/com/mycompany/app/App.java:[11,18]
>> error: cannot find symbol
>> [ERROR] -> [Help 1]
>> ...
>>
>> It doesn't show me what symbol is wrong.  Compare with the default javac
>> output:
>>
>> $ javac src/main/java/com/mycompany/app/App.java
>> src/main/java/com/mycompany/app/App.java:11: error: cannot find symbol
>>         System.out.printl( "Hello World!" );
>>                   ^
>>   symbol:   method printl(String)
>>   location: variable out of type PrintStream
>> 1 error
>>
>> Obviously much more useful.
>>
>> Any help much appreciated.
>> -Paul
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
>> For additional commands, e-mail: users-h...@maven.apache.org
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org

Reply via email to