You will need to configure Maven as a global build tool.
In the Jenkins web interface, go to:
Manage Jenkins -> Global Tool Configuration -> Maven installations -> Add Maven.
Give your Maven installation a name and check the option to Install automatically.
Create a freestyle job and configure it as follows:
Invoke Top-Level Maven Target.package.Execute Windows batch command build stepExecute shell build stepjava -cp target/hello-1.0-SNAPSHOT.jar com.learningjenkins.App