<?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.
-->

<project name="OFBiz Special Purpose Applications Build" default="build" basedir=".">
    <import file="../macros.xml"/>
    <filelist id="specialpurpose-builds" dir="."
        files="
        ecommerce/build.xml,
        pos/build.xml,
        hhfacility/build.xml,
        assetmaint/build.xml,
        oagis/build.xml,
        googlebase/build.xml,
        ebay/build.xml,
        ebaystore/build.xml,
        projectmgr/build.xml,
        ldap/build.xml,
        crowd/build.xml,
        webpos/build.xml
        googlecheckout/build.xml"/>
    <!-- For the old OFBiz Workflow Engine add "workflow/build.xml" to the list above -->
    <!-- For Shark add "shark/build.xml" to the list above, in the specialpurpose-builds list (after workflow) -->

    <!-- ================================================================== -->
    <!-- Removes all created files and directories                          -->
    <!-- ================================================================== -->

    <target name="refresh">
        <antcall target="clean-all"/>
        <antcall target="build"/>
    </target>

    <target name="clean-all">
        <antcall target="clean-xtra"/>
        <antcall target="clean"/>
    </target>

    <target name="clean-xtra" depends="">
        <delete verbose="on">
            <fileset dir="." includes="**/.nbattrs,**/*~,**/.#*,**/.DS_Store,**/*.rej,**/*.orig"/>
        </delete>
    </target>

    <target name="tests">
    </target>

    <target name="clean">
        <iterate target="clean" filelist="specialpurpose-builds"/>
        <delete file="ofbiz.jar"/>
        <echo message="[clean] ========== Done Cleaning Special purpose =========="/>
    </target>

    <!-- ================================================================== -->
    <!-- Build Components                                                   -->
    <!-- ================================================================== -->

    <target name="build" depends="">
        <echo message="[build] ========== Start Building Special Purpose (Compile) =========="/>

        <iterate inheritall="false" filelist="specialpurpose-builds"/>

        <echo message="[build] ========== Done Building Special Purpose (Compile) =========="/>
    </target>

    <!-- ================================================================== -->
    <!-- Build JavaDocs                                                     -->
    <!-- ================================================================== -->

    <target name="docs" depends="">
        <echo message="[docs] ========== Start Building Special Purpose (JavaDoc) =========="/>

        <iterate target="docs" filelist="specialpurpose-builds"/>

        <echo message="[docs] ========== Done Building Special Purpose (JavaDocs) =========="/>
    </target>
</project>
