Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

107 lines (94 sloc) 4.195 kb
<?xml version="1.0"?>
<!--
Doctrine 2 build file.
-->
<project name="DoctrineMongoDBODM" default="build" basedir=".">
<taskdef classname="phing.tasks.ext.d51PearPkg2Task" name="d51pearpkg2" />
<property file="build.properties" />
<!--
Fileset for artifacts shared across all distributed packages.
-->
<fileset id="shared-artifacts" dir=".">
<include name="LICENSE"/>
</fileset>
<!--
Fileset for the sources of the Doctrine Common dependency.
-->
<fileset id="common-sources" dir="./lib/vendor/doctrine-common/lib">
<include name="Doctrine/Common/**"/>
</fileset>
<!--
Fileset for the sources of the Doctrine MongoDB ODM.
-->
<fileset id="mongodb-odm-sources" dir="./lib">
<include name="Doctrine/ODM/MongoDB/**"/>
</fileset>
<!--
Fileset for source of the Symfony YAML and Console components.
-->
<fileset id="symfony-sources" dir="./lib/vendor">
<include name="Symfony/Component/**"/>
</fileset>
<!--
Clean the directory for the next build.
-->
<target name="clean">
<available file="./build.properties" property="build_properties_exist" value="true"/>
<fail unless="build_properties_exist" message="The build.properties file is missing." />
<delete dir="${build.dir}" includeemptydirs="true" />
<delete dir="${dist.dir}" includeemptydirs="true" />
<delete dir="${report.dir}" includeemptydirs="true" />
</target>
<!--
Prepare the new build directories after cleaning
-->
<target name="prepare" depends="clean">
<echo msg="Creating build directory: ${build.dir}" />
<mkdir dir="${build.dir}" />
<echo msg="Creating distribution directory: ${dist.dir}" />
<mkdir dir="${dist.dir}" />
<echo msg="Creating report directory: ${report.dir}" />
<mkdir dir="${report.dir}" />
<mkdir dir="${build.dir}/logs"/>
</target>
<!--
Builds ORM package, preparing it for distribution.
-->
<target name="build-mongodb-odm" depends="prepare">
<copy todir="${build.dir}/mongodb-odm">
<fileset refid="shared-artifacts"/>
</copy>
<copy todir="${build.dir}/mongodb-odm">
<fileset refid="common-sources"/>
<fileset refid="mongodb-odm-sources"/>
</copy>
<copy todir="${build.dir}/mongodb-odm/Doctrine">
<fileset refid="symfony-sources"/>
</copy>
<exec command="sed 's/${version}-DEV/${version}/' ${build.dir}/mongodb-odm/Doctrine/ODM/MongoDB/Version.php > ${build.dir}/mongodb-odm/Doctrine/ODM/MongoDB/Version2.php" passthru="true" />
<exec command="mv ${build.dir}/mongodb-odm/Doctrine/ODM/MongoDB/Version2.php ${build.dir}/mongodb-odm/Doctrine/ODM/MongoDB/Version.php" passthru="true" />
</target>
<!--
Builds distributable PEAR packages.
-->
<target name="build" depends="build-mongodb-odm">
<d51pearpkg2 baseinstalldir="/" dir="${build.dir}/mongodb-odm">
<name>DoctrineMongoDBODM</name>
<summary>Doctrine MongoDB Object Document Mapper</summary>
<channel>pear.doctrine-project.org</channel>
<description>The Doctrine MongoDB ODM package is the package that offers transparent persistence to MongoDB.</description>
<lead user="jwage" name="Jonathan H. Wage" email="jonwage@gmail.com" />
<lead user="avalanche" name="Bulat Shakirzyanov" email="mallluhuct@gmail.com" />
<license>LGPL</license>
<version release="${version}" api="${version}" />
<stability release="${stability}" api="${stability}" />
<notes>-</notes>
<dependencies>
<php minimum_version="5.3.0" />
<pear minimum_version="1.6.0" recommended_version="1.6.1" />
</dependencies>
</d51pearpkg2>
<exec command="pear package" dir="${build.dir}/mongodb-odm" passthru="true" />
<exec command="mv DoctrineMongoDBODM-${version}.tgz ../../dist" dir="${build.dir}/mongodb-odm" passthru="true" />
</target>
</project>
Jump to Line
Something went wrong with that request. Please try again.