[DebianGIS-dev] r2829 - packages/openjump/trunk/debian

frankie at alioth.debian.org frankie at alioth.debian.org
Wed Apr 14 16:20:03 UTC 2010


Author: frankie
Date: 2010-04-14 16:20:02 +0000 (Wed, 14 Apr 2010)
New Revision: 2829

Added:
   packages/openjump/trunk/debian/build.xml
Log:
New ant script.


Added: packages/openjump/trunk/debian/build.xml
===================================================================
--- packages/openjump/trunk/debian/build.xml	                        (rev 0)
+++ packages/openjump/trunk/debian/build.xml	2010-04-14 16:20:02 UTC (rev 2829)
@@ -0,0 +1,270 @@
+<?xml version="1.0"?>
+<!--  =======================================================================
+      OpenJUMP build file. Based on the HttpUnit build file.
+
+      OpenJUMP Release Procedure:
+       - Update PDF documents (especially version history)
+       - Update SVN sandbox
+       - Commit SVN sandbox
+       - Change version in build.xml
+       - Run ant clean,dist-zip
+       - Tag CVS repository with the version number
+      ======================================================================= -->
+
+<project name="openjump" default="dist-zip" basedir="..">
+    <property name="name" value="openjump"/>
+    <property name="Name" value="OpenJUMP"/>
+    <!--property name="version" value="20050728"/-->
+    <property name="version" value="1.3.1"/>
+    <!-- The recommended setting for debug is "on", so that line numbers are included in stack traces. [Jon Aquino 2005-04-06] -->
+    <property name="debug" value="on"/>
+    <property name="deprecation" value="off"/>
+    <property name="targetversion" value="1.5"/>
+    <property name="sourceversion" value="1.5"/>
+    <property name="optimize" value="off"/>
+    <property name="src.dir" value="src"/>
+    <property name="lib.dir" value="lib"/>
+    <property name="etc.dir" value="etc"/>
+    <property name="scripts.dir" value="scripts"/>
+    <property name="docs.dir" value="doc"/>
+    <property name="build.dir" value="build"/>
+    <property name="build.classes" value="${build.dir}/classes"/>
+    <property name="javadoc.dir" value="${build.dir}/javadoc"/>
+    <property name="workbench.jar.name" value="openjump-workbench-${version}.jar" />
+    <property name="workbench.jar" value="${build.dir}/${workbench.jar.name}"/>
+    <property name="api.jar.name" value="openjump-api-${version}.jar" />
+    <property name="api.jar" value="${build.dir}/${api.jar.name}"/>
+    <property name="dist.dir" value="dist"/>
+    <property name="archive.dir" value="${dist.dir}/${name}-${version}"/>
+    <property name="archive.src.dir" value="${dist.dir}/${name}-src-${version}"/>
+    <property name="classpath" value=""/>
+    <selector id="resource.selector">
+        <and>
+            <or>
+                <filename name="**/*.properties" casesensitive="no"/>
+                <filename name="**/*.png" casesensitive="no"/>
+                <filename name="**/*.gif" casesensitive="no"/>
+                <filename name="**/*.java2xml" casesensitive="no"/>
+                <filename name="**/*.html" casesensitive="no"/>
+                <filename name="**/*.xml" casesensitive="no"/>
+                <filename name="**/*.txt" casesensitive="no"/>
+                <filename name="**/*.jpg" casesensitive="no"/>
+                <filename name="**/*.xsl" casesensitive="no"/>
+            </or>
+            <not>
+                <filename name="**/overview.html" casesensitive="no"/>
+            </not>
+            <not>
+                <filename name="**/package.html" casesensitive="no"/>
+            </not>
+        </and>
+    </selector>
+    <selector id="api.jar.selector">
+        <and>
+            <or>
+                <filename name="**/*.class" casesensitive="no"/>
+                <selector refid="resource.selector"/>
+            </or>
+            <or>
+                <filename name="com/**" casesensitive="no"/>
+                <filename name="org/**" casesensitive="no"/>
+                <filename name="de/**" casesensitive="no"/>
+            </or>
+            <not>
+                <or>
+                    <filename name="com/vividsolutions/jump/workbench/**" casesensitive="no"/>
+                    <filename name="com/vividsolutions/jump/demo/**" casesensitive="no"/>
+                </or>
+            </not>
+        </and>
+    </selector>
+    <selector id="workbench.jar.selector">
+        <and>
+            <or>
+                <filename name="**/*.class" casesensitive="no"/>
+                <selector refid="resource.selector"/>
+            </or>
+            <or>
+                <filename name="com/vividsolutions/jump/workbench/**" casesensitive="no"/>
+                <filename name="com/vividsolutions/jump/demo/**" casesensitive="no"/>
+                <filename name="language/**" casesensitive="no"/>
+                <filename name="versiondoc/**" casesensitive="no"/>
+            </or>
+        </and>
+    </selector>
+    <selector id="archive.src.selector">
+        <and>
+            <or>
+                <filename name="**/*.java" casesensitive="no"/>
+                <selector refid="resource.selector"/>
+            </or>
+            <or>
+                <filename name="com/**" casesensitive="no"/>
+                <filename name="org/**" casesensitive="no"/>
+                <filename name="de/**" casesensitive="no"/>
+                <!-- [sstein] added -->
+                <filename name="language/**" casesensitive="no"/>
+                <filename name="versiondoc/**" casesensitive="no"/>
+            </or>
+        </and>
+    </selector>
+
+    <!-- =================================================================== -->
+    <!-- Defines the classpath used for compilation and test.                -->
+    <!-- =================================================================== -->
+    <path id="base.classpath">
+        <fileset dir="${lib.dir}">
+            <include name="**/*.jar"/>
+        </fileset>
+    </path>
+
+    <!--  ===================================================================  -->
+    <!--  Prepares the build directory                                         -->
+    <!--  ===================================================================  -->
+    <target name="prepare">
+        <tstamp/>
+        <mkdir dir="${build.dir}"/>
+    </target>
+
+    <!--  ===================================================================  -->
+    <!--  Compiles the source code                                             -->
+    <!--  ===================================================================  -->
+    <target name="compile" depends="prepare">
+        <mkdir dir="${build.classes}"/>
+        <javac srcdir="${src.dir}" destdir="${build.classes}" debug="${debug}" deprecation="${deprecation}" optimize="${optimize}" target="${targetversion}" source="${sourceversion}">
+            <classpath refid="base.classpath"/>
+        </javac>
+        <copy todir="${build.classes}">
+            <fileset dir="${src.dir}" excludes="**/*.java,**/*.class"/>
+        </copy>
+    </target>
+
+    <!--  ===================================================================  -->
+    <!--  Creates the jar archive                                              -->
+    <!--  ===================================================================  -->
+    <!-- [sstein] new property -->
+    <property name="distpathprop" refid="base.classpath"/>
+        <!--                       -->
+    <target name="jar" depends="compile">
+<!--        <echo file="${build.dir}/info.txt">Manifest-Version: 1.0
+Sealed: false
+${Name}-Version: ${version}
+Build-Date: ${TODAY}
+Build-Time: ${TSTAMP}
+Class-Path: ${distpathprop}
+Main-Class: com.vividsolutions.jump.workbench.JUMPWorkbench
+</echo>-->
+        <!-- [sstein] eliminate absolute paths from manifest file -->
+        <replaceregexp file="${build.dir}/info.txt" match=":\\" replace="" flags="gs"/>
+        <replaceregexp file="${build.dir}/info.txt" match=":[^:;]*lib" replace=": lib" flags="gs"/>
+        <replaceregexp file="${build.dir}/info.txt" match=";[^:;]*lib" replace=" lib" flags="gs"/>
+        <!-- manifest="${build.dir}/info.txt" -->
+
+                <manifestclasspath property="manifest.classpath" jarfile="lib/bogus.jar">
+                        <classpath refid="base.classpath" />
+                </manifestclasspath>
+        <jar jarfile="${workbench.jar}">
+            <fileset dir="${build.classes}">
+                <selector refid="workbench.jar.selector"/>
+            </fileset>
+                        <manifest>
+                                <attribute name="Sealed" value="false" />
+                                <attribute name="${Name}-Version" value="${version}" />
+                                <attribute name="Build-Date" value="${TODAY}" />
+                                <attribute name="Build-Time" value="${TSTAMP}" />
+                                <attribute name="Class-Path" value="${manifest.classpath} ${workbench.jar.name} ${api.jar.name}" />
+                                <attribute name="Main-Class" value="com.vividsolutions.jump.workbench.JUMPWorkbench" />
+                        </manifest>
+        </jar>
+<!-- manifest="${build.dir}/info.txt" -->
+        <jar jarfile="${api.jar}">
+            <fileset dir="${build.classes}">
+                <selector refid="api.jar.selector"/>
+            </fileset>
+                        <manifest>
+                                <attribute name="Sealed" value="false" />
+                                <attribute name="${Name}-Version" value="${version}" />
+                                <attribute name="Build-Date" value="${TODAY}" />
+                                <attribute name="Build-Time" value="${TSTAMP}" />
+                                <attribute name="Class-Path" value="${manifest.classpath} ${workbench.jar.name} ${api.jar.name}" />
+                                <attribute name="Main-Class" value="com.vividsolutions.jump.workbench.JUMPWorkbench" />
+                        </manifest>
+        </jar>
+    </target>
+
+    <!--  ===================================================================  -->
+    <!--  Creates the API documentation                                        -->
+    <!--  ===================================================================  -->
+    <target name="javadocs" depends="prepare">
+        <mkdir dir="${javadoc.dir}"/>
+        <javadoc destdir="${javadoc.dir}" use="true">
+            <classpath refid="base.classpath"/>
+            <packageset dir="${src.dir}">
+                <!-- include name="com/vividsolutions/**"/-->
+                <!-- [sstein 16 Jan 07] new: -->
+                <include name="com/**"/>
+                <include name="org/**"/>
+                <include name="de/**"/>
+            </packageset>
+        </javadoc>
+    </target>
+
+    <!--  ===================================================================  -->
+    <!--  Creates the distribution                                             -->
+    <!--  ===================================================================  -->
+    <target name="dist" depends="jar,javadocs">
+        <mkdir dir="${archive.dir}"/>
+        <copy todir="${archive.dir}/bin">
+            <fileset dir="${scripts.dir}"/>
+            <filterset>
+                <filter token="VERSION" value="${version}"/>
+            </filterset>
+        </copy>
+        <copy file="etc/log4j.xml" todir="${archive.dir}/bin"/>
+        <copy todir="${archive.dir}">
+            <fileset dir=".">
+                <include name="${lib.dir}/**"/>
+                <exclude name="**/junit.jar"/>
+                <include name="${docs.dir}/**"/>
+            </fileset>
+        </copy>
+        <copy file="${workbench.jar}" todir="${archive.dir}/lib"/>
+        <copy file="${api.jar}" todir="${archive.dir}/lib"/>
+        <mkdir dir="${archive.src.dir}"/>
+        <copy todir="${archive.src.dir}/javadoc">
+            <fileset dir="${javadoc.dir}"/>
+        </copy>
+        <copy todir="${archive.src.dir}/src">
+            <fileset dir="${src.dir}">
+                <selector refid="archive.src.selector"/>
+            </fileset>
+        </copy>
+        <!-- [sstein] added begin : copy also all other stuff to src-->
+        <copy todir="${archive.src.dir}">
+            <fileset dir=".">
+                <include name="${lib.dir}/**"/>
+                <exclude name="**/junit.jar"/>
+                <include name="${docs.dir}/**"/>
+                <include name="${etc.dir}/**"/>
+                <include name="${scripts.dir}/**"/>
+            </fileset>
+        </copy>
+        <!-- [sstein] added end -->
+    </target>
+
+    <!--  ===================================================================  -->
+    <!--  Packages the distribution with ZIP                                   -->
+    <!--  ===================================================================  -->
+    <target name="dist-zip" depends="dist">
+        <zip zipfile="${dist.dir}/${name}-${version}.zip" basedir="${dist.dir}" includes="${name}-${version}/**"/>
+        <zip zipfile="${dist.dir}/${name}-src-${version}.zip" basedir="${dist.dir}" includes="${name}-src-${version}/**"/>
+    </target>
+
+    <!--  ===================================================================  -->
+    <!--  Cleans up generated stuff                                            -->
+    <!--  ===================================================================  -->
+    <target name="clean">
+        <delete dir="${build.dir}"/>
+        <delete dir="${dist.dir}"/>
+    </target>
+</project>




More information about the Pkg-grass-devel mailing list