Compiling UFace exception

4 views
Skip to first unread message

Chris

unread,
Jan 22, 2008, 2:36:23 AM1/22/08
to uface
Hi,

I was trying to follow the instructions on the wiki to build and i'm
getting the following exception when running Maven. Any idea what's
going on?

...
[INFO]
------------------------------------------------------------------------
[INFO] Building UFace :: GWT :: Example
[INFO] task-segment: [clean, install]
[INFO]
------------------------------------------------------------------------
[INFO] [clean:clean]
[INFO] Deleting directory /Users/cfong/workspace-gwt/
org.ufacekit.ui.gwt.example/target
[INFO] [resources:resources]
[INFO] Using default encoding to copy filtered resources.
[INFO] [compiler:compile]
Compiling 4 source files to /Users/cfong/workspace-gwt/
org.ufacekit.ui.gwt.example/target/classes
[INFO] [gwt:compile {execution: default}]
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] Exception attempting compile.

[INFO]
------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Exception
attempting compile.
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:
564)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:
480)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:
459)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:
311)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:
278)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:
143)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:333)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:126)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:282)
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.MojoExecutionException: Exception
attempting compile.
at com.totsp.mavenplugin.gwt.CompileMojo.execute(CompileMojo.java:71)
at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:
447)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:
539)
... 16 more
Caused by: java.lang.NullPointerException
at java.io.File.<init>(File.java:194)
at
com.totsp.mavenplugin.gwt.AbstractGWTMojo.buildClasspathList(AbstractGWTMojo.java:
345)
at
com.totsp.mavenplugin.gwt.ScriptWriterUnix.writeCompileScript(ScriptWriterUnix.java:
105)
at com.totsp.mavenplugin.gwt.CompileMojo.execute(CompileMojo.java:63)
... 18 more
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 14 seconds
[INFO] Finished at: Mon Jan 21 23:30:45 PST 2008
[INFO] Final Memory: 13M/29M
[INFO]
------------------------------------------------------------------------

James Strachan

unread,
Jan 22, 2008, 4:16:49 AM1/22/08
to uf...@googlegroups.com
Sorry about that - I'm guessing this could be related to your setup of GWT?

Did you follow the building instructions to configure where GWT is
installed on your machine?
http://code.google.com/p/uface/wiki/Building

I have been pondering about switching the maven build to this other
maven plugin instead which might make the build work without a GWT
install configured on the build machine...
http://gwtforge.com/


--
James
-------
http://macstrac.blogspot.com/

Open Source Integration
http://open.iona.com

Chris

unread,
Jan 23, 2008, 11:51:55 AM1/23/08
to uface
So yes, I followed those build instructions. I'm currently using OS X
10.5

1) I compiled and built the latest GWT distribution which is located
in:
/Users/cfong/workspace-gwt/trunk/build/dist

2) I modified my ~/m2/settings.xml file as described and pointed the
google.webtoolkit.home property to the above location

3) I ran mvn clean install

Am I missing a step?

Chris



On Jan 22, 1:16 am, "James Strachan" <james.strac...@gmail.com> wrote:
> Sorry about that - I'm guessing this could be related to your setup of GWT?
>
> Did you follow the building instructions to configure where GWT is
> installed on your machine?http://code.google.com/p/uface/wiki/Building
>
> I have been pondering about switching the maven build to this other
> maven plugin instead which might make the build work without a GWT
> install configured on the build machine...http://gwtforge.com/

James Strachan

unread,
Jan 23, 2008, 12:28:52 PM1/23/08
to uf...@googlegroups.com
On 23/01/2008, Chris <fon...@gmail.com> wrote:
>
> So yes, I followed those build instructions. I'm currently using OS X
> 10.5
>
> 1) I compiled and built the latest GWT distribution which is located
> in:
> /Users/cfong/workspace-gwt/trunk/build/dist
>
> 2) I modified my ~/m2/settings.xml file as described and pointed the
> google.webtoolkit.home property to the above location
>
> 3) I ran mvn clean install
>
> Am I missing a step?

