ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dean A. Hoover" <dhoo...@rochester.rr.com>
Subject Re: using build.xml snippets
Date Thu, 15 May 2003 01:02:54 GMT
Thanks. I am using apache-ant-1.6alpha. I attempted to follow your
advice as follows:

==== build.xml ====
<?xml version="1.0"?>
XML <!DOCTYPE project [
  <!ENTITY taskdefs SYSTEM "file:/home/dhoover/taskdefs.ent">
  ]>
<project name="fermata" basedir="." default="build">
&taskdefs;
    <target name="init">
...
</project>
=== taskdefs.ent ===
       <taskdef name="deploy" 
classname="org.apache.catalina.ant.DeployTask"/>
        <taskdef name="install" 
classname="org.apache.catalina.ant.InstallTask"/>
        <taskdef name="list" classname="org.apache.catalina.ant.ListTask"/>
        <taskdef name="reload" 
classname="org.apache.catalina.ant.ReloadTask"/>
        <taskdef name="remove" 
classname="org.apache.catalina.ant.RemoveTask"/>
        <taskdef name="resources" 
classname="org.apache.catalina.ant.ResourcesTask"/>
        <taskdef name="roles" 
classname="org.apache.catalina.ant.RolesTask"/>
        <taskdef name="start" 
classname="org.apache.catalina.ant.StartTask"/>
        <taskdef name="stop" classname="org.apache.catalina.ant.StopTask"/>
        <taskdef name="undeploy" 
classname="org.apache.catalina.ant.UndeployTask"/>

When I run ant I get:

Buildfile: build.xml

BUILD FAILED
/home/dhoover/DEVEL/migrasponder/web/vendor/build.xml:2: Content is not 
allowed in prolog.

Total time: 0 seconds

Did I misunderstand?

Dean

Sebastien Blanc wrote:

>Hi !
>
>if u're talking about XML build inclusion, u can use the following:
>
>XML <!DOCTYPE project [
>  <!ENTITY builddefs SYSTEM "file:../../build/builddefs.xml">
>]>
>
><project name="AMC logging" default="main">
>
>  <property name="component.name" value="amc"/>
>  <target name="main" depends="jar"/>
>
>  &builddefs;
>
>this is extensible to as much XML files as u wish; also I think ANT 1.6
>is supposed to have an <import> task.
>
>seb.
>
>"Dean A. Hoover" wrote:
>
>  
>
>>Suppose I want to "include" files in a build.xml file. How do
>>I do it?
>>
>>Dean Hoover
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
>>For additional commands, e-mail: user-help@ant.apache.org
>>    
>>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
>For additional commands, e-mail: user-help@ant.apache.org
>
>
>  
>



Mime
View raw message