Index: trunk/build.xml
===================================================================
--- trunk/build.xml	(revision 9079)
+++ trunk/build.xml	(revision 9133)
@@ -15,4 +15,5 @@
     <property name="javacc.home" location="tools"/>
     <property name="mapcss.dir" location="${src.dir}/org/openstreetmap/josm/gui/mappaint/mapcss"/>
+    <property name="epsg.output" location="data/projection/custom-epsg"/>
     <property name="groovy.jar" location="tools/groovy-all-2.4.5.jar"/>
     <!-- build parameter: compression level (ant -Dclevel=N)
@@ -101,5 +102,5 @@
       ** Main target that builds JOSM and checks XML against schemas
     -->
-    <target name="dist" depends="compile,create-revision,check-schemas">
+    <target name="dist" depends="compile,create-revision,check-schemas,epsg">
         <echo>Revision ${version.entry.commit.revision}</echo>
         <copy file="CONTRIBUTION" todir="build"/>
@@ -287,8 +288,10 @@
     <target name="clean">
         <delete dir="build"/>
+        <delete dir="build2"/>
         <delete dir="dist"/>
         <delete dir="${mapcss.dir}/parsergen"/>
         <delete file="${src.dir}/org/w3/_2001/xmlschema/Adapter1.java"/>
         <delete dir="${src.dir}/org/openstreetmap/josm/data/imagery/types"/>
+        <delete file="${epsg.output}"/>
     </target>
     <path id="test.classpath">
@@ -640,3 +643,21 @@
         </java>
     </target>
+    <!-- compile build script for generating projection list -->
+    <target name="epsg-compile" depends="compile">
+        <mkdir dir="build2"/>
+        <javac sourcepath="" srcdir="scripts"
+            destdir="build2" target="1.7" source="1.7" debug="on" includeantruntime="false" createMissingPackageInfoClass="false" encoding="UTF-8" classpath="build">
+        </javac>
+    </target>
+    <!-- generate projection list -->
+    <target name="epsg" depends="epsg-compile">
+        <touch file="${epsg.output}"/>
+        <java classname="BuildProjectionDefinitions">
+            <classpath>
+                <pathelement path="."/>
+                <pathelement path="build"/>
+                <pathelement path="build2"/>
+            </classpath>
+        </java>
+    </target>
 </project>
