Short overview:
- My situation
- What I want
- What I have done so far
1. My situation:
In my company we use a document archiving software called Proxess. This software offers several APIs / interfaces to interact with. The only backdraw is that they are all C(++) / .NET oriented. There is no official support for Java.
Since all of our self developed applications are written in Java and my company does not want to switch the document archiving software, my superior decided to develop a wrapper using JNI so our applications can use the archive. And I am the one who received this task.
We are using eclipse (currently the "Kepler" release with m2e Maven plugin) on a Windows 7 workstation. All our applications are Maven multi-module projects. Target platform is RedHat Enterprise Linux (6.3+).
2. What I want:
I want a separate Maven module which capsules the JNI/C++ bridge part. If possible I want a <build>-section in the pom.xml of the module. So when I start mvn clean install
, Maven shall compile my JNI java class files, generate the corresponding C++ header / class files and Finally a compiled dll that I can use in my appliocations. I am not familiar with C++ or .NET.
- Is this possible?
- How can I achieve this?
- How do I get Maven to compile C++ classes?
3. What I have done so far:
I have googled on Eclipse, m2e, Maven, JNI, javah and dll. What I have found so far are examples on how to configure javah as external tools in eclipse, the maven-native-plugin but only with pseudo configurations and a lot of threads that never got solved.
Best regards, CB