I would recommend learning the basics of Java before delving into Drools and Guvnor!
Here's the Java tutorial on creating Jar files:
http://docs.oracle.com/javase/tutorial/deployment/jar/build.html
... but you would be better off using Maven to do your builds: