We have the following scenario with our project:
You usually start from the Java source code. WAR
s don't include the Java source code, just the compiled classes under WEB-INF/classes
or JAR
s under WEB-INF/libs
.
What I would do is use Maven and start a brand new empty webapp project with it: http://maven.apache.org/guides/mini/guide-webapp.html
After you have the new empty project structure, copy the Java source code to it (src/main/java
) and fill out the dependencies list in pom.xml
.
Once you've done all this you can use mvn clean package
to create a standard WAR
file that you can deploy to Tomcat.