-
zzz authored
- Move multipart form support from susimail to jetty-i2p.jar so console can use it - Add multipart form support to formhandler.jsi and FormHandler.java Reseed: - Fix zip magic number - Finish manual reseed from local file package.html files for jetty-i2p.jar
zzz authored- Move multipart form support from susimail to jetty-i2p.jar so console can use it - Add multipart form support to formhandler.jsi and FormHandler.java Reseed: - Fix zip magic number - Finish manual reseed from local file package.html files for jetty-i2p.jar
build.xml 5.90 KiB
<?xml version="1.0" encoding="UTF-8"?>
<project basedir="." default="all" name="susimail">
<target name="all" depends="clean, build" />
<target name="build" depends="builddep, jar" />
<target name="builddep">
<!-- run from top level build.xml to get dependencies built -->
</target>
<property name="javac.compilerargs" value="" />
<property name="javac.version" value="1.6" />
<property name="require.gettext" value="true" />
<condition property="no.bundle">
<isfalse value="${require.gettext}" />
</condition>
<condition property="depend.available">
<typefound name="depend" />
</condition>
<target name="depend" if="depend.available">
<depend
cache="../../build"
srcdir="./src/src"
destdir="./src/WEB-INF/classes" >
<!-- Depend on classes instead of jars where available -->
<classpath>
<pathelement location="../../core/java/build/obj" />
<pathelement location="../jetty/jettylib/javax.servlet.jar" />
<pathelement location="../jetty/jettylib/jetty-i2p.jar" />
</classpath>
</depend>
</target>
<target name="compile" depends="depend" >
<mkdir dir="./src/WEB-INF/classes" />
<javac
srcdir="./src/src"
debug="true" deprecation="on" source="${javac.version}" target="${javac.version}"
includeAntRuntime="false"
destdir="./src/WEB-INF/classes">
<compilerarg line="${javac.compilerargs}" />
<classpath>
<pathelement location="../jetty/jettylib/javax.servlet.jar" />
<pathelement location="../jetty/jettylib/jetty-i2p.jar" />
<pathelement location="../../core/java/build/i2p.jar" />
</classpath>
</javac>
</target>
<target name="jar" depends="compile, war" />
<target name="listChangedFiles" depends="warUpToDate" if="shouldListChanges" >
<exec executable="mtn" outputproperty="workspace.changes" errorproperty="mtn.error2" failifexecutionfails="false" >
<arg value="list" />
<arg value="changed" />
<arg value="." />
</exec>
<!-- \n in an attribute value generates an invalid manifest -->
<exec executable="tr" inputstring="${workspace.changes}" outputproperty="workspace.changes.tr" errorproperty="mtn.error2" failifexecutionfails="false" >
<arg value="-s" />
<arg value="[:space:]" />
<arg value="," />
</exec>
</target>
<target name="war" depends="compile, bundle, warUpToDate, listChangedFiles" unless="war.uptodate" >
<!-- set if unset -->
<property name="workspace.changes.tr" value="" />
<copy file="src/susimail.properties" todir="src/WEB-INF/classes" />
<war destfile="susimail.war" webxml="src/WEB-INF/web.xml"
basedir="src/" excludes="WEB-INF/web.xml LICENSE src src/**/* susimail.properties">
<manifest>
<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.tr}" />
</manifest>
</war>
</target>
<target name="warUpToDate">
<uptodate property="war.uptodate" targetfile="susimail.war">
<srcfiles dir= "src" excludes="LICENSE src/**/*" />
</uptodate>
<condition property="shouldListChanges" >
<and>
<not>
<isset property="war.uptodate" />
</not>
<isset property="mtn.available" />
</and>
</condition>
</target>
<target name="bundle" depends="compile" unless="no.bundle">
<!-- Update the messages_*.po files.
We need to supply the bat file for windows, and then change the fail property to true -->
<exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" >
<env key="JAVA_HOME" value="${java.home}" />
<arg value="./bundle-messages.sh" />
</exec>
<exec executable="sh" osfamily="mac" failifexecutionfails="true" failonerror="${require.gettext}" >
<arg value="./bundle-messages.sh" />
</exec>
<!-- multi-lang is optional -->
<exec executable="sh" osfamily="windows" failifexecutionfails="false" >
<arg value="./bundle-messages.sh" />
</exec>
</target>
<target name="poupdate" depends="builddep, compile">
<!-- Update the messages_*.po files. -->
<exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="true" >
<arg value="./bundle-messages.sh" />
<arg value="-p" />
</exec>
<exec executable="sh" osfamily="mac" failifexecutionfails="true" failonerror="true" >
<arg value="./bundle-messages.sh" />
<arg value="-p" />
</exec>
<exec executable="sh" osfamily="windows" failifexecutionfails="true" failonerror="true" >
<arg value="./bundle-messages.sh" />
<arg value="-p" />
</exec>
</target>
<target name="javadoc">
<mkdir dir="./build" />
<mkdir dir="./build/javadoc" />
<javadoc
sourcepath="./src/src/" destdir="./build/javadoc"
packagenames="*"
use="true"
splitindex="true"
windowtitle="susimail" />
</target>
<target name="clean">
<delete dir="src/WEB-INF/classes"/>
<delete file="susimail.war"/>
</target>
<target name="cleandep" depends="clean" />
<target name="distclean" depends="clean" />
</project>