Browse Source

Updates to allow nightly snapshots of maven central-compatible artifacts

pull/23217/head
Ben Hale 15 years ago
parent
commit
265b82013d
  1. 1
      build-spring-framework/build.xml
  2. 131
      build-spring-framework/generate-pom.xml
  3. 2
      build-spring-framework/package-bundle.xml
  4. 2
      build-spring-framework/package-library.xml
  5. 101
      build-spring-framework/pom.xml
  6. 95
      build-spring-framework/publish-maven.xml
  7. 58
      build-spring-framework/publish.xml
  8. 13
      org.springframework.asm/build.xml
  9. 17
      org.springframework.spring-library/build.xml
  10. 5
      org.springframework.spring-parent/build.xml
  11. 2
      org.springframework.spring-parent/ivy.xml
  12. 11
      org.springframework.spring-parent/pom.xml
  13. 9
      org.springframework.web.struts/template.mf

1
build-spring-framework/build.xml

@ -2,6 +2,7 @@ @@ -2,6 +2,7 @@
<project name="build-spring-framework" default="precommit">
<path id="bundles">
<pathelement location="../org.springframework.spring-parent"/>
<pathelement location="../org.springframework.instrument"/>
<pathelement location="../org.springframework.instrument.tomcat"/>
<pathelement location="../org.springframework.asm"/>

131
build-spring-framework/generate-pom.xml

@ -1,131 +0,0 @@ @@ -1,131 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="generate-poms" xmlns:ivy="antlib:org.apache.ivy.ant">
<property file="${basedir}/../build.properties"/>
<import file="${basedir}/../spring-build/multi-bundle/default.xml"/>
<path id="modules-to-process">
<pathelement location="../org.springframework.instrument"/>
<pathelement location="../org.springframework.instrument.tomcat"/>
<pathelement location="../org.springframework.asm"/>
<pathelement location="../org.springframework.core"/>
<pathelement location="../org.springframework.expression"/>
<pathelement location="../org.springframework.beans"/>
<pathelement location="../org.springframework.aop"/>
<pathelement location="../org.springframework.context"/>
<pathelement location="../org.springframework.transaction"/>
<pathelement location="../org.springframework.oxm"/>
<pathelement location="../org.springframework.jms"/>
<pathelement location="../org.springframework.aspects"/>
<pathelement location="../org.springframework.jdbc"/>
<pathelement location="../org.springframework.web"/>
<pathelement location="../org.springframework.orm"/>
<pathelement location="../org.springframework.context.support"/>
<pathelement location="../org.springframework.web.servlet"/>
<pathelement location="../org.springframework.web.portlet"/>
<pathelement location="../org.springframework.test"/>
<pathelement location="../org.springframework.web.struts"/>
</path>
<condition property="maven.extension" value=".bat" else="">
<os family="windows"/>
</condition>
<property name="mvn.exe" value="mvn${maven.extension}"/>
<target name="test">
<echo message="pom version = ${project.version}"/>
</target>
<target name="generate-pom" depends="ivy.init">
<all-bundles target="do-generate-pom" buildpathRef="modules-to-process"/>
</target>
<target name="generate-pom-test">
<all-bundles target="do-generate-pom-test" buildpathRef="modules-to-process"/>
</target>
<target name="do-generate-pom" depends="ivy.init">
<delete file="pom.xml" quiet="true"/>
<delete file="central-pom.xml" quiet="true"/>
<ivy:makepom ivyfile="ivy.xml" pomfile="pom.xml">
<mapping conf="compile" scope="compile"/>
<mapping conf="test" scope="test"/>
<mapping conf="provided" scope="provided"/>
<mapping conf="runtime" scope="runtime"/>
</ivy:makepom>
<xmlproperty file="../org.springframework.spring-library/pom.xml"/>
<replaceregexp file="pom.xml"
match="&lt;version>.*?&lt;/version>"
replace="&lt;version>@project-version@&lt;/version>" />
<exec executable="${mvn.exe}" failonerror="true">
<arg line="org.springframework.build.repository:org.springframework.build.repository.maven:create-central"/>
</exec>
<move file="pom.xml" tofile="pom-bundle.xml"/>
<move file="central-pom.xml" tofile="pom.xml"/>
<replace file="pom.xml">
<replacetoken><![CDATA[ <version>@project-version@</version>]]></replacetoken>
<replacevalue><![CDATA[ <version>@project-version@</version>
<parent>
<groupId>org.springframework</groupId>
<artifactId>spring-parent</artifactId>
<relativePath>../org.springframework.spring-parent</relativePath>
<version>@project-version@</version>
</parent>
]]></replacevalue>
</replace>
<replace file="pom.xml" token="@project-version@" value="${project.version}"/>
<replace file="pom.xml" token="latest.integration" value="${project.version}"/>
<fixcrlf srcDir="."
eol="lf"
eof="remove"
includes="pom.xml"/>
</target>
<target name="remove-unresolved-references">
<!-- TODO in spring-context these are only found in S2 bundle repo, not maven central -->
<replace file="pom.xml">
<replacetoken><![CDATA[<dependency>
<groupId>com.oracle.oc4j</groupId>
<artifactId>oracle.classloader</artifactId>
<version>10.1.3.1</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.sun.enterprise</groupId>
<artifactId>com.sun.enterprise.loader</artifactId>
<version>1.0</version>
<scope>provided</scope>
</dependency>
]]></replacetoken>
<replacevalue><![CDATA[]]></replacevalue>
</replace>
</target>
<target name="do-generate-pom-test">
<exec executable="${mvn.exe}" failonerror="true">
<env key="MAVEN_TERMINATE_CMD" value="on" />
<arg line="-P stage,fast install"/>
</exec>
</target>
</project>

