Move TunnelConfig to .ui, separate it from i2ptunnel.jar

This commit is contained in:
str4d
2015-03-11 03:58:24 +00:00
parent 812c00f11e
commit 1919e36c30
5 changed files with 51 additions and 8 deletions

View File

@ -62,7 +62,7 @@
<target name="jar" depends="builddep, compile, bundle-proxy, jarUpToDate, listChangedFiles" unless="jar.uptodate" >
<!-- set if unset -->
<property name="workspace.changes.j.tr" value="" />
<jar destfile="./build/i2ptunnel.jar" basedir="./build/obj" includes="**/*.class" excludes="**/EditBean.class **/IndexBean.class" >
<jar destfile="./build/i2ptunnel.jar" basedir="./build/obj" includes="**/*.class" excludes="**/ui/*.class **/EditBean.class **/IndexBean.class" >
<manifest>
<attribute name="Main-Class" value="net.i2p.i2ptunnel.I2PTunnel" />
<attribute name="Class-Path" value="i2p.jar mstreaming.jar" />
@ -73,7 +73,7 @@
<attribute name="Workspace-Changes" value="${workspace.changes.j.tr}" />
</manifest>
</jar>
<jar destfile="./build/temp-beans.jar" basedir="./build/obj" includes="**/EditBean.class **/IndexBean.class" />
<jar destfile="./build/temp-beans.jar" basedir="./build/obj" includes="**/ui/*.class **/EditBean.class **/IndexBean.class" />
</target>
<target name="jarUpToDate">
@ -90,6 +90,36 @@
</condition>
</target>
<!-- Separate jar for general UI classes -->
<target name="uiJar" depends="jar, uiJarUpToDate, listChangedFiles" unless="uiJar.uptodate" >
<!-- set if unset -->
<property name="workspace.changes.j.tr" value="" />
<jar destfile="./build/i2ptunnel-ui.jar" basedir="./build/obj" includes="**/ui/*.class" >
<manifest>
<attribute name="Class-Path" value="i2p.jar mstreaming.jar i2ptunnel.jar" />
<attribute name="Implementation-Version" value="${full.version}" />
<attribute name="Built-By" value="${build.built-by}" />
<attribute name="Build-Date" value="${build.timestamp}" />
<attribute name="Base-Revision" value="${workspace.version}" />
<attribute name="Workspace-Changes" value="${workspace.changes.j.tr}" />
</manifest>
</jar>
</target>
<target name="uiJarUpToDate">
<uptodate property="uiJar.uptodate" targetfile="build/i2ptunnel-ui.jar" >
<srcfiles dir= "build/obj" includes="**/ui/*.class" />
</uptodate>
<condition property="shouldListChanges" >
<and>
<not>
<isset property="uiJar.uptodate" />
</not>
<isset property="mtn.available" />
</and>
</condition>
</target>
<!-- servlet translations go in the war, not the jar -->
<target name="bundle" depends="compile, precompilejsp" unless="no.bundle">
<!-- Update the messages_*.po files.
@ -185,6 +215,9 @@
<target name="war" depends="precompilejsp, bundle, warUpToDate, listChangedFiles2" unless="war.uptodate" >
<!-- set if unset -->
<property name="workspace.changes.w.tr" value="" />
<copy todir="../jsp/WEB-INF/classes/net/i2p/i2ptunnel">
<fileset dir="build/obj/net/i2p/i2ptunnel/ui" />
</copy>
<copy file="build/obj/net/i2p/i2ptunnel/web/EditBean.class" todir="../jsp/WEB-INF/classes/net/i2p/i2ptunnel/web" />
<copy file="build/obj/net/i2p/i2ptunnel/web/IndexBean.class" todir="../jsp/WEB-INF/classes/net/i2p/i2ptunnel/web" />
<war destfile="build/i2ptunnel.war" webxml="../jsp/web-out.xml"

View File

@ -1,4 +1,4 @@
package net.i2p.i2ptunnel;
package net.i2p.i2ptunnel.ui;
import java.security.GeneralSecurityException;
import java.util.Arrays;
@ -16,6 +16,14 @@ import net.i2p.crypto.SigType;
import net.i2p.data.Base64;
import net.i2p.data.Destination;
import net.i2p.data.SimpleDataStructure;
import net.i2p.i2ptunnel.I2PTunnelClientBase;
import net.i2p.i2ptunnel.I2PTunnelConnectClient;
import net.i2p.i2ptunnel.I2PTunnelHTTPClient;
import net.i2p.i2ptunnel.I2PTunnelHTTPClientBase;
import net.i2p.i2ptunnel.I2PTunnelHTTPServer;
import net.i2p.i2ptunnel.I2PTunnelIRCClient;
import net.i2p.i2ptunnel.I2PTunnelServer;
import net.i2p.i2ptunnel.TunnelController;
import net.i2p.util.ConcurrentHashSet;
import net.i2p.util.PasswordManager;

View File

@ -27,9 +27,9 @@ import net.i2p.i2ptunnel.I2PTunnelHTTPClientBase;
import net.i2p.i2ptunnel.I2PTunnelHTTPServer;
import net.i2p.i2ptunnel.I2PTunnelIRCClient;
import net.i2p.i2ptunnel.I2PTunnelServer;
import net.i2p.i2ptunnel.TunnelConfig;
import net.i2p.i2ptunnel.TunnelController;
import net.i2p.i2ptunnel.TunnelControllerGroup;
import net.i2p.i2ptunnel.ui.TunnelConfig;
import net.i2p.util.Addresses;
/**

View File

@ -28,9 +28,9 @@ import net.i2p.i2ptunnel.I2PTunnelHTTPClient;
import net.i2p.i2ptunnel.I2PTunnelHTTPServer;
import net.i2p.i2ptunnel.I2PTunnelServer;
import net.i2p.i2ptunnel.SSLClientUtil;
import net.i2p.i2ptunnel.TunnelConfig;
import net.i2p.i2ptunnel.TunnelController;
import net.i2p.i2ptunnel.TunnelControllerGroup;
import net.i2p.i2ptunnel.ui.TunnelConfig;
import net.i2p.util.Addresses;
import net.i2p.util.FileUtil;
import net.i2p.util.Log;

View File

@ -286,6 +286,7 @@
<!-- jar (not war) for Android -->
<target name="buildAddressbookJar" depends="buildCore" >
<ant dir="apps/addressbook/" target="jar" />
<copy file="apps/addressbook/dist/addressbook.jar" todir="build/" />
</target>
<target name="buildAddressbook" depends="buildCore, buildJetty" >
@ -293,10 +294,11 @@
<copy file="apps/addressbook/dist/addressbook.war" todir="build/" />
</target>
<!-- jar only (no war) for Android -->
<target name="buildI2PTunnelJar" depends="buildStreaming" >
<ant dir="apps/i2ptunnel/java/" target="jar" />
<!-- Both jars and no war, for Android -->
<target name="buildI2PTunnelJars" depends="buildStreaming" >
<ant dir="apps/i2ptunnel/java/" target="uiJar" />
<copy file="apps/i2ptunnel/java/build/i2ptunnel.jar" todir="build/" />
<copy file="apps/i2ptunnel/java/build/i2ptunnel-ui.jar" todir="build/" />
</target>
<target name="buildI2PTunnel" depends="buildStreaming, buildJetty" >