Changeset ff520b7 for build.xml


Ignore:
Timestamp:
May 20, 2011 1:13:26 PM (10 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
0e719b8e
Parents:
08d24b0 (diff), 48bf618 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

propagate from branch 'i2p.i2p.libgmp' (head 41a57954f7e78e57f8eb5e30e8ebde7fd75b15dc)

to branch 'i2p.i2p' (head d174e772ebd4f3e3eac5c9b5abd7f736c2527eb2)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • build.xml

    r08d24b0 rff520b7  
    3333        <echo message="  distclean: clean up all derived files" />
    3434        <echo message="  syndie:    generate a standalone syndie install" />
     35        <echo message="  desktopgui: generate a standalone desktopgui install" />
    3536        <echo message="  i2psnark:  generate a standalone i2psnark install" />
    3637        <echo message="  justBOB:  generate a standalone BOB-one.jar" />
     
    4142        <echo message="          (libc6-i686 and libc6-amd64 required, ant>=1.8 required)" />
    4243        <echo message="  debianrepo: build a Debian repository (reprepro required)" />
    43         <echo message="  updaterWithDesktopgui: tar the built files and desktopgui in an i2pupdate.zip" />
    44         <echo message="  pkgWithDesktopgui: distclean then package everything up with the desktopgui" />
    45         <echo message="  distWithDesktopgui: pkgWithDesktopgui and javadoc" />
    46         <echo message="  distcleanWithDesktopgui: clean up all derived files (including desktopgui files)" />
    4744        <echo message="  poupdate: update the .po files for translators" />
    48     </target>
     45        <echo message="  pkg-portable-win32:  build a minimum portable version for win32" />
     46   </target>
    4947    <target name="debianhowto">
    5048        <echo message="To build debian packages, you must run dpkg-buildpackage as root in the source directory. It will then run ant for you. dpkg-buildpackage is found in the 'dpkg-dev' package. Also it should work fine to use the 'fakeroot' package with dpkg-buildpackage, if you don't want to run as root. Please read 'man dpkg-buildpackage' before building any packages yourself." />
     
    6563    <target name="builddep" depends="builddepSmall, buildBOB, buildSAM, buildSusiMail, buildSusiDNS, buildI2PSnark" />
    6664
    67     <target name="builddepSmall" depends="buildrouter, buildSystray, buildRouterConsole, buildStreaming, buildI2PTunnel, buildAddressbook" />
     65    <target name="builddepSmall" depends="buildrouter, buildSystray, buildDesktopGui, buildRouterConsole, buildStreaming, buildI2PTunnel, buildAddressbook" />
    6866
    6967    <!-- start of buildX, one for each sub-build.xml.
     
    7270      -->
    7371
    74     <!-- TODO remove I2PTunnel dependency in BOB -->
    75     <target name="buildBOB" depends="buildStreaming, buildI2PTunnel" >
     72    <target name="buildBOB" depends="buildStreaming" >
    7673        <ant dir="apps/BOB/" target="jar" />
    7774    </target>
     
    10198    </target>
    10299
    103     <target name="buildRouterConsole" depends="buildrouter, buildSystray, buildJetty" >
     100    <target name="buildDesktopGui" depends="buildCore, buildrouter" >
     101<!--
     102        <ant dir="apps/desktopgui" target="clean" />
     103-->
     104        <ant dir="apps/desktopgui" target="jar" />
     105    </target>
     106
     107    <target name="buildRouterConsole" depends="buildrouter, buildSystray, buildDesktopGui, buildJetty" >
    104108        <ant dir="apps/routerconsole/java/" target="jar" />
    105109    </target>
    106110
    107     <target name="buildJetty" >
     111    <target name="buildJetty" depends="buildProperties" >
    108112        <ant dir="apps/jetty" target="build" />
    109113    </target>
     
    127131    </target>
    128132
    129     <target name="buildCore" >
     133    <target name="buildCore" depends="buildProperties" >
    130134        <ant dir="core/java/" target="jar" />
    131135        <copy file="core/java/build/i2p.jar" todir="build/" />
     136    </target>
     137
     138    <target name="buildProperties" >
     139        <exec executable="mtn" outputproperty="workspace.version" errorproperty="mtn.error1" failifexecutionfails="false" >
     140            <arg value="automate" />
     141            <arg value="get_base_revision_id" />
     142        </exec>
     143        <tstamp>
     144            <format property="build.timestamp" pattern="yyyy-MM-dd HH:mm:ss z" timezone="UTC" locale="en" />
     145        </tstamp>
    132146    </target>
    133147
     
    165179        <ant target="doBuildEXE" />
    166180    </target>
    167     <target name="doBuildEXE" unless="noExe">
     181    <target name="doBuildEXE" depends="buildProperties" unless="noExe">
    168182        <jar destfile="./build/launchi2p.jar">
    169183            <manifest>
    170184             <attribute name="Main-Class" value="net.i2p.router.RouterLaunch" />
    171              <attribute name="Class-Path" value="lib/i2p.jar lib/router.jar lib/jbigi.jar lib/BOB.jar lib/sam.jar lib/mstreaming.jar lib/streaming.jar lib/routerconsole.jar lib/i2ptunnel.jar lib/org.mortbay.jetty.jar lib/javax.servlet.jar lib/jasper-compiler.jar lib/jasper-runtime.jar lib/commons-logging.jar lib/commons-el.jar lib/wrapper.jar lib/systray.jar lib/systray4j.jar" />
     185             <attribute name="Class-Path" value="lib/i2p.jar lib/router.jar lib/jbigi.jar lib/BOB.jar lib/sam.jar lib/mstreaming.jar lib/streaming.jar lib/routerconsole.jar lib/i2ptunnel.jar lib/org.mortbay.jetty.jar lib/javax.servlet.jar lib/jasper-compiler.jar lib/jasper-runtime.jar lib/commons-logging.jar lib/commons-el.jar lib/wrapper.jar lib/systray.jar lib/systray4j.jar lib/desktopgui.jar" />
     186             <attribute name="Build-Date" value="${build.timestamp}" />
     187             <attribute name="Base-Revision" value="${workspace.version}" />
    172188            </manifest>
    173189        </jar>
     
    197213        <copy file="apps/i2ptunnel/java/build/i2ptunnel.war" todir="build/" />
    198214        <copy file="apps/systray/java/build/systray.jar" todir="build/" />
     215        <copy file="apps/desktopgui/dist/desktopgui.jar" todir="build/" />
     216        <copy file="installer/lib/jbigi/jbigi.jar" todir="build" />
    199217        <copy file="apps/addressbook/dist/addressbook.war" todir="build/" />
    200218    </target>
     
    219237
    220238    <!-- the apps need to compile the jsps to poupdate -->
    221     <target name="poupdate" depends="buildRouter, buildStreaming, buildSystray, buildJetty" >
     239    <target name="poupdate" depends="buildRouter, buildStreaming, buildSystray, buildJetty, buildDesktopGui" >
     240        <echo message="Setting environment variable LG2 to a lang code (eg: de,zh,nl etc)" />
     241        <echo message=" will restrict language update to the language you specified, leaving other language untact." />
    222242        <ant dir="apps/routerconsole/java/" target="poupdate" />
    223243        <ant dir="apps/i2psnark/java/" target="poupdate" />
    224244        <ant dir="apps/i2ptunnel/java/" target="poupdate" />
    225245        <ant dir="apps/susidns/src/" target="poupdate" />
     246        <ant dir="apps/susimail/" target="poupdate" />
     247        <ant dir="apps/desktopgui" target="poupdate" />
    226248    </target>
    227249    <target name="javadoc">
     
    269291            <group title="SusiMail Application" packages="i2p.susi.webmail:i2p.susi.webmail.*:i2p.susi.debug:i2p.susi.util" />
    270292            <group title="Systray Application" packages="net.i2p.apps.systray" />
     293            <group title="Desktopgui Application" packages="net.i2p.desktopgui.*" />
    271294            <sourcepath>
    272295                <pathelement location="core/java/src" />
     
    278301                <pathelement location="apps/i2ptunnel/java/src" />
    279302                <pathelement location="apps/systray/java/src" />
     303                <pathelement location="apps/desktopgui/src" />
    280304                <pathelement location="apps/routerconsole/java/src" />
    281305                <pathelement location="apps/addressbook/java/src" />
     
    324348        <ant dir="apps/sam/java/" target="distclean" />
    325349        <ant dir="apps/BOB" target="clean" />
     350        <ant dir="apps/desktopgui" target="clean" />
    326351        <ant dir="apps/routerconsole/java/" target="distclean" />
    327352        <ant dir="apps/addressbook/" target="distclean" />
     
    404429        <copy file="installer/resources/install_i2p_service_winnt.bat" todir="pkg-temp/" />
    405430        <copy file="installer/resources/postinstall.bat" todir="pkg-temp/" />
     431        <copy file="installer/resources/set_config_dir_for_nt_service.bat" todir="pkg-temp/" />
    406432        <copy file="installer/resources/uninstall_i2p_service_winnt.bat" todir="pkg-temp/" />
    407433        <copy todir="pkg-temp/lib/wrapper/win32/">
     
    449475        <copy file="build/org.mortbay.jetty.jar" todir="pkg-temp/lib/" />
    450476        <copy file="build/router.jar" todir="pkg-temp/lib/" />
     477        <copy file="build/desktopgui.jar" todir="pkg-temp/lib/" />
    451478        <copy file="build/routerconsole.jar" todir="pkg-temp/lib/" />
    452479        <!-- pulled out of routerconsole.jar in 0.7.12; name without version so we can overwrite if we upgrade  -->
     
    491518        <mkdir dir="pkg-temp/eepsite/docroot/help/lib" />
    492519        <copy todir="pkg-temp/eepsite/docroot/" >
    493             <fileset dir="installer/resources/eepsite.help/"  includes="robots.txt index.html help/pagetemplate.html help/index*.html **/*.png **/*.css" />
     520            <fileset dir="installer/resources/eepsite.help/" />
     521        </copy>
     522        <copy todir="pkg-temp/eepsite/docroot/help/lib/" >
     523            <fileset dir="installer/resources/icons/flags/" includes="cn.png de.png es.png fr.png ir.png it.png jp.png nl.png ru.png se.png us.png" />
    494524        </copy>
    495525        <copy file="installer/resources/themes/console/images/favicon.ico" tofile="pkg-temp/eepsite/docroot/favicon.ico" />
     
    551581          <fileset dir="installer/resources/readme/" includes="readme*.html" />
    552582          <fileset dir="installer/resources/proxy/" includes="*.ht" />
     583          <!-- lang_ar.png added in 0.8.4 -->
     584          <fileset dir="installer/resources/" includes="icons/flags/lang_ar.png" />
    553585        </copy>
    554586    </target>
     
    619651        <!-- include systray changes in 0.7.5 -->
    620652        <copy file="build/systray.jar" todir="pkg-temp/lib/" />
     653        <copy file="build/desktopgui.jar" todir="pkg-temp/lib/" />
    621654        <copy file="build/susimail.war" todir="pkg-temp/webapps/" />
    622655        <copy file="build/susidns.war" todir="pkg-temp/webapps/" />
     
    681714        <copy file="build/org.mortbay.jetty.jar" todir="pkg-temp/lib/" />
    682715    </target>
    683     <target name="installer" depends="preppkg">
     716    <target name="installer" depends="preppkg, buildProperties">
    684717        <taskdef name="izpack" classpath="${basedir}/installer/lib/izpack/standalone-compiler.jar" classname="com.izforge.izpack.ant.IzPackTask" />
    685718        <mkdir dir="pkg-temp/installer" />
     719        <exec executable="mtn" outputproperty="workspace.changes.util" errorproperty="mtn.error.util" failifexecutionfails="false" >
     720            <arg value="list" />
     721            <arg value="changed" />
     722            <arg value="core/java/src/net/i2p/util" />
     723        </exec>
     724        <!-- \n in an attribute value generates an invalid manifest -->
     725        <exec executable="tr" inputstring="${workspace.changes.util}" outputproperty="workspace.changes.util.tr" errorproperty="mtn.error2" failifexecutionfails="false" >
     726            <arg value="-s" />
     727            <arg value="[:space:]" />
     728            <arg value="," />
     729        </exec>
    686730        <jar destfile="./pkg-temp/installer/copy.jar" basedir="./core/java/build/obj" includes="net/i2p/util/Copy.class net/i2p/util/FileUtil.class">
    687             <manifest><attribute name="Main-Class" value="net.i2p.util.Copy" /></manifest>
     731            <manifest>
     732                <attribute name="Main-Class" value="net.i2p.util.Copy" />
     733                <attribute name="Build-Date" value="${build.timestamp}" />
     734                <attribute name="Base-Revision" value="${workspace.version}" />
     735                <attribute name="Workspace-Changes" value="${workspace.changes.util.tr}" />
     736            </manifest>
    688737        </jar>
    689738        <jar destfile="./pkg-temp/installer/delete.jar" basedir="./core/java/build/obj" includes="net/i2p/util/Delete.class net/i2p/util/FileUtil.class">
    690             <manifest><attribute name="Main-Class" value="net.i2p.util.Delete" /></manifest>
     739            <manifest>
     740                <attribute name="Main-Class" value="net.i2p.util.Delete" />
     741                <attribute name="Build-Date" value="${build.timestamp}" />
     742                <attribute name="Base-Revision" value="${workspace.version}" />
     743                <attribute name="Workspace-Changes" value="${workspace.changes.util.tr}" />
     744            </manifest>
    691745        </jar>
    692746        <jar destfile="./pkg-temp/installer/exec.jar" basedir="./core/java/build/obj" includes="net/i2p/util/Exec.class">
    693             <manifest><attribute name="Main-Class" value="net.i2p.util.Exec" /></manifest>
     747            <manifest>
     748                <attribute name="Main-Class" value="net.i2p.util.Exec" />
     749                <attribute name="Build-Date" value="${build.timestamp}" />
     750                <attribute name="Base-Revision" value="${workspace.version}" />
     751                <attribute name="Workspace-Changes" value="${workspace.changes.util.tr}" />
     752            </manifest>
    694753        </jar>
    695754        <!--
     
    732791        <!-- thazzit -->
    733792    </target>
    734     <target name="test">
     793
     794    <target name="test" depends="buildProperties" >
    735795        <ant dir="core/java/" target="test" />
    736796    </target>
    737     <target name="junit.report">
     797    <target name="junit.report" depends="buildProperties" >
    738798        <ant dir="core/java/" target="junit.report" />
    739799    </target>
    740     <target name="clover.report">
     800    <target name="clover.report" depends="buildProperties" >
    741801        <ant dir="core/java/" target="clover.report" />
    742802    </target>
    743803    <target name="test.report" depends="junit.report, clover.report"/>
    744     <target name="fulltest">
     804    <target name="fulltest" depends="buildProperties" >
    745805                <ant dir="core/java/" target="fulltest" />
    746806                <ant dir="router/java/" target="fulltest" />
    747807    </target>
    748     <target name="fullclovertest">
     808    <target name="fullclovertest" depends="buildProperties" >
    749809                <ant dir="core/java/" target="fullclovertest" />
    750810                <ant dir="router/java/" target="fullclovertest" />
    751811    </target>
     812
    752813    <target name="syndie" >
    753814        <ant dir="apps/syndie/java/" target="standalone" />
    754815        <copy file="apps/syndie/java/syndie-standalone.zip" todir="." />
    755816    </target>
    756     <target name="i2psnark">
     817    <target name="i2psnark" depends="buildProperties" >
    757818        <ant dir="apps/i2psnark/java" target="standalone" />
    758819        <copy file="apps/i2psnark/java/i2psnark-standalone.zip" todir="." />
     
    792853            <arg value="build/mstreaming.jar"/>
    793854            <arg value="build/router.jar/"/>
     855            <arg value="build/desktopgui.jar"/>
    794856            <arg value="build/routerconsole.jar"/>
    795857            <arg value="build/routerconsole.war"/>
     
    802864        <echo message="Findbugs output stored in i2p.fba" />
    803865        <echo message="Now run: findbugs i2p.fba" />
    804     </target>
    805     <target name="buildWithDesktopgui" depends="buildrouter,builddepSmall">
    806         <ant dir="apps/desktopgui" target="build_jar" />
    807     </target>
    808     <target name="preppkgWithDesktopgui" depends="buildWithDesktopgui,preppkg">
    809         <copy file="apps/desktopgui/dist/desktopgui.jar" todir="pkg-temp/lib/" />
    810         <copy file="apps/desktopgui/lib/swing-worker.jar" todir="pkg-temp/lib/" />
    811         <copy file="apps/desktopgui/lib/appframework.jar" todir="pkg-temp/lib/" />
    812         <mkdir dir="pkg-temp/desktopgui/resources/" />
    813         <copy todir="pkg-temp/desktopgui/resources/">
    814             <fileset dir="apps/desktopgui/desktopgui/resources/" />
    815         </copy>
    816     </target>
    817     <target name="installerWithDesktopgui" depends="preppkgWithDesktopgui,installer" />
    818     <target name="prepupdateWithDesktopgui" depends="buildWithDesktopgui,prepupdate">
    819         <copy file="apps/desktopgui/dist/desktopgui.jar" todir="pkg-temp/lib/" />
    820         <copy file="apps/desktopgui/lib/swing-worker.jar" todir="pkg-temp/lib/" />
    821         <copy file="apps/desktopgui/lib/appframework.jar" todir="pkg-temp/lib/" />
    822         <mkdir dir="pkg-temp/desktopgui/resources/" />
    823         <copy todir="pkg-temp/desktopgui/resources/">
    824             <fileset dir="apps/desktopgui/desktopgui/resources/" />
    825         </copy>
    826     </target>
    827     <target name="updaterWithDesktopgui" depends="prepupdateWithDesktopgui,updater" />
    828     <target name="pkgWithDesktopgui" depends="distclean, updaterWithDesktopgui, installerWithDesktopgui, preppkg" />
    829     <target name="distWithDesktopgui" depends="pkgWithDesktopgui, javadoc" />
    830     <target name="distcleanWithDesktopgui" depends="distclean">
    831         <ant dir="apps/desktopgui" target="build_clean" />
    832866    </target>
    833867
     
    9851019    <target name="debian" depends="distclean, debian-source, debian-binary" />
    9861020
    987     <target name="debian-binary">
     1021    <target name="debian-binary" depends="buildProperties" >
    9881022        <echo message="Did you update the version in these files?" />
    9891023        <exec executable="ls" failonerror="true">
     
    10021036        </exec>
    10031037    </target>
    1004     <target name="debian-source">
     1038    <target name="debian-source" depends="buildProperties" >
    10051039        <!-- bundle the 20MB jetty 5 lib since there probably isn't a deb for it -->
    10061040        <ant dir="apps/jetty" target="ensureJettylib" />
Note: See TracChangeset for help on using the changeset viewer.