From 8284c1317062a166b3e54668f07fdf9d1ac7fd8c Mon Sep 17 00:00:00 2001
From: Todd Lipcon <todd@cloudera.com>
Date: Tue, 15 Sep 2009 01:19:54 -0700
Subject: [PATCH] HADOOP-6267. Make build-contrib.xml reference relative paths using a dirname property

This allows contrib projects to be built out-of-tree
---
 src/contrib/build-contrib.xml |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/src/contrib/build-contrib.xml b/src/contrib/build-contrib.xml
index 3dc5540..d1db385 100644
--- a/src/contrib/build-contrib.xml
+++ b/src/contrib/build-contrib.xml
@@ -22,6 +22,7 @@
 <project name="hadoopbuildcontrib" xmlns:ivy="antlib:org.apache.ivy.ant">
 
   <property name="name" value="${ant.project.name}"/>
+  <dirname property="src.contrib.dir" file="${ant.file.hadoopbuildcontrib}" />
   <property name="root" value="${basedir}"/>
 
   <!-- Load all the default properties, and any the user wants    -->
@@ -29,7 +30,7 @@
   <property file="${user.home}/${name}.build.properties" />
   <property file="${root}/build.properties" />
 
-  <property name="hadoop.root" location="${root}/../../../"/>
+  <property name="hadoop.root" location="${src.contrib.dir}/../../"/>
   <property name="src.dir"  location="${root}/src/java"/>
   <property name="src.test" location="${root}/src/test"/>
   <property name="src.examples" location="${root}/src/examples"/>
-- 
1.6.0.4

