avalon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From craft...@apache.org
Subject cvs commit: jakarta-avalon-logkit build.xml
Date Wed, 17 Apr 2002 09:51:53 GMT
crafterm    02/04/17 02:51:53

  Modified:    .        build.xml
  Log:
  Modified build.xml to conditionally include SMTPOutputLogTarget for
  compilation when the javamail classes are available, and to print the usual
  warning when they are not.
  
  Revision  Changes    Path
  1.74      +21 -1     jakarta-avalon-logkit/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-logkit/build.xml,v
  retrieving revision 1.73
  retrieving revision 1.74
  diff -u -r1.73 -r1.74
  --- build.xml	3 Apr 2002 09:20:53 -0000	1.73
  +++ build.xml	17 Apr 2002 09:51:53 -0000	1.74
  @@ -84,11 +84,13 @@
     <property name="announce2site" value="${tools.dir}/announcement2site.xsl"/>
   
     <property name="servlet.jar" value="${lib.dir}/servlet.jar"/>
  +  <property name="mail.jar" value="${lib.dir}/mail.jar"/>
   
     <path id="project.class.path">
       <pathelement path="${java.class.path}" />
       <pathelement location="${junit.jar}"/>
       <pathelement path="${servlet.jar}" />
  +    <pathelement path="${mail.jar}"/>
       <pathelement path="${j2ee.jar}" />
       <pathelement path="${jdbc.driver.jar}" />
       <fileset dir="${lib.dir}">
  @@ -185,6 +187,10 @@
                  classname="javax.jms.TopicConnection"
                  classpathref="project.class.path" />
   
  +    <available property="javax.mail.present"
  +               classname="javax.mail.Message"
  +               classpathref="project.class.path" />
  +
     </target>
   
     <target name="op-warning" description="General waring target (used by other targets)">
  @@ -209,6 +215,15 @@
       </antcall>
     </target>
   
  +  <target name="mail-warn" unless="javax.mail.present"
  +      description="Outputs a warning if javax.mail.* classes are missing during compilation">
  +    <antcall target="op-warning">
  +      <param name="thing" value="SMTP"/>
  +      <param name="recovery"
  +        value="Get mail.jar from inside javamail-1_2.zip from http://java.sun.com/products/javamail/
and place it in the lib dir"/>
  +    </antcall>
  +  </target>
  +
     <target name="jms-warn" unless="javax.jms.present"
         description="Outputs a warning if javax.jms.* classes are missing during compilation">
       <antcall target="op-warning">
  @@ -241,7 +256,7 @@
       <echo/>
     </target>
   
  -  <target name="optional-warnings" depends="jms-warn,framework-warn,sql-warn,servlet-warn"
  +  <target name="optional-warnings" depends="jms-warn,framework-warn,sql-warn,servlet-warn,mail-warn"
         description="Outputs warnings if some jars are missing from the environment">
     </target>
   
  @@ -265,6 +280,8 @@
         <src path="${compat.dir}"/>
         <exclude name="org/apache/log/output/ServletOutputLogTarget.java"
                  unless="servlet.present"/>
  +      <exclude name="org/apache/log/output/net/SMTPOutputLogTarget.java"
  +               unless="javax.mail.present"/>
         <exclude name="org/apache/log/format/AvalonFormatter.java"
                  unless="avalon-framework.present"/>
         <exclude name="org/apache/log/output/db/**"
  @@ -370,6 +387,8 @@
         <fileset dir="${java.dir}">
           <exclude name="org/apache/log/output/ServletOutputLogTarget.java"
                    unless="servlet.present"/>
  +        <exclude name="org/apache/log/output/net/SMTPOutputLogTarget.java"
  +                 unless="javax.mail.present"/>
           <exclude name="org/apache/log/format/AvalonFormatter.java"
                    unless="avalon-framework.present"/>
           <exclude name="org/apache/log/output/db/**"
  @@ -689,3 +708,4 @@
     </target>
   
   </project>
  +
  
  
  

--
To unsubscribe, e-mail:   <mailto:avalon-cvs-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:avalon-cvs-help@jakarta.apache.org>


Mime
View raw message