Problem
-------

I am having some trouble with creating a runnable jar file in Eclipse with Scala.

In Eclipse I have a Scala project that I wish to make into a runnable jar file. When I run the jar file it cannot locate the Scala standard library.

Details
-------

**IDE** - I am using [Scala IDE](http://scala-ide.org/) for extending Eclipse for Scala usage.

**Setup** - To export right click on my project and navigate down Export>Runnable Jar File. I select my run configuration and set the path to my desktop. I have the 'Extract' library handling option selected. My run configuration is a Java Application with my main class selected. My main class is written in Java whilst the rest of the project is written in Scala. I then run the create jar file through Windows CMD with `java -jar myjarfile.jar`.

**Error** - When I run the jar file a `NoClassDefFoundError` is thrown when the program first encounters a Scala standard library class (`scala.util.Random` in my case). The program runs my Scala files fine and even runs another project's files that I added as a project dependency under Eclipse. When I run the jar file with `scala myjarfile.jar` it cannot find the main class. Even if using `scala` did work it would not be acceptable because the user will likely not have anything related Scala installed.

I have researched similar questions on Stack Overflow and none of them have worked. So how do I access Scala standard libraries in my jar file? Packaging the Scala standard libraries into my jar sounds like a good option but I have not idea how to do this.