I tried to build this example : https://github.com/oltzen/JavaCppExample with Maven (mvn clean install) on Linux. After the successful build, when I run : java de.oltzen.javacppexample.Abc : it says 'could not load or find the main class'
The video tutorial (https://www.youtube.com/watch?v=LZrrqZLhtmw) uses Eclipse and it runs the program with Run as .. Java Application
Is the POM file missing something ?
I tried to add this plugin in POM but it did not work:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifest>
<addClasspath>true</addClasspath>
<classpathPrefix>lib/</classpathPrefix>
<mainClass>de.oltzen.javacppexample.Abc</mainClass>
</manifest>
</archive>
</configuration>
</plugin>
I am executing from JavaCppExample/target/classes/ :-
The /classes folder contains package folders : de/oltzen/javacppexample/ The last folder contains the class file Abc.class
So I run the command :
java de.oltzen.javacppexample.Abc
The /target folder contains : 1) classes [folder containing the package] 2) JavaCppExample.jar 3) maven-archiver 4) maven-status
Please help