Are you using the latest trunk BTW? I made a few changes yesterday to
use a specific gwt maven plugin version to avoid some build issues.

If so what errors do you get?

Chris

unread,
Jan 23, 2008, 10:07:55 PM1/23/08
to uface
Hi James,

Ok, so I just did an update to my tree and I now get the following
error when running mvn.

[INFO]
------------------------------------------------------------------------
[INFO] Building UFace :: GWT :: Example
[INFO] task-segment: [clean, install]
[INFO]
------------------------------------------------------------------------
[INFO] [clean:clean]
[INFO] Deleting directory /Users/cfong/workspace-gwt/
org.ufacekit.ui.gwt.example/target
[INFO] [resources:resources]
[INFO] Using default encoding to copy filtered resources.
[INFO] [compiler:compile]
Compiling 4 source files to /Users/cfong/workspace-gwt/
org.ufacekit.ui.gwt.example/target/classes
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] One or more required plugin parameters are invalid/missing for
'gwt:mergewebxml'

[0] Inside the definition for plugin 'maven-googlewebtoolkit2-plugin'
specify the following:

<configuration>
...
<compileTargets>VALUE</compileTargets>
</configuration>.

[INFO]
------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Error
configuring: com.totsp.gwt:maven-googlewebtoolkit2-plugin. Reason:
Invalid or missing parameters: [Mojo parameter [name:
'compileTargets'; alias: 'null']] for mojo: com.totsp.gwt:maven-
googlewebtoolkit2-plugin:2.0-beta6:mergewebxml
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:
568)
Caused by: org.apache.maven.plugin.PluginParameterException: Error
configuring: com.totsp.gwt:maven-googlewebtoolkit2-plugin. Reason:
Invalid or missing parameters: [Mojo parameter [name:
'compileTargets'; alias: 'null']] for mojo: com.totsp.gwt:maven-
googlewebtoolkit2-plugin:2.0-beta6:mergewebxml
at
org.apache.maven.plugin.DefaultPluginManager.checkRequiredParameters(DefaultPluginManager.java:
911)
at
org.apache.maven.plugin.DefaultPluginManager.getConfiguredMojo(DefaultPluginManager.java:
616)
at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:
425)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:
539)
... 16 more
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 15 seconds
[INFO] Finished at: Wed Jan 23 19:05:37 PST 2008
[INFO] Final Memory: 14M/28M
[INFO]
------------------------------------------------------------------------


On Jan 23, 9:28 am, "James Strachan" <james.strac...@gmail.com> wrote:
> On 23/01/2008, Chris <fon...@gmail.com> wrote:
>
>
>
> > So yes, I followed those build instructions. I'm currently using OS X
> > 10.5
>
> > 1) I compiled and built the latest GWT distribution which is located
> > in:
> > /Users/cfong/workspace-gwt/trunk/build/dist
>
> > 2) I modified my ~/m2/settings.xml file as described and pointed the
> > google.webtoolkit.home property to the above location
>
> > 3) I ran mvn clean install
>
> > Am I missing a step?
>
> Are you using the latest trunk BTW? I made a few changes yesterday to
> use a specific gwt maven plugin version to avoid some build issues.
>
> If so what errors do you get?
>
> --
> James

Chris

unread,
Jan 23, 2008, 10:13:16 PM1/23/08
to uface
Disregard my last message. It was my mistake. I didn't have the
updated pom.xml. Now I'm getting the following error message which
looks like it can't find the GWTCompiler class.

