<?xml version="1.0" ?>
<project name="OpenSim.Framework.Servers" default="build">
    <target name="build">
        <echo message="Build Directory is ${project::get-base-directory()}/${build.dir}" />
        <mkdir dir="${project::get-base-directory()}/${build.dir}" />
        <copy todir="${project::get-base-directory()}/${build.dir}" flatten="true">
            <fileset basedir="${project::get-base-directory()}">
            </fileset>
        </copy>
        <copy todir="${project::get-base-directory()}/${build.dir}">
            <fileset basedir=".">
            </fileset>
        </copy>
        <csc target="library" debug="${build.debug}" unsafe="False" warnaserror="False" define="TRACE;DEBUG" main="" output="${project::get-base-directory()}/${build.dir}/${project::get-name()}.dll">
            <resources prefix="OpenSim.Framework.Servers" dynamicprefix="true" >
            </resources>
            <sources failonempty="true">
                <include name="BaseHTTPHandler.cs" />
                <include name="BaseHttpServer.cs" />
                <include name="BaseOpenSimServer.cs" />
                <include name="BaseRequestHandler.cs" />
                <include name="BaseStreamHandler.cs" />
                <include name="BinaryStreamHandler.cs" />
                <include name="CheckSumServer.cs" />
                <include name="GenericHTTPMethod.cs" />
                <include name="IHttpAgentHandler.cs" />
                <include name="IStreamHandler.cs" />
                <include name="LLSDMethod.cs" />
                <include name="LLSDMethodString.cs" />
                <include name="MessageServerInfo.cs" />
                <include name="OSHttpRequest.cs" />
                <include name="OSHttpResponse.cs" />
                <include name="OSHttpStatusCodes.cs" />
                <include name="RestDeserialiseHandler.cs" />
                <include name="RestHTTPHandler.cs" />
                <include name="RestMethod.cs" />
                <include name="RestObjectPoster.cs" />
                <include name="RestObjectPosterResponse.cs" />
                <include name="RestSessionService.cs" />
                <include name="RestStreamHandler.cs" />
                <include name="SynchronousRestObjectPoster.cs" />
                <include name="VersionInfo.cs" />
                <include name="XmlRpcMethod.cs" />
            </sources>
            <references basedir="${project::get-base-directory()}">
                <lib>
                    <include name="${project::get-base-directory()}" />
                    <include name="${project::get-base-directory()}/${build.dir}" />
                </lib>
                <include name="../../../bin/HttpServer.dll" />
                <include name="../../../bin/log4net.dll" />
                <include name="../../../bin/OpenMetaverse.dll" />
                <include name="../../../bin/OpenMetaverseTypes.dll" />
                <include name="../../../bin/OpenSim.Framework.dll" />
                <include name="../../../bin/OpenSim.Framework.Console.dll" />
                <include name="../../../bin/OpenSim.Framework.Statistics.dll" />
                <include name="System.dll" />
                <include name="System.Xml.dll" />
                <include name="../../../bin/XMLRPC.dll" />
            </references>
        </csc>
        <echo message="Copying from [${project::get-base-directory()}/${build.dir}/] to [${project::get-base-directory()}/../../../bin/" />
        <mkdir dir="${project::get-base-directory()}/../../../bin/"/>
        <copy todir="${project::get-base-directory()}/../../../bin/">
            <fileset basedir="${project::get-base-directory()}/${build.dir}/" >
                <include name="*.dll"/>
                <include name="*.exe"/>
                <include name="*.mdb" if='${build.debug}'/>
            </fileset>
        </copy>
    </target>
    <target name="clean">
        <delete dir="${obj.dir}" failonerror="false" />
        <delete dir="${bin.dir}" failonerror="false" />
    </target>
    <target name="doc" description="Creates documentation.">
    </target>
</project>
