ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hi...@apache.org
Subject svn commit: r662190 - in /ant/ivy/ivyde/trunk: ./ build.properties build.xml builder/component/build.properties org.apache.ivyde.eclipse/ org.apache.ivyde.eclipse/build.properties org.apache.ivyde.eclipse/build.xml org.apache.ivyde.eclipse/ivy.xml
Date Sun, 01 Jun 2008 09:52:29 GMT
Author: hibou
Date: Sun Jun  1 02:52:29 2008
New Revision: 662190

URL: http://svn.apache.org/viewvc?rev=662190&view=rev
Log:
Improve the build system:
 - add source packaging
 - when doing official release, do not append the timestamp
 - in the feature zip, do not prefix with an eclipse folder
 - remove the obsolete build.xml
 - add a local.build.properties to avoid specifying everytime baseLocation

Added:
    ant/ivy/ivyde/trunk/build.properties   (with props)
Removed:
    ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/build.xml
    ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/ivy.xml
Modified:
    ant/ivy/ivyde/trunk/   (props changed)
    ant/ivy/ivyde/trunk/build.xml
    ant/ivy/ivyde/trunk/builder/component/build.properties
    ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/   (props changed)
    ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/build.properties

Propchange: ant/ivy/ivyde/trunk/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Sun Jun  1 02:52:29 2008
@@ -0,0 +1,2 @@
+local.build.properties
+

Added: ant/ivy/ivyde/trunk/build.properties
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/build.properties?rev=662190&view=auto
==============================================================================
--- ant/ivy/ivyde/trunk/build.properties (added)
+++ ant/ivy/ivyde/trunk/build.properties Sun Jun  1 02:52:29 2008
@@ -0,0 +1 @@
+version.qualifier=alpha1

Propchange: ant/ivy/ivyde/trunk/build.properties
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: ant/ivy/ivyde/trunk/build.properties
------------------------------------------------------------------------------
    svn:keywords = Date Revision Author HeadURL Id

Modified: ant/ivy/ivyde/trunk/build.xml
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/build.xml?rev=662190&r1=662189&r2=662190&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/build.xml (original)
+++ ant/ivy/ivyde/trunk/build.xml Sun Jun  1 02:52:29 2008
@@ -16,7 +16,29 @@
    specific language governing permissions and limitations
    under the License.    
 -->
-<project name="ivyde" basedir="." default="build">
+<!--
+   This build script expects two properties:
+- version.qualifier : defines which version append to the version defined in the manifests.
+                      It will probably be "alpha1", "beta4", "RC1" or even "patch-4".
+- baseLocation      : the full path to the SDK version of Eclipse in order to build the binary
jars.
+
+   Properties could be set in the two files :
+- build.properties       : properties shared between developers, so under version control.
+                           The version.qualifier property should be set there.
+- local.build.properties : properties handled by developers, ignored by subversion.
+                           The baseLocation property should be set there.
+-->
+<project name="ivyde" basedir="." default="all">
+
+    <property file="local.build.properties" />
+    <property file="build.properties" />
+
+    <target name="/release" description="Make the build artifacts tagged with the release
version">
+        <property name="forceContextQualifier" value="${version.qualifier}" />
+        <property name="generateFeatureVersionSuffix" value="false" />
+	</target>
+
+    <target name="all" depends="build,sources" description="Build the sources and binaries
artifacts"/>
 
     <target name="eclipse-startup-check">
         <fail message="An Eclipse install is needed to run the build. Set your Eclipse
install dir into the baseLocation property." unless="baseLocation" />
@@ -56,8 +78,25 @@
         <property name="eclipse.classpath" value="${equinox.launcher.jar.location}" />
     </target>
 
-    <target name="build" depends="eclipse-startup-classpath,eclipse-launcher-classpath">
-        <tstamp />
+    <target name="timestamp">
+	    <tstamp />
+	</target>
+
+    <target name="compute-version" depends="timestamp">
+        <property name="forceContextQualifier" value="${version.qualifier}-${DSTAMP}${TSTAMP}"/>
+        <property name="generateFeatureVersionSuffix" value="true" />
+        <loadfile srcfile="org.apache.ivyde.eclipse/META-INF/MANIFEST.MF" property="build.version">
+            <filterchain>
+                <linecontainsregexp>
+                    <regexp pattern="Bundle-Version:.*"/>
+                </linecontainsregexp>
+                <replaceregex pattern="Bundle-Version: (.*)qualifier" replace="\1${forceContextQualifier}"/>
+                <striplinebreaks/>
+            </filterchain>
+        </loadfile>
+	</target>
+
+    <target name="build" depends="eclipse-startup-classpath,eclipse-launcher-classpath,compute-version"
description="Build the plugin distribution binaries">
         <java classpath="${eclipse.classpath}" classname="org.eclipse.core.launcher.Main"
fork="true" failonerror="true">
             <arg value="-clean" />
             <arg value="-consolelog" />