[INFO] [gwt:compile {execution: default}]
Using classpath: /Users/cfong/workspace-gwt/
org.ufacekit.ui.gwt.example/target/classes:/Users/cfong/.m2/repository/
com/google/gwt/gwt-user/1.5-dev/gwt-user-1.5-dev.jar:/Users/cfong/
workspace-gwt/org.ufacekit.ui.gwt/target/org.ufacekit.ui.gwt-1.0-
SNAPSHOT.jar:/Users/cfong/workspace-gwt/
org.ufacekit.ui.gwt.databinding/target/
org.ufacekit.ui.gwt.databinding-1.0-SNAPSHOT.jar:/Users/cfong/.m2/
repository/org/eclipse/equinox/common/3.3-uface/common-3.3-uface.jar:/
Users/cfong/.m2/repository/org/eclipse/core/databinding/3.3-uface/
databinding-3.3-uface.jar:/Users/cfong/workspace-gwt/org.ufacekit.ui/
target/org.ufacekit.ui-1.0-SNAPSHOT.jar:/Users/cfong/workspace-gwt/
org.ufacekit.ui.example/target/org.ufacekit.ui.example-1.0-
SNAPSHOT.jar:/Users/cfong/workspace-gwt/org.ufacekit.core.ubean/target/
org.ufacekit.core.ubean-1.0-SNAPSHOT.jar:/Users/cfong/.m2/repository/
org/eclipse/core/runtime/3.3.100-v20070530/runtime-3.3.100-
v20070530.jar:/Users/cfong/.m2/repository/org/eclipse/osgi/3.3.0-
v20070530/osgi-3.3.0-v20070530.jar:/Users/cfong/.m2/repository/org/
eclipse/core/jobs/3.3.0-v20070423/jobs-3.3.0-v20070423.jar:/Users/
cfong/.m2/repository/org/eclipse/equinox/registry/3.3.0-v20070522/
registry-3.3.0-v20070522.jar:/Users/cfong/.m2/repository/org/eclipse/
equinox/preferences/3.2.100-v20070522/preferences-3.2.100-
v20070522.jar:/Users/cfong/.m2/repository/org/eclipse/core/contenttype/
3.2.100-v20070319/contenttype-3.2.100-v20070319.jar:/Users/cfong/
workspace-gwt/org.ufacekit.ui.uform/target/org.ufacekit.ui.uform-1.0-
SNAPSHOT.jar:/Users/cfong/workspace-gwt/
org.ufacekit.core.ubean.databinding/target/
org.ufacekit.core.ubean.databinding-1.0-SNAPSHOT.jar:/Users/cfong/
workspace-gwt/trunk/build/dist/gwt-mac-0.0.0/gwt-dev-linux.jar:/Users/
cfong/workspace-gwt/trunk/build/dist/gwt-mac-0.0.0/gwt-dev-mac.jar:/
Users/cfong/workspace-gwt/trunk/build/dist/gwt-mac-0.0.0/gwt-dev-
windows.jar:/Users/cfong/workspace-gwt/trunk/build/dist/gwt-mac-0.0.0/
gwt-user.jar:/Users/cfong/workspace-gwt/org.ufacekit.ui.gwt.example/
src:/Users/cfong/workspace-gwt/org.ufacekit.ui.gwt.example/src
[INFO] Running GWTCompile with command: /System/Library/Frameworks/
JavaVM.framework/Versions/1.5.0/Home/bin/java -Xmx256m -classpath /
Users/cfong/workspace-gwt/org.ufacekit.ui.gwt.example/target/classes:/
Users/cfong/.m2/repository/com/google/gwt/gwt-user/1.5-dev/gwt-
user-1.5-dev.jar:/Users/cfong/workspace-gwt/org.ufacekit.ui.gwt/target/
org.ufacekit.ui.gwt-1.0-SNAPSHOT.jar:/Users/cfong/workspace-gwt/
org.ufacekit.ui.gwt.databinding/target/
org.ufacekit.ui.gwt.databinding-1.0-SNAPSHOT.jar:/Users/cfong/.m2/
repository/org/eclipse/equinox/common/3.3-uface/common-3.3-uface.jar:/
Users/cfong/.m2/repository/org/eclipse/core/databinding/3.3-uface/
databinding-3.3-uface.jar:/Users/cfong/workspace-gwt/org.ufacekit.ui/
target/org.ufacekit.ui-1.0-SNAPSHOT.jar:/Users/cfong/workspace-gwt/
org.ufacekit.ui.example/target/org.ufacekit.ui.example-1.0-
SNAPSHOT.jar:/Users/cfong/workspace-gwt/org.ufacekit.core.ubean/target/
org.ufacekit.core.ubean-1.0-SNAPSHOT.jar:/Users/cfong/.m2/repository/
org/eclipse/core/runtime/3.3.100-v20070530/runtime-3.3.100-
v20070530.jar:/Users/cfong/.m2/repository/org/eclipse/osgi/3.3.0-
v20070530/osgi-3.3.0-v20070530.jar:/Users/cfong/.m2/repository/org/
eclipse/core/jobs/3.3.0-v20070423/jobs-3.3.0-v20070423.jar:/Users/
cfong/.m2/repository/org/eclipse/equinox/registry/3.3.0-v20070522/
registry-3.3.0-v20070522.jar:/Users/cfong/.m2/repository/org/eclipse/
equinox/preferences/3.2.100-v20070522/preferences-3.2.100-
v20070522.jar:/Users/cfong/.m2/repository/org/eclipse/core/contenttype/
3.2.100-v20070319/contenttype-3.2.100-v20070319.jar:/Users/cfong/
workspace-gwt/org.ufacekit.ui.uform/target/org.ufacekit.ui.uform-1.0-
SNAPSHOT.jar:/Users/cfong/workspace-gwt/
org.ufacekit.core.ubean.databinding/target/
org.ufacekit.core.ubean.databinding-1.0-SNAPSHOT.jar:/Users/cfong/
workspace-gwt/trunk/build/dist/gwt-mac-0.0.0/gwt-dev-linux.jar:/Users/
cfong/workspace-gwt/trunk/build/dist/gwt-mac-0.0.0/gwt-dev-mac.jar:/
Users/cfong/workspace-gwt/trunk/build/dist/gwt-mac-0.0.0/gwt-dev-
windows.jar:/Users/cfong/workspace-gwt/trunk/build/dist/gwt-mac-0.0.0/
gwt-user.jar:/Users/cfong/workspace-gwt/org.ufacekit.ui.gwt.example/
src:/Users/cfong/workspace-gwt/org.ufacekit.ui.gwt.example/src
com.google.gwt.dev.GWTCompiler -logLevel INFO -style OBF -out /Users/
cfong/workspace-gwt/org.ufacekit.ui.gwt.example/target/
org.ufacekit.ui.gwt.example-1.0-SNAPSHOT gwtDemo.GwtDemo

