summaryrefslogtreecommitdiff
path: root/build.xml
diff options
context:
space:
mode:
authorJosh Suereth <joshua.suereth@gmail.com>2012-03-14 09:03:38 -0400
committerJosh Suereth <joshua.suereth@gmail.com>2012-03-16 12:07:03 -0400
commit0574a3fa71b62eca54e6bf63c8d2cd19afb4c336 (patch)
treef0f7537ca2a6a09f2e5f36efd2ce9fd71c1fcb92 /build.xml
parentc3bff042546a343f260e2ef8be01665671db1043 (diff)
downloadscala-0574a3fa71b62eca54e6bf63c8d2cd19afb4c336.tar.gz
scala-0574a3fa71b62eca54e6bf63c8d2cd19afb4c336.tar.bz2
scala-0574a3fa71b62eca54e6bf63c8d2cd19afb4c336.zip
Moved to Mirco's versioning idea.
Conflicts: build.xml
Diffstat (limited to 'build.xml')
-rw-r--r--build.xml28
1 files changed, 17 insertions, 11 deletions
diff --git a/build.xml b/build.xml
index 20f953cd4f..3bc905887e 100644
--- a/build.xml
+++ b/build.xml
@@ -166,6 +166,8 @@ PROPERTIES
<!-- Loads custom properties definitions -->
<property file="${basedir}/build.properties"/>
+ <!-- Generating version number -->
+ <property file="${basedir}/build.number"/>
<!-- Additional command line arguments for scalac. They are added to all build targets -->
<property name="scalac.args" value=""/>
@@ -237,16 +239,27 @@ INITIALISATION
</target>
<!-- Determines OSGi string + maven extension. -->
+ <target name="init.hasbuildnum">
+ <condition property="version.hasbuildnum">
+ <not><equals arg1="${version.bnum}" arg2="0"/></not>
+ </condition>
+ </target>
<target name="init.build.snapshot" unless="build.release">
- <property name="version.suffix" value="DEV"/>
+ <property name="version.suffix" value="dev"/>
<property name="maven.version.suffix" value="-SNAPSHOT"/>
</target>
- <target name="init.build.release" if="build.release">
- <property name="version.suffix" value="FINAL"/>
+ <target name="init.build.release" if="build.release" unless="version.hasbuildnum" depends="init.hasbuildnum">
+ <property name="version.suffix" value="v0"/>
<property name="maven.version.suffix" value=""/>
</target>
+ <!-- funny thing, ant is. Can only specify *one* property in if check. Guaranteed that both are true here,
+ since properties are immutable. -->
+ <target name="init.build.patch.release" if="version.hasbuildnum" depends="init.hasbuildnum, init.build.snapshot">
+ <property name="version.suffix" value="v${version.bnum}"/>
+ <property name="maven.version.suffix" value="-${version.bnum}"/>
+ </target>
- <target name="init.build.suffix.done" depends="init.build.snapshot, init.build.release"/>
+ <target name="init.build.suffix.done" depends="init.build.snapshot, init.build.release, init.build.patch.release"/>
<target name="init" depends="init.jars, init.build.suffix.done">
<!-- scalac.args.optimise is selectively overridden in certain antcall tasks. -->
@@ -275,9 +288,6 @@ INITIALISATION
<property name="version.number" value="-unknown-"/>
<property name="init.avail" value="yes"/>
-
- <!-- Generating version number -->
- <property file="${basedir}/build.number"/>
<!-- We use the git describe to determine the OSGi modifier for our build. -->
<property
name="version.number"
@@ -317,9 +327,6 @@ INITIALISATION
<path refid="lib.extra"/>
</path>
-<<<<<<< HEAD
- <!-- Define tasks that can be run with Starr -->
-=======
<!-- And print-out what we are building -->
<echo message=" build time: ${time.human}" />
<echo message=" java version: ${java.vm.name} ${java.version}" />
@@ -330,7 +337,6 @@ INITIALISATION
<echo message=" OSGi version: ${version.number}" />
<!-- Define tasks that can be run with Starr -->
->>>>>>> 6ec24f1611... Fixes to build numbering system for 2.9.x release
<path id="starr.classpath">
<pathelement location="${lib.starr.jar}"/>
<pathelement location="${comp.starr.jar}"/>