From 479a97c3869b36f4158fa65135c302c6dbf1265c Mon Sep 17 00:00:00 2001 From: Jacobus Martinus Kruithof Date: Sun, 8 Feb 2009 11:33:56 +0000 Subject: [PATCH] Bugzilla Report 46659, space missing between define and value in RPM task (verified against help page of rpm). git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@742061 13f79535-47bb-0310-9956-ffa450edef68 --- WHATSNEW | 3 +++ src/main/org/apache/tools/ant/taskdefs/optional/Rpm.java | 5 ++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/WHATSNEW b/WHATSNEW index 26aa05ed4..ca5227559 100644 --- a/WHATSNEW +++ b/WHATSNEW @@ -137,6 +137,9 @@ Changes that could break older environments: Fixed bugs: ----------- + * RPM task needed an inserted space between the define and the value. + bugzilla Report 46659. + * Got rid of deadlock between in in, out and err in the Redirector. Bugzilla Report 44544. diff --git a/src/main/org/apache/tools/ant/taskdefs/optional/Rpm.java b/src/main/org/apache/tools/ant/taskdefs/optional/Rpm.java index 95fa3ec9d..d0d3d1cf0 100644 --- a/src/main/org/apache/tools/ant/taskdefs/optional/Rpm.java +++ b/src/main/org/apache/tools/ant/taskdefs/optional/Rpm.java @@ -120,7 +120,7 @@ public class Rpm extends Task { : rpmBuildCommand); if (topDir != null) { toExecute.createArgument().setValue("--define"); - toExecute.createArgument().setValue("_topdir" + topDir); + toExecute.createArgument().setValue("_topdir " + topDir); } toExecute.createArgument().setLine(command); @@ -187,9 +187,8 @@ public class Rpm extends Task { + "' failed with exit code " + returncode; if (failOnError) { throw new BuildException(msg); - } else { - log(msg, Project.MSG_ERR); } + log(msg, Project.MSG_ERR); } } catch (IOException e) { throw new BuildException(e, getLocation());