Exception in thread "main" java.lang.NoClassDefFoundError: com/google/
gwt/dev/GWTCompiler

[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] Exception in thread "main" java.lang.NoClassDefFoundError: com/
google/gwt/dev/GWTCompiler

[INFO]
------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Exception in
thread "main" java.lang.NoClassDefFoundError: com/google/gwt/dev/
GWTCompiler

at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:
564)
Caused by: org.apache.maven.plugin.MojoExecutionException: Exception
in thread "main" java.lang.NoClassDefFoundError: com/google/gwt/dev/
GWTCompiler

at com.totsp.mavenplugin.gwt.CompileMojo.execute(CompileMojo.java:85)
at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:
447)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:
539)
... 16 more
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 16 seconds
[INFO] Finished at: Wed Jan 23 19:09:46 PST 2008
[INFO] Final Memory: 12M/30M
[INFO]
------------------------------------------------------------------------

Chris

unread,
Jan 23, 2008, 10:24:30 PM1/23/08
to uface
Ok, looks like I got it to build successfully. I had to copy my gwt-
dev-mac.jar that I built from the gwt source and copy it to my ~/m2/
repository/com/google/gwt/gwt-user/1.5-dev/ directory. After that,
everything worked fine.

Thanks

Chris
Reply all
Reply to author
Forward
0 new messages