Need help with Ant GWT compile script

114 views
Skip to first unread message

Kwame

unread,
Aug 27, 2008, 8:23:17 PM8/27/08
to Google Web Toolkit
I'm trying to write a simple Ant script to compile my GWT app. o far I
have this

<target name="compile">
<java classname="com.google.gwt.dev.GWTCompiler"
fork="true"
failonerror="true"
maxmemory="256m">
<arg value="-out" file="${basedir}/www"/>
<arg value="module" file="src/com.my.app.Module" />

<classpath>
<pathelement location="${gwthome}/gwt-user.jar"/>
<pathelement location="${gwthome}/gwt-dev-mac.jar"/>
<pathelement location="${basedir}/src"/>
<pathelement path="${java.class.path}"/>
</classpath>

</java>
</target>

I'm getting build error:
compile:
[java] Loading module '/Users/me/Documents/workspace/com.gwt/src/
com.my.app.Module'
[java] [ERROR] Invalid module name:
'/Users/me/Documents/workspace/com.gwt/src/com.my.app.Module'
[java] [ERROR] Build failed

All the build properties are correctly set.
Can anyone help?

Renato Mangini

unread,
Aug 27, 2008, 10:32:09 PM8/27/08
to Google-We...@googlegroups.com

Kwame,

Here is mine. It works perfectly.

    <target name="web.compile" depends="init">
                <java fork="true" maxmemory="256M" classname="com.google.gwt.dev.GWTCompiler">
                        <classpath>
                                <pathelement path="${src.dir}"></pathelement>
                                <pathelement location="${GWT_HOME}/gwt-user.jar"></pathelement>
                                <pathelement location="${GWT_HOME}/gwt-dev-linux.jar"></pathelement>
                        </classpath>
                        <arg value="-out"/><arg value="www"/>
                        <arg value="com.mycompany.myapp"/>
                </java>
    </target>

Kwame Iwegbue

unread,
Aug 28, 2008, 1:04:44 AM8/28/08
to Google-We...@googlegroups.com
THANK YOU :)

Len

unread,
Aug 28, 2008, 3:27:29 AM8/28/08
to Google-We...@googlegroups.com
yes its that src/ in your module name
Reply all
Reply to author
Forward
0 new messages