@@ -68,14 +107,46 @@
             <sysproperty key="buildDirectory" path="${basedir}/work" />
             <sysproperty key="DSTAMP" value="${DSTAMP}" />
             <sysproperty key="TSTAMP" value="${TSTAMP}" />
+            <sysproperty key="forceContextQualifier" value="${forceContextQualifier}"
/>
+            <sysproperty key="generateFeatureVersionSuffix" value="${generateFeatureVersionSuffix}"
/>
+            <sysproperty key="build.version" value="${build.version}" />
             <sysproperty key="javacDebugInfo" value="true"/>
         </java>
         <echo>
 Zip archive can be found here:
-  ${basedir}/work/${DSTAMP}${TSTAMP}/org.apache.ivyde.feature-${DSTAMP}${TSTAMP}.zip
+  ${basedir}/work/${build.version}/org.apache.ivyde.feature-${build.version}.zip
         </echo>
     </target>
 
+    <target name="sources" depends="compute-version" description="Create source archive
files">
+    	<mkdir dir="${basedir}/work/${build.version}"/>
+        <jar destfile="${basedir}/work/${build.version}/apache-ivyde-sources-${build.version}.jar">
+            <manifest>
+                <attribute name="Specification-Title" value="Apache IvyDE sources" />
+                <attribute name="Specification-Version" value="${build.version}" />
+                <attribute name="Specification-Vendor" value="Apache Software Foundation"
/>
+            </manifest>
+            <fileset dir=".">
+	            <include name="build.xml" />
+                <include name="builder/**" />
+                <include name="org.apache.ivyde.eclipse/plugin.xml"/>
+                <include name="org.apache.ivyde.eclipse/build.properties"/>
+                <include name="org.apache.ivyde.eclipse/**/*.java"/>
+                <include name="org.apache.ivyde.eclipse/icons/**"/>
+                <include name="org.apache.ivyde.eclipse/META_INF/**"/>
+                <include name="org.apache.ivyde.eclipse/CHANGES.txt"/>
+                <include name="org.apache.ivyde.eclipse/LICENCE.txt"/>
+                <include name="org.apache.ivyde.eclipse/.project"/>
+                <include name="org.apache.ivyde.eclipse/.classpath"/>
+                <include name="org.apache.ivyde.eclipse/.settings/**"/>
+                <include name="org.apache.ivyde.feature/feature.xml"/>
+                <include name="org.apache.ivyde.feature/build.properties"/>
+                <include name="org.apache.ivyde.feature/.project"/>
+                <include name="org.apache.ivyde.feature/.classpath"/>
+	        </fileset>
+        </jar>
+	</target>
+
     <target name="clean">
         <delete dir="${basedir}/work" />
     </target>

Modified: ant/ivy/ivyde/trunk/builder/component/build.properties
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/builder/component/build.properties?rev=662190&r1=662189&r2=662190&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/builder/component/build.properties (original)
+++ ant/ivy/ivyde/trunk/builder/component/build.properties Sun Jun  1 02:52:29 2008
@@ -20,7 +20,7 @@
 runPackager=true
 
 # The prefix that will be used in the generated archive.
-archivePrefix=eclipse
+archivePrefix=
 
 # The location underwhich all of the build output will be collected.
 collectingFolder=${archivePrefix}
@@ -93,10 +93,10 @@
 buildType=I
 
 # ID of the build.  Used in naming the build output.
-buildId=${DSTAMP}${TSTAMP}
+buildId=${build.version}
 
 # Label for the build.  Used in naming the build output
-buildLabel=${DSTAMP}${TSTAMP}
+buildLabel=${build.version}
 
 #The value to be used for the qualifier of a plugin or feature when you want to override
the value computed by pde.
 #The value will only be applied to plugin or features indicating build.properties, qualifier
= context 

Propchange: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/
------------------------------------------------------------------------------
--- svn:ignore (original)
+++ svn:ignore Sun Jun  1 02:52:29 2008
@@ -1,2 +1 @@
-lib
-build
+bin

Modified: ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/build.properties
URL: http://svn.apache.org/viewvc/ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/build.properties?rev=662190&r1=662189&r2=662190&view=diff
==============================================================================
--- ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/build.properties (original)
+++ ant/ivy/ivyde/trunk/org.apache.ivyde.eclipse/build.properties Sun Jun  1 02:52:29 2008
@@ -16,17 +16,6 @@
 #	 * specific language governing permissions and limitations
 #	 * under the License.
 #	 ***************************************************************
-lib.dir=${basedir}/lib
-src.dir=${basedir}/src/java
-test.dir=${basedir}/test/java
-build.dir=${basedir}/build
-classes.build.dir=${basedir}/build/classes
-artifacts.build.dir=${basedir}/build/artifact
-
-ivy.minimum.javaversion=1.4
-debug.mode=on
-ivy.install.version=2.0.0-beta1
-
 source.ivyde-eclipse.jar = src/java/
 output.ivyde-eclipse.jar = bin/
 bin.includes = plugin.xml,\



Mime
View raw message