wangwei created SINGA-259:
-----------------------------
Summary: Add maven pom file for building java classes
Key: SINGA-259
URL: https://issues.apache.org/jira/browse/SINGA-259
Project: Singa
Issue Type: New Feature
Reporter: wangwei
SINGA-244 has generated java files for the c++ code.
This ticket would refactor some API in *.i files and create the pom.xml to use
maven to compile the java classes. Java unittest is also enabled with a simple
example.
To test this ticket,
1. compile singa with java (cuda and cudnn are optional) in `build/`
{code}
cmake -DUSE_JAVA=ON -DUSE_PYTHON=OFF ..
make
{code}
2. goto build/java and run the unit tests
{code}
export LD_LIBRARY_PATH=<path to build>/java/lib:$LD_LIBRARY_PATH
mvn test
{code}
The folder structure for the java project is
{code}
java/
pom.xml
lib/libsinga_wrap.so
src/
main/java/org/apache/singa/
swig/
proto/
test/org/apache/singa/
{code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)