2
build-spring-framework/package-bundle.xml

@ -1,8 +1,6 @@ @@ -1,8 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="package-bundle">
<import file="publish-maven.xml"/>
<target name="package" depends="ivy.init">
<dist-jar/>
<src-jar/>

2
build-spring-framework/package-library.xml

@ -1,8 +1,6 @@ @@ -1,8 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="package-library">
<import file="publish-maven.xml"/>
<target name="package" depends="ivy.init">
<dist-jar/>
</target>

101
build-spring-framework/pom.xml

@ -1,101 +0,0 @@ @@ -1,101 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<!--
This POM cannot be used to build Spring; it is a work in progress and should only be used as
part of a Maven repository upload bundle using artifacts created by the spring build system.
-->
<modelVersion>4.0.0</modelVersion>
<groupId>org.springframework</groupId>
<artifactId>spring</artifactId>
<packaging>pom</packaging>
<version>3.0.1.BUILD-SNAPSHOT</version>
<name>Spring Framework</name>
<description>Spring is a layered Java/J2EE application platform, based on code published in Expert
One-on-One J2EE Design and Development by Rod Johnson (Wrox, 2002). </description>
<url>http://www.springframework.org</url>
<issueManagement>
<system>JIRA</system>
<url>http://jira.springframework.org/browse/SPR</url>
</issueManagement>
<ciManagement>
<system>Bamboo</system>
<url>https://build.springframework.org/browse/SPR</url>
</ciManagement>
<inceptionYear>2003</inceptionYear>
<organization>
<name>SpringSource</name>
<url>http://www.springsource.com</url>
</organization>
<licenses>
<license>
<name>The Apache Software License, Version 2.0</name>
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
<distribution>repo</distribution>
</license>
</licenses>
<scm>
<url>https://fisheye.springframework.org/browse/spring-framework</url>
<connection>scm:svn:https://src.springframework.org/svn/spring-framework/trunk</connection>
<developerConnection>scm:svn:https://src.springframework.org/svn/spring-framework/trunk</developerConnection>
</scm>
<mailingLists>
<mailingList>
<name> Spring Forum
</name>
<post>http://forum.springframework.org</post>
<archive>http://forum.springframework.org</archive>
</mailingList>
</mailingLists>
<modules>
<module>../org.springframework.spring-parent</module>
<module>../org.springframework.instrument</module>
<module>../org.springframework.instrument.tomcat</module>
<module>../org.springframework.asm</module>
<module>../org.springframework.core</module>
<module>../org.springframework.expression</module>
<module>../org.springframework.beans</module>
<module>../org.springframework.aop</module>
<module>../org.springframework.context</module>
<module>../org.springframework.transaction</module>
<module>../org.springframework.oxm</module>
<module>../org.springframework.jms</module>
<module>../org.springframework.aspects</module>
<module>../org.springframework.jdbc</module>
<module>../org.springframework.web</module>
<module>../org.springframework.orm</module>
<module>../org.springframework.context.support</module>
<module>../org.springframework.web.servlet</module>
<module>../org.springframework.web.portlet</module>
<module>../org.springframework.test</module>
<module>../org.springframework.web.struts</module>
</modules>
<profiles>
<profile>
<id>staging</id>
<distributionManagement>
<site>
<id>staging</id>
<url>file:///${user.dir}/target/staging</url>
</site>
<repository>
<id>staging</id>
<url>file:///${user.dir}/target/staging</url>
</repository>
<snapshotRepository>
<id>staging</id>
<url>file:///${user.dir}/target/staging</url>
</snapshotRepository>
</distributionManagement>
</profile>
</profiles>
</project>

95
build-spring-framework/publish-maven.xml

@ -1,95 +0,0 @@ @@ -1,95 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="publish-maven-central-only-pom" xmlns:maven="antlib:org.apache.maven.artifact.ant">
<description>
This build file publishes to a maven repository and two ways.
1. Publish jar, source-jar, and pom artifacts.
2. Publish only the pom artifact.
The additional complexity in the implementation is due to a bug in the maven ant tasks version 2.0.8 that
prevents deploying to a local file repository on windows.
</description>
<condition property="is.windows" value="windows">
<os family="windows"/>
</condition>
<!-- top level targets -->
<target name="publish-maven-central-only-pom-artifacts" depends="publish-central-only-pom-windows,publish-central-only-pom-unix">
</target>
<target name="publish-maven-central-code-artifacts" depends="publish-central-windows,publish-code-unix">
</target>
<target name="publish-maven-milestone-only-pom-artifacts" depends="maven.init">
<maven:deploy>
<remoteRepository url="s3://${publish.bucket}/maven/bundles/${adjusted.release.type}">
<authentication username="${accessKey}" passphrase="${secretKey}"/>
</remoteRepository>
<pom file="${local.pom.output.file}"/>
</maven:deploy>
</target>
<target name="publish-maven-milestone-code-artifacts" depends="maven.init">
<maven:deploy file="${jar.output.file}">
<remoteRepository url="s3://${publish.bucket}/maven/bundles/${adjusted.release.type}">
<authentication username="${accessKey}" passphrase="${secretKey}"/>
</remoteRepository>
<pom file="${pom.output.file}"/>
<attach file="${source-jar.output.file}" classifier="sources"/>
</maven:deploy>
</target>
<target name="install-pom" depends="maven.init">
<maven:install>
<pom file="${local.pom.output.file}"/>
</maven:install>
</target>
<!-- Supporting targets -->
<!-- POM only deployment -->
<target name="publish-central-only-pom-windows" depends="maven.init" if="is.windows">
<maven:deploy>
<!-- Due to http://jira.codehaus.org/browse/MANTTASKS-103 in 2.0.8 on windows, fixed in 2.0.9 -->
<!-- Assuming using local file, value of variable should be of the form L:\temp\maven-repo-test -->
<remoteRepository id="localDisk" url="file:${maven.central.repository}"/>
<pom file="${local.pom.output.file}"/>
</maven:deploy>
</target>
<target name="publish-central-only-pom-unix" depends="maven.init" unless="is.windows">
<maven:deploy>
<remoteRepository url="${maven.central.repository}"/>
<pom file="${local.pom.output.file}"/>
</maven:deploy>
</target>
<!-- jar, source-jar and POM deployment -->
<target name="publish-central-windows" depends="maven.init">
<maven:deploy file="${jar.output.file}">
<!-- Due to http://jira.codehaus.org/browse/MANTTASKS-103 in 2.0.8 on windows, fixed in 2.0.9 -->
<!-- Assuming using local file, value of variable should be of the form L:\temp\maven-repo-test -->
<remoteRepository id="localDisk" url="file:${maven.central.repository}"/>
<pom file="${local.pom.output.file}"/>
<attach file="${source-jar.output.file}" classifier="sources"/>
</maven:deploy>
</target>
<target name="publish-code-unix" depends="maven.init" unless="is.windows">
<maven:deploy file="${jar.output.file}">
<remoteRepository url="${maven.central.repository}"/>
<pom file="${local.pom.output.file}"/>
<attach file="${source-jar.output.file}" classifier="sources"/>
</maven:deploy>
</target>
</project>

58
build-spring-framework/publish.xml

@ -1,58 +0,0 @@ @@ -1,58 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="publish-spring-framework" xmlns:maven="antlib:org.apache.maven.artifact.ant">
<property file="${basedir}/../build.properties"/>
<import file="${basedir}/../spring-build/multi-bundle/default.xml"/>
<path id="modules-with-code-artifacts">
<pathelement location="../org.springframework.instrument"/>
<pathelement location="../org.springframework.instrument.tomcat"/>
<pathelement location="../org.springframework.asm"/>
<pathelement location="../org.springframework.core"/>
<pathelement location="../org.springframework.expression"/>
<pathelement location="../org.springframework.beans"/>
<pathelement location="../org.springframework.aop"/>
<pathelement location="../org.springframework.context"/>
<pathelement location="../org.springframework.transaction"/>
<pathelement location="../org.springframework.oxm"/>
<pathelement location="../org.springframework.jms"/>
<pathelement location="../org.springframework.aspects"/>
<pathelement location="../org.springframework.jdbc"/>
<pathelement location="../org.springframework.web"/>
<pathelement location="../org.springframework.orm"/>
<pathelement location="../org.springframework.context.support"/>
<pathelement location="../org.springframework.web.servlet"/>
<pathelement location="../org.springframework.web.portlet"/>
<pathelement location="../org.springframework.test"/>
<pathelement location="../org.springframework.web.struts"/>
</path>
<path id="modules-with-only-pom-artifacts">
<pathelement location="../org.springframework.spring-library"/>
<pathelement location="../org.springframework.spring-parent"/>
</path>
<!-- for milestones -->
<target name="publish-maven-milestone" depends="publish-maven-milestone-only-pom">
<all-bundles target="publish-maven-milestone-code-artifacts" buildpathRef="modules-with-code-artifacts"/>
</target>
<target name="publish-maven-milestone-only-pom">
<all-bundles target="publish-maven-milestone-only-pom-artifacts" buildpathRef="modules-with-only-pom-artifacts"/>
</target>
<!-- for releases -->
<target name="publish-maven-central-release" depends="publish-maven-central-only-pom-release">
<all-bundles target="publish-maven-central-code-artifacts" buildpathRef="modules-with-code-artifacts"/>
</target>
<target name="publish-maven-central-only-pom-release">
<all-bundles target="publish-maven-central-only-pom-artifacts" buildpathRef="modules-with-only-pom-artifacts"/>
</target>
</project>

13
org.springframework.asm/build.xml

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="org.springframework.asm" xmlns:ivy="antlib:org.apache.ivy.ant">
<project name="org.springframework.asm" xmlns:ivy="antlib:org.apache.ivy.ant"
xmlns:bundlor="antlib:com.springsource.bundlor.ant">
<property file="${basedir}/../build.properties"/>
<import file="${basedir}/../build-spring-framework/package-bundle.xml"/>
<import file="${basedir}/../spring-build/standard/default.xml"/>
@ -45,4 +46,14 @@ @@ -45,4 +46,14 @@
<taskdef name="jarjar" classname="com.tonicsystems.jarjar.JarJarTask" classpathref="jarjar.classpath"/>
</target>
<target name="bundlor" depends="bundlor.init" unless="disable.bundlor">
<bundlor:bundlor inputPath="${jar.output.file}" outputPath="${jar.output.file}"
bundleVersion="${bundle.version}" manifestTemplatePath="${manifest.template.file}"
failOnWarnings="${fail.on.warnings}">
<propertyset refid="bundlor.properties"/>
<propertyset>
<propertyref builtin="all"/>
</propertyset>
</bundlor:bundlor>
</target>
</project>

17
org.springframework.spring-library/build.xml

@ -1,23 +1,8 @@ @@ -1,23 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="org.springframework.spring-library" xmlns:maven="antlib:org.apache.maven.artifact.ant">
<property file="${basedir}/../build.properties"/>
<import file="${basedir}/../build-spring-framework/package-library.xml"/>
<import file="${basedir}/../spring-build/library/default.xml"/>
<target name="publish-maven-central"/>
<target name="publish-maven-central-pom-only" depends="maven.init">
<maven:deploy>
<remoteRepository url="${maven.central.repository}"/>
<!-- Due to http://jira.codehaus.org/browse/MANTTASKS-103 in 2.0.8 on windows, fixed in 2.0.9 -->
<!-- e.g. file:L:\temp\maven-repo-test -->
<!--
<remoteRepository id="localDisk" url="file:${maven.local.staging.repository}"/>
-->
<pom file="${local.pom.output.file}"/>
</maven:deploy>
</target>
</project>

5
org.springframework.spring-parent/build.xml

@ -1,8 +1,7 @@ @@ -1,8 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="org.springframework.spring-parent" xmlns:maven="antlib:org.apache.maven.artifact.ant">
<project name="org.springframework.spring-parent">
<property file="${basedir}/../build.properties"/>
<import file="${basedir}/../build-spring-framework/package-library.xml"/>
<import file="${basedir}/../spring-build/resource/default.xml"/>
</project>

2
org.springframework.spring-parent/ivy.xml

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
</configurations>
<publications>
<artifact name="${ant.project.name}"/>
<artifact name="${ant.project.name}-sources" type="src" ext="jar"/>
</publications>
</ivy-module>

11
org.springframework.spring-parent/pom.xml

@ -254,4 +254,15 @@ @@ -254,4 +254,15 @@
</plugins>
</build>
<distributionManagement>
<repository>
<id>staging</id>
<url>file:///${user.dir}/target/staging</url>
</repository>
<snapshotRepository>
<id>staging</id>
<url>file:///${user.dir}/target/staging</url>
</snapshotRepository>
</distributionManagement>
</project>

9
org.springframework.web.struts/template.mf

@ -3,15 +3,22 @@ Bundle-Name: Spring Web Struts @@ -3,15 +3,22 @@ Bundle-Name: Spring Web Struts
Bundle-Vendor: SpringSource
Bundle-ManifestVersion: 2
Import-Template:
antlr.*;version="[2.7.6, 3.0.0)";resolution:=optional,
javax.servlet.*;version="[2.4.0, 3.0.0)",
javax.sql.*;version="0",
org.apache.commons.beanutils.*;version="[1.7.0, 2.0.0)",
org.apache.commons.collections.*;version="[3.2.0, 4.0.0)",
org.apache.commons.digester.*;version="[0.4.0, 1.0.0)",
org.apache.commons.fileupload.*;version="[1.2.0, 2.0.0)",
org.apache.commons.logging.*;version="[1.0.4, 2.0.0)",
org.apache.commons.validator.*;version="[1.1.4, 2.0.0)",
org.apache.struts.*;version="[1.2.9, 2.0.0)",
org.springframework.beans.*;version="[3.0.0, 3.0.1)",
org.springframework.context.*;version="[3.0.0, 3.0.1)",
org.springframework.util.*;version="[3.0.0, 3.0.1)",
org.springframework.validation.*;version="[3.0.0, 3.0.1)",
org.springframework.web.*;version="[3.0.0, 3.0.1)"
org.springframework.web.*;version="[3.0.0, 3.0.1)",
org.xml.sax.*;version="0"
Ignored-Existing-Headers:
Bnd-LastModified,
Import-Package,

Loading…
Cancel
Save