Private
Public Access
2
0

java: Added Java SWIG binding creation

%init directive is not supported in java so move %init to js/py interface files

Signed-off-by: Alexander Komarov <alexander.komarov@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
This commit is contained in:
Alexander Komarov
2015-04-13 13:23:13 +00:00
committed by Brendan Le Foll
parent c5780dceaa
commit 4302f0d0c3
12 changed files with 303 additions and 5 deletions

View File

@@ -115,3 +115,15 @@ cmake -DBUILDDOC=OFF -DBUILDSWIG=OFF ..
cov-build --dir cov-int make
tar caf mraa.tar.bz2 cov-int
~~~~~~~~~~~~~
## Building Java bindings
Have JAVA_HOME set to JDK install directory. Then use the cmake configuration flag:
-DBUILDSWIGJAVA=ON
To compile Example.java
~~~~~~~~~~~~~{.sh}
javac -cp $DIR_WHERE_YOU_INSTALLED_MRAA/mraa.jar:. Example.java
~~~~~~~~~~~~~
To run, make sure libmraajava.so is in LD_LIBRARY_PATH
~~~~~~~~~~~~~{.sh}
jave -cp $DIR_WHERE_YOU_INSTALLED_MRAA/mraa.jar:. Example
~~~~~~~~~~~~~