title: How to include a external jar in a GWT (Google Web Toolkit) project?
body: <p>I have a external jar file named "xxx.jar". I use "xxx.jar" in my GWT project.</p>
  
  <p>When I attempt to build the JavaScript version of my project in Ant, I get one of the following type of errors at every location in which I use xxx. I get a error of this kind when doing the "gwtc" task in Ant, the javac compilation process proceeds just fine.</p>
  
  <blockquote>
    <blockquote>
      <p>[ERROR] Line 45: No source code is available for type org.xxx.ObjectName; did you forget to inherit a required module?</p>
    </blockquote>
  </blockquote>
  
  <p>Ok, so clearly it is not able to see/use the xxx.jar. Fixing this problem however is not as simple in GWT as it is in "plain" java. From the internet <a href="http://markmail.org/message/vwkngsyzlh3vvjrp#query:include%20external%20jar%20in%20GWT+page:1+mid:vwkngsyzlh3vvjrp+state:results1.2." rel="noreferrer">ref1</a>, I gather that I need to </p>
  
  <ol>
  <li>Include all the source (.java) files from xxx.jar in a source directory</li>
  <li>Add this source directory in some sort of new  gwt.xml file</li>
  <li>Hope and pray that all the java files are translatable by GWT :/</li>
  </ol>
  
  <p>So... What exactly do I do? what is this gwt.xml file I need to generate (Step 2)? Where do I put the source directory, and how to I reference it (Step 1)? What exactly are the mechanical steps necessary to add a external jar file in GWT?</p>