Hi,
I am a new member of this community. I have just started using GWT. I
am getting following error while running build script through ant:

Buildfile: /home/viks/workspace/Calculator/build.xml
libs:
javac:
     [copy] Copying 1 file to /home/viks/workspace/Calculator/war/WEB-
INF/classes
gwtc:
     [java] Compiling module com.mydept.mycompany.client.Calculator"
     [java]    Finding entry point classes
     [java]       [ERROR] Unable to find type
'com.mycompany.mydept.client.Calculator'
     [java]          [ERROR] Hint: Previous compiler errors may have
made this type unavailable
     [java]          [ERROR] Hint: Check the inheritance chain from
your module; it may not be inheriting a required module or a module
may not be adding its source path entries properly


#################################################


Calculator.gwt.xml file is in same package as Calculator.java. Its
contents are:

<module>
      <inherits name='com.google.gwt.user.User'/>

        <inherits name="com.google.gwt.i18n.I18N" />

        <inherits name='com.gwtext.GwtExt'/>
        <entry-point class='com.mycompany.mydept.client.Calculator'/>
        <stylesheet src="js/ext/resources/css/ext-all.css" />
        <script src="js/ext/adapter/ext/ext-base.js" />
        <script src="js/ext/ext-all.js" />
    <stylesheet src='Calculator.css' />
        <servlet path="/DbaseRPCService"
class="com.mycompany.mydept.server.DbaseRPCServiceImpl"/>
</module>


######################################################


The class Calculator is exactly at the specified package. It is like
this:
public class Calculator implements EntryPoint {
...
...
}


######################################################


build.xml is:

<?xml version="1.0" encoding="utf-8" ?>
<project name="Calculator" default="build" basedir=".">
  <!-- Arguments to gwtc and devmode targets -->
  <property name="gwt.args" value="" />

  <!-- Configure path to GWT SDK -->
  <property name="gwt.sdk" location="/home/viks/gwt-2.0.1" />
  <property name="libs" location="/home/viks/otherLibraries" />

  <path id="project.class.path">
    <pathelement location="war/WEB-INF/classes"/>
    <pathelement location="${gwt.sdk}/gwt-user.jar"/>
        <pathelement location="${libs}/gwtext.jar"/>
        <pathelement location="${libs}/servlet-api-2.4.jar"/>
        <pathelement location="${libs}/mail.jar"/>
        <pathelement location="${libs}/activation.jar"/>
    <fileset dir="${gwt.sdk}" includes="gwt-dev*.jar"/>
    <!-- Add any additional non-server libs (such as JUnit) -->
    <fileset dir="war/WEB-INF/lib" includes="**/*.jar"/>
  </path>


  <target name="libs" description="Copy libs to WEB-INF/lib">
    <mkdir dir="war/WEB-INF/lib" />
    <copy todir="war/WEB-INF/lib" file="${gwt.sdk}/gwt-servlet.jar" />
    <!-- Add any additional server libs that need to be copied -->
  </target>

  <target name="javac" depends="libs" description="Compile java
source">
    <mkdir dir="war/WEB-INF/classes"/>
    <javac srcdir="src" includes="**" encoding="utf-8"
        destdir="war/WEB-INF/classes"
        source="1.5" target="1.5" nowarn="true"
        debug="true" debuglevel="lines,vars,source">
      <classpath refid="project.class.path"/>
    </javac>
    <copy todir="war/WEB-INF/classes">
      <fileset dir="src" excludes="**/*.java"/>
    </copy>
  </target>

  <target name="gwtc" depends="javac" description="GWT compile to
JavaScript">
    <java failonerror="true" fork="true"
classname="com.google.gwt.dev.Compiler">
        <classpath>
                <pathelement location="src"/>
                <path refid="project.class.path"/>
        </classpath>
      <!-- add jvmarg -Xss16M or similar if you see a
StackOverflowError -->
      <jvmarg value="-Xmx256M"/>
      <!-- Additional arguments like -style PRETTY or -logLevel DEBUG
-->
      <arg line="${gwt.args}"/>
      <arg value="com.mycompany.mydept.client.Calculator"/>
    </java>
  </target>

  <target name="devmode" depends="javac" description="Run development
mode">
    <java failonerror="true" fork="true"
classname="com.google.gwt.dev.DevMode">
      <classpath>
        <pathelement location="src"/>
        <path refid="project.class.path"/>
      </classpath>
      <jvmarg value="-Xmx256M"/>
      <arg value="-startupUrl"/>
      <arg value="/home/viks/workspace/Calculator/src/com/mydept/
mycompany/public/index.html"/>
      <!-- Additional arguments like -style PRETTY or -logLevel DEBUG
-->
      <arg line="${gwt.args}"/>
      <arg value="com.mycompany.mydept.client.Calculator"/>
    </java>
  </target>

<target name="hosted" depends="devmode" description="Run development
mode (NOTE: the 'hosted' target is deprecated)" />

  <target name="build" depends="gwtc" description="Build this
project" />

  <target name="war" depends="build" description="Create a war file">
    <zip destfile="Calculator.war" basedir="war"/>
  </target>

  <target name="clean" description="Cleans this project">
    <delete dir="war/WEB-INF/classes" failonerror="false" />
    <delete dir="war/Calculator" failonerror="false" />
  </target>

</project>



######################################################



Looks like the problem is specific to following 2 lines:
     [java]          [ERROR] Hint: Previous compiler errors may have
made this type unavailable
     [java]          [ERROR] Hint: Check the inheritance chain from
your module; it may not be inheriting a required module or a module
may not be adding its source path entries properly


I am not able to analyse this situation. I would really appreciate any
help on this.

Thanks.

--
viks

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to