1 /*! \page install Java Binding
3 \section bindings_binding_java_install How to install Simgrid-java
5 To use java with Simgrid you have to install some dependencies:
6 \li Simgrid (see <a href="http://simgrid.gforge.inria.fr/simgrid/3.7/doc/install.html">install
7 Simgrid</a>). You should set the SIMGRID_ROOT environment
8 variable to the path where you installed SimGrid.
9 \li Java JDK packages, such as sun-java6-jdk (with libgcj10-dev or
10 another version of gcj) or openjdk6.
12 Then Download and install package Simgrid-java:
14 git clone git://scm.gforge.inria.fr/simgrid/simgrid-java.git
16 cmake -DCMAKE_INSTALL_PREFIX=$HOME/Install/simgrid-java/ .
22 -- SITE : Linux_2.6.38-8-generic_x86_64
23 -- BUILDNAME : Simgrid-Java
24 -- Looking for lib SimGrid
25 -- Looking for lib SimGrid - found
26 -- Simgrid version : 3.6
28 -- Looking for gras.h - found
29 -- Found Tesh: /home/user/Bureau/simgrid/git/bin/tesh
30 -- Found gras_stub_generator: /home/user/Bureau/simgrid/git/bin/gras_stub_generator
31 -- Java version 1.6.0.22 configured successfully!
33 -- Looking for jni.h - found
34 -- Add flags -I/usr/lib/jvm/java-6-openjdk/include
35 -- Looking for jni_md.h
36 -- Looking for jni_md.h - found
37 -- Found javac: /usr/bin/javac
38 -- Found jar: /usr/bin/jar
41 -- Build files have been written to: /home/user/workspace/simgrid-java/build
44 \section bindings_binding_java_use How to use Simgrid-java
46 To execute the examples you need to add the path where you installed
47 the generated libSG_java library (<build_dir>/lib) and libsimgrid
48 ($SIMGRID_ROOT/lib) into the LD_LIBRARY_PATH.
50 Be careful on Mac, this variable is called DYLD_LIBRARY_PATH and not
54 $ export SIMGRID_ROOT="$HOME/Install/simgrid/"
55 $ export SIMGRID_JAVA_ROOT="$HOME/Install/simgrid-java"
56 $ export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$SIMGRID_ROOT/lib:$SIMGRID_JAVA_ROOT/java
58 $ java -cp .:../simgrid.jar basic/BasicTest platform.xml basic/basicDeployment.xml