From 4c0e3f92d36cf743998a3669ea100a7bb786150b Mon Sep 17 00:00:00 2001 From: aum <aum> Date: Mon, 12 Apr 2004 08:32:32 +0000 Subject: [PATCH] Created build.xml for SAM Moved README out of build dir --- apps/sam/jython/README | 57 +++++++++++++++++++++++++++++++++++++++ apps/sam/jython/build.xml | 27 +++++++++++++++++++ 2 files changed, 84 insertions(+) create mode 100644 apps/sam/jython/README create mode 100644 apps/sam/jython/build.xml diff --git a/apps/sam/jython/README b/apps/sam/jython/README new file mode 100644 index 0000000000..e72bc479e9 --- /dev/null +++ b/apps/sam/jython/README @@ -0,0 +1,57 @@ +----------------------------------- +Instructions for building i2psam.jar +------------------------------------ + +1) Requirements + +You will need: + + - a decent java sdk, eg Sun J2SDK 1.4.2 or later + - jython - www.jython.org + +Note that you don't need python to build the SAM server + +IMPORTANT - when installing jython, and run java on jython_n.n.class, +make sure you run the java.exe that's in your SDK, not the one in your +JRE. + +--------------------------------------------------------- + +2) Preparation + +Edit the Makefile, and set JYTHONJAR to where your jython.jar lives + +Don't worry about this if your're on windows + +---------------------------------------------------------- + +3) Building + +To build i2psam.jar on regular *nix OSs, simply type 'make'. + +To build i2psam.jar on Windows, type 'build.bat' + +---------------------------------------------------------- + +4) Installing + +Copy i2psam.jar to wherever the jar files live on your i2p installation, +usually <i2pbasedir>/lib + +Find jython.jar, and copy it there too + +---------------------------------------------------------- + +5) Running + +(assuming that you're putting the start script into your main i2p +runtime directory, where the I2P jars live in a 'lib' subdirectory) + +You will need to launch i2psam.jar with a command like: + + java -cp lib/jython.jar:lib/i2p.jar:lib/mstreaming.jar:lib/i2psam.jar i2psam + +or on windows, + + java -cp lib\jython.jar;lib\i2p.jar;lib\mstreaming.jar;lib\i2psam.jar i2psam + diff --git a/apps/sam/jython/build.xml b/apps/sam/jython/build.xml new file mode 100644 index 0000000000..35cffd8b08 --- /dev/null +++ b/apps/sam/jython/build.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project basedir="." default="all" name="sam"> + + <target name="all" depends="build" /> + + <target name="build" depends="builddep, jar" /> + + <target name="builddep"> + <ant dir="../../../core/java/" target="build" /> + <ant dir="../../ministreaming/java/" target="build" /> + </target> + + <target name="jar"> + <exec executable="jythonc"> + <env key="CLASSPATH" path="../../../core/java/build/i2p.jar:../../ministreaming/java/build/mstreaming.jar"/> + <arg value="--jar"/> + <arg value="./build/i2psam.jar"/> + <arg value="./src/i2psam.py"/> + </exec> + </target> + + <target name="clean"> + <delete dir="./build" /> + <delete dir="./jpywork" /> + </target> + +</project> -- GitLab