I am building a GWT project with Maven. I have added the gwt-maven-plugin for GWT compilation as shown below :
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-user</artifactId>
<version>2.5.0</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-dev</artifactId>
<version>2.5.0</version>
<scope>provided</scope>
</dependency>
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>gwt-maven-plugin</artifactId>
<version>2.5.0</version>
<executions>
<execution>
<configuration>
<module>com.karthik.ui.MainWidgets</module>
</configuration>
<goals>
<goal>compile</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
I have included compile goal under executions tag expecting to execute GWT compilation during compile phase. But GWT compilation is getting executed only during package phase or when I run mvn package command.
Also I am getting a warning as shown below even though provided scope is set for gwt-dev dependency.
[WARNING] Don't declare gwt-dev as a project dependency. This may introduce complex dependency conflict
1) Why GWT compilation is not executed during compile phase?
2) What scope should I set for GWT(gwt-user, gwt-dev) dependencies to overcome the warning?