Author: rgreig
Date: Mon Feb 12 02:10:27 2007
New Revision: 506401

URL: http://svn.apache.org/viewvc?view=rev&rev=506401
Log:
(Path Qpid-337 submitted by Rupert Smith)
Does 1.4 retrotranslation as part of the maven build.

Added:
    
incubator/qpid/trunk/qpid/java/client/distribution/src/main/assembly/client-java1.4-bin.xml
Modified:
    incubator/qpid/trunk/qpid/java/client/distribution/pom.xml
    
incubator/qpid/trunk/qpid/java/client/distribution/src/main/assembly/client-bin.xml
    incubator/qpid/trunk/qpid/java/client/pom.xml
    incubator/qpid/trunk/qpid/java/common/pom.xml
    incubator/qpid/trunk/qpid/java/distribution/src/main/assembly/bin.xml
    incubator/qpid/trunk/qpid/java/pom.xml

Modified: incubator/qpid/trunk/qpid/java/client/distribution/pom.xml
URL: 
http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/java/client/distribution/pom.xml?view=diff&rev=506401&r1=506400&r2=506401
==============================================================================
--- incubator/qpid/trunk/qpid/java/client/distribution/pom.xml (original)
+++ incubator/qpid/trunk/qpid/java/client/distribution/pom.xml Mon Feb 12 
02:10:27 2007
@@ -46,6 +46,21 @@
             <groupId>org.apache.qpid</groupId>
             <artifactId>qpid-client</artifactId>
             <type>jar</type>
+            <version>${pom.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.qpid</groupId>
+            <artifactId>qpid-client</artifactId>
+            <type>jar</type>
+            <version>${pom.version}</version>
+           <classifier>java1.4</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.qpid</groupId>
+            <artifactId>qpid-common</artifactId>
+            <type>jar</type>
+            <version>${pom.version}</version>
+           <classifier>java1.4</classifier>
         </dependency>
     </dependencies>
 
@@ -104,6 +119,7 @@
                         <configuration>
                             <descriptors>
                                 
<descriptor>src/main/assembly/client-bin.xml</descriptor>
+                                
<descriptor>src/main/assembly/client-java1.4-bin.xml</descriptor>
                                 
<descriptor>src/main/assembly/client-src.xml</descriptor>
                             </descriptors>
                             <finalName>qpid-${pom.version}</finalName>

Modified: 
incubator/qpid/trunk/qpid/java/client/distribution/src/main/assembly/client-bin.xml
URL: 
http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/java/client/distribution/src/main/assembly/client-bin.xml?view=diff&rev=506401&r1=506400&r2=506401
==============================================================================
--- 
incubator/qpid/trunk/qpid/java/client/distribution/src/main/assembly/client-bin.xml
 (original)
+++ 
incubator/qpid/trunk/qpid/java/client/distribution/src/main/assembly/client-bin.xml
 Mon Feb 12 02:10:27 2007
@@ -69,6 +69,8 @@
           <outputDirectory>qpid-${qpid.version}/lib</outputDirectory>
           <unpack>false</unpack>
           <excludes>
+             <exclude>org.apache.qpid:qpid-client:jar:java1.4</exclude>
+             <exclude>org.apache.qpid:qpid-common:jar:java1.4</exclude>
              <exclude>org.apache.qpid:qpid-client-distribution</exclude>
           </excludes>
       </dependencySet>

Added: 
incubator/qpid/trunk/qpid/java/client/distribution/src/main/assembly/client-java1.4-bin.xml
URL: 
http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/java/client/distribution/src/main/assembly/client-java1.4-bin.xml?view=auto&rev=506401
==============================================================================
--- 
incubator/qpid/trunk/qpid/java/client/distribution/src/main/assembly/client-java1.4-bin.xml
 (added)
+++ 
incubator/qpid/trunk/qpid/java/client/distribution/src/main/assembly/client-java1.4-bin.xml
 Mon Feb 12 02:10:27 2007
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+-->
+<!-- Assembly instructions for a client that runs on Java 1.4 -->
+<assembly>
+  <id>java-client-java1.4-bin</id>
+  <includeBaseDirectory>false</includeBaseDirectory>
+  <formats>
+    <format>tar.gz</format>
+    <format>zip</format>
+  </formats>
+
+  <fileSets>
+      <fileSet>
+          <!-- Apache license files -->
+          <directory>../../resources</directory>
+          <outputDirectory>qpid-${qpid.version}</outputDirectory>
+          <includes>
+              <include>DISCLAIMER</include>
+              <include>LICENSE.txt</include>
+              <include>NOTICE.txt</include>
+              <include>README.txt</include>
+          </includes>
+      </fileSet>
+
+      <fileSet>
+          <directory>../../release-docs</directory>
+          <outputDirectory>qpid-${qpid.version}/docs</outputDirectory>
+          <includes>
+              <include>RELEASE_NOTES.txt</include>
+          </includes>
+      </fileSet>
+
+      <fileSet>
+          <directory>target</directory>
+          <outputDirectory>qpid-${qpid.version}/lib</outputDirectory>
+          <includes>
+              <include>qpid-incubating.jar</include>
+          </includes>
+      </fileSet>
+  </fileSets>
+
+  <dependencySets>
+      <dependencySet>
+          <outputDirectory>qpid-${qpid.version}/lib</outputDirectory>
+          <unpack>false</unpack>
+          <excludes>
+             <exclude>org.apache.qpid:qpid-client:jar</exclude>
+             <exclude>org.apache.qpid:qpid-common:jar</exclude>
+             <exclude>org.apache.qpid:qpid-client-distribution</exclude>
+             <exclude>org.apache.mina:mina-java5</exclude>
+             <exclude>org.apache.mina:mina-filter-ssl</exclude>
+          </excludes>
+      </dependencySet>
+  </dependencySets>
+</assembly>
+
+

Modified: incubator/qpid/trunk/qpid/java/client/pom.xml
URL: 
http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/java/client/pom.xml?view=diff&rev=506401&r1=506400&r2=506401
==============================================================================
--- incubator/qpid/trunk/qpid/java/client/pom.xml (original)
+++ incubator/qpid/trunk/qpid/java/client/pom.xml Mon Feb 12 02:10:27 2007
@@ -38,6 +38,11 @@
         <java.source.version>1.5</java.source.version>
         <qpid.version>${pom.version}</qpid.version>
         <qpid.targetDir>${project.build.directory}</qpid.targetDir>
+
+       <!-- Override these in local settings.xml to perform verification. 
Cannot make assumptions about 1.4 Jdk location to turn this on by default. -->
+       <retrotranslator.verify>false</retrotranslator.verify>
+       <retrotranslator.1.4-rt-path/>
+
     </properties>
 
     <dependencies>
@@ -67,7 +72,7 @@
             <artifactId>mina-filter-ssl</artifactId>
         </dependency>
 
-       <!-- Test Dependencies -->
+        <!-- Test Dependencies -->
         <dependency> <!-- for inVm Broker -->
             <groupId>org.apache.qpid</groupId>
             <artifactId>qpid-broker</artifactId>
@@ -98,6 +103,14 @@
             <artifactId>easymockclassextension</artifactId>
             <scope>test</scope>
         </dependency>
+
+       <!-- This needs to be included at compile time, for the retrotranslator 
verification to find it. -->
+       <dependency>
+           <groupId>net.sf.retrotranslator</groupId>
+           <artifactId>retrotranslator-runtime</artifactId>
+           <scope>provided</scope>
+       </dependency>
+
     </dependencies>
 
     <build>
@@ -141,48 +154,91 @@
                 </executions>
             </plugin>
 
-        </plugins>
+            <!-- Backports the module to Java 1.4. This is done during the 
packaging phase as a transformation of the Jar. -->
+            <plugin>
+               <groupId>org.codehaus.mojo</groupId>
+               <artifactId>retrotranslator-maven-plugin</artifactId>
+               <executions>
+                   <execution>
+                       <phase>package</phase>
+                       <goals>
+                           <goal>translate</goal>
+                       </goals>
+                       <configuration>
+                           
<destjar>${project.build.directory}/${project.build.finalName}-java1.4.jar</destjar>
+                          <verify>${retrotranslator.verify}</verify>
+                          <verifyClasspath>
+                              <element>${retrotranslator.1.4-rt-path}</element>
+                              
<element>${retrotranslator.1.4-jce-path}</element>
+                              
<element>${retrotranslator.1.4-jsse-path}</element>
+                          </verifyClasspath>
+                           <includes>
+                               <include>
+                                   
<directory>${project.build.directory}</directory>
+                                   
<pattern>${project.build.finalName}.jar</pattern>
+                               </include>
+                           </includes>
+                       </configuration>
+                   </execution>
 
-<!-- The inclusion of this resource causes the build to hang. -->
-    <!--resources>
-        <resource>
-            <targetPath>META-INF/</targetPath>
-            <filtering>false</filtering>
-            <directory>../resources/META-INF</directory>
-            <includes>
-                <include>**</include>
-            </includes>
-        </resource>
-    </resources-->
-
-    <testResources>
-        <testResource>
-            <targetPath>META-INF/</targetPath>
-            <filtering>false</filtering>
-            <directory>../resources/META-INF</directory>
-            <includes>
-                <include>**</include>
-            </includes>
-        </testResource>
-        <testResource>
-            <targetPath>src/</targetPath>
-            <filtering>false</filtering>
-            <directory>src/test/java</directory>
-            <includes>
-                <include>**/*.java</include>
-            </includes>
-        </testResource>
-
-        <testResource>
-            <targetPath></targetPath>
-            <filtering>false</filtering>
-            <directory>src/main/java</directory>
-            <includes>
-                <include>client.log4j</include>
-            </includes>
-        </testResource>
-    </testResources>
+               </executions>
+            </plugin>
+           
+           <!-- This identifies the backported java 1.4 jar and attaches it as 
a jar (classified as java1.4) build artifact. -->
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>build-helper-maven-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>attach-artifacts</id>
+                        <phase>package</phase>
+                        <goals>
+                            <goal>attach-artifact</goal>
+                        </goals>
+                        <configuration>
+                            <artifacts>
+                                <artifact>
+                                    
<file>${project.build.directory}/${project.build.finalName}-java1.4.jar</file>
+                                    <type>jar</type>
+                                    <classifier>java1.4</classifier>
+                                </artifact>
+                            </artifacts>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
 
-    </build>
+        </plugins>
 
+        <testResources>
+            <testResource>
+                <targetPath>META-INF/</targetPath>
+                <filtering>false</filtering>
+                <directory>../resources/META-INF</directory>
+                <includes>
+                    <include>**</include>
+                </includes>
+            </testResource>
+            <testResource>
+                <targetPath>src/</targetPath>
+                <filtering>false</filtering>
+                <directory>src/test/java</directory>
+                <includes>
+                    <include>**/*.java</include>
+                </includes>
+            </testResource>
+    
+            <testResource>
+                <targetPath></targetPath>
+                <filtering>false</filtering>
+                <directory>src/main/java</directory>
+                <includes>
+                    <include>client.log4j</include>
+                </includes>
+            </testResource>
+        </testResources>
+    
+    </build>
+    
 </project>
+    
\ No newline at end of file

Modified: incubator/qpid/trunk/qpid/java/common/pom.xml
URL: 
http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/java/common/pom.xml?view=diff&rev=506401&r1=506400&r2=506401
==============================================================================
--- incubator/qpid/trunk/qpid/java/common/pom.xml (original)
+++ incubator/qpid/trunk/qpid/java/common/pom.xml Mon Feb 12 02:10:27 2007
@@ -64,6 +64,61 @@
                     </execution>
                 </executions>
             </plugin>
+
+            <!-- Backports the module to Java 1.4. This is done during the 
packaging phase as a transformation of the Jar. -->
+            <plugin>
+               <groupId>org.codehaus.mojo</groupId>
+               <artifactId>retrotranslator-maven-plugin</artifactId>
+               <executions>
+                   <execution>
+                       <phase>package</phase>
+                       <goals>
+                           <goal>translate</goal>
+                       </goals>
+                       <configuration>
+                           
<destjar>${project.build.directory}/${project.build.finalName}-java1.4.jar</destjar>
+                          <verify>${retrotranslator.verify}</verify>
+                          <verifyClasspath>
+                              <element>${retrotranslator.1.4-rt-path}</element>
+                              
<element>${retrotranslator.1.4-jce-path}</element>
+                              
<element>${retrotranslator.1.4-jsse-path}</element>
+                          </verifyClasspath>
+                           <includes>
+                               <include>
+                                   
<directory>${project.build.directory}</directory>
+                                  
<pattern>${project.build.finalName}.jar</pattern>
+                               </include>
+                           </includes>
+                       </configuration>
+                   </execution>
+
+               </executions>
+            </plugin>
+           
+           <!-- This identifies the backported java 1.4 jar and attaches it as 
a jar (classified as java1.4) build artifact. -->
+            <plugin>
+                <groupId>org.codehaus.mojo</groupId>
+                <artifactId>build-helper-maven-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>attach-artifacts</id>
+                        <phase>package</phase>
+                        <goals>
+                            <goal>attach-artifact</goal>
+                        </goals>
+                        <configuration>
+                            <artifacts>
+                                <artifact>
+                                    
<file>${project.build.directory}/${project.build.finalName}-java1.4.jar</file>
+                                    <type>jar</type>
+                                    <classifier>java1.4</classifier>
+                                </artifact>
+                            </artifacts>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+
         </plugins>
     </build>
 
@@ -74,12 +129,11 @@
             <artifactId>log4j</artifactId>
         </dependency>
 
-
-<!-- This is a mina dependency but it isn't being picked up-->
-       <dependency>
+        <!-- This is a mina dependency but it isn't being picked up-->
+        <dependency>
             <groupId>org.slf4j</groupId>
             <artifactId>slf4j-simple</artifactId>
-       </dependency>
+        </dependency>
 
         <dependency>
             <groupId>org.apache.mina</groupId>
@@ -101,6 +155,13 @@
             <artifactId>junit</artifactId>
             <scope>test</scope>
         </dependency>
+
+       <!-- This needs to be included at compile time, for the retrotranslator 
verification to find it. -->
+       <dependency>
+           <groupId>net.sf.retrotranslator</groupId>
+           <artifactId>retrotranslator-runtime</artifactId>
+           <scope>provided</scope>
+       </dependency>
 
     </dependencies>
 </project>

Modified: incubator/qpid/trunk/qpid/java/distribution/src/main/assembly/bin.xml
URL: 
http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/java/distribution/src/main/assembly/bin.xml?view=diff&rev=506401&r1=506400&r2=506401
==============================================================================
--- incubator/qpid/trunk/qpid/java/distribution/src/main/assembly/bin.xml 
(original)
+++ incubator/qpid/trunk/qpid/java/distribution/src/main/assembly/bin.xml Mon 
Feb 12 02:10:27 2007
@@ -148,6 +148,7 @@
       <outputDirectory>qpid-${qpid.version}/lib</outputDirectory>
       <unpack>false</unpack>
       <excludes>
+        <exclude>org.apache.qpid:qpid-broker</exclude>
         <exclude>org.apache.qpid:qpid-distribution</exclude>
         
<exclude>org.apache.qpid.management:org.apache.qpid.management.ui</exclude>
         <exclude>org.eclipse.core:org.eclipse.core.commands</exclude>

Modified: incubator/qpid/trunk/qpid/java/pom.xml
URL: 
http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/java/pom.xml?view=diff&rev=506401&r1=506400&r2=506401
==============================================================================
--- incubator/qpid/trunk/qpid/java/pom.xml (original)
+++ incubator/qpid/trunk/qpid/java/pom.xml Mon Feb 12 02:10:27 2007
@@ -47,7 +47,7 @@
             
<url>scp://people.apache.org/www/people.apache.org/repo/m2-snapshot-repository</url>
         </snapshotRepository>
 
-    <!-- Qpid has a Wiki site, maven generated site not used. This is just so 
that it can be created locally for viewing the reports. -->
+        <!-- Qpid has a Wiki site, maven generated site not used. This is just 
so that it can be created locally for viewing the reports. -->
         <site>
           <id>Qpid_Site</id>
           <name>Qpid Site</name>
@@ -97,17 +97,17 @@
         <java.source.version>1.5</java.source.version>
         <compile.flags>-Xlint:fallthrough,finally</compile.flags>
 
-    <!-- 
+        <!-- 
           This should always point to a default minimal log4j configuration 
that all developers are happy with as a useable default. To use your own
           log4j preferences set up an alternative in your settings.xml and 
avoid corrupting the default with private preferences.
-      -->
-    
<!--<log4j.configuration>file:/${topDirectoryLocation}/etc/log4j.xml</log4j.configuration>-->
+          -->
+        
<!--<log4j.configuration>file:/${topDirectoryLocation}/etc/log4j.xml</log4j.configuration>-->
         <amqj.logging.level>warn</amqj.logging.level> <!-- This is referenced 
in the default log4j.xml -->
 
         <!--Versions for various plugins and features -->
         <antrun.version>1.2-SNAPSHOT</antrun.version>
         <!--<assembly.version>2.2-SNAPSHOT</assembly.version>-->
-    <assembly.version>2.1</assembly.version>
+        <assembly.version>2.1</assembly.version>
         <cobertura.version>2.0</cobertura.version>
         <compiler.version>2.0.1</compiler.version>
         <dependency.plugin.version>1.0</dependency.plugin.version>
@@ -121,7 +121,8 @@
         <site.version>2.0-beta-5</site.version>
         <surefire-report.version>2.1-SNAPSHOT</surefire-report.version>
         <surefire.version>2.2</surefire.version>
-
+        
<retrotranslator.plugin.version>1.0-alpha-1</retrotranslator.plugin.version>
+       <build-helper.plugin.version>1.0</build-helper.plugin.version>
         
<eclipse.workspace.dir>${basedir}/${topDirectoryLocation}/../workspace</eclipse.workspace.dir>
         
<clover.license.pathname>/set/clover/license/path/here</clover.license.pathname>
     </properties>
@@ -251,6 +252,18 @@
                 </plugin>
 
                 <plugin>
+                    <groupId>org.codehaus.mojo</groupId>
+                    <artifactId>retrotranslator-maven-plugin</artifactId>
+                    <version>${retrotranslator.plugin.version}</version>
+                </plugin>
+
+                <plugin>
+                    <groupId>org.codehaus.mojo</groupId>
+                    <artifactId>build-helper-maven-plugin</artifactId>
+                    <version>${build-helper.plugin.version}</version>
+                </plugin>
+
+                <plugin>
                     <groupId>org.apache.maven.plugins</groupId>
                     <artifactId>maven-jar-plugin</artifactId>
                     <version>${jar.version}</version>
@@ -288,12 +301,12 @@
                         <argLine>-ea</argLine>
                         <systemproperties>
                             <property>
-                    <name>amqj.logging.level</name>
+                                <name>amqj.logging.level</name>
                                 <value>${amqj.logging.level}</value>
-                <!--
-                <name>log4j.configuration</name>
-                <value>${log4j.configuration}</value>
-                -->
+                                <!--
+                                <name>log4j.configuration</name>
+                                <value>${log4j.configuration}</value>
+                                -->
                             </property>
                         </systemproperties>
                     </configuration>
@@ -363,6 +376,16 @@
 
     <dependencyManagement>
         <dependencies>
+
+           <!-- Comile time only dependencies. -->
+           <dependency>
+               <groupId>net.sf.retrotranslator</groupId>
+               <artifactId>retrotranslator-runtime</artifactId>
+               <version>1.0.8</version>
+               <scope>provided</scope>
+           </dependency>
+
+           <!-- Compilation and run time dependecies. -->
             <dependency>
                 <groupId>commons-cli</groupId>
                 <artifactId>commons-cli</artifactId>


Reply via email to