If build property starts with project.basedir, don't resolve absolute path.

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@726343 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Britton Isbell 2008-12-14 03:12:08 +00:00
parent fafb133780
commit fca273b3a0
1 changed files with 2 additions and 1 deletions

View File

@ -177,7 +177,8 @@ public class Interpolator {
if(mp.getUri().startsWith( ProjectUri.Build.xUri ) || mp.getUri().equals( ProjectUri.Reporting.outputDirectory )) if(mp.getUri().startsWith( ProjectUri.Build.xUri ) || mp.getUri().equals( ProjectUri.Reporting.outputDirectory ))
{ {
File file = new File(mp.getResolvedValue()); File file = new File(mp.getResolvedValue());
if( !file.isAbsolute() && !mp.getResolvedValue().startsWith("${project.build.")) if( !file.isAbsolute() && !mp.getResolvedValue().startsWith("${project.build.")
&& !mp.getResolvedValue().equals("${project.basedir}"))
{ {
buildDirectories.put(mp, new ModelProperty(mp.getUri(), new File(basedir, file.getPath()).getAbsolutePath())); buildDirectories.put(mp, new ModelProperty(mp.getUri(), new File(basedir, file.getPath()).getAbsolutePath()));
} }