ASF Bugzilla – Attachment 5711 Details for
Bug 18826
rpm task doesn't work with recent versions of rpm
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Introduce a customizable rpm build command
ant-rpm.patch (text/plain), 3.43 KB, created by
Ville Skyttä
on 2003-04-08 17:56:02 UTC
(
hide
)
Description:
Introduce a customizable rpm build command
Filename:
MIME Type:
Creator:
Ville Skyttä
Created:
2003-04-08 17:56:02 UTC
Size:
3.43 KB
patch
obsolete
>Index: src/main/org/apache/tools/ant/taskdefs/optional/Rpm.java >=================================================================== >RCS file: /home/cvspublic/ant/src/main/org/apache/tools/ant/taskdefs/optional/Rpm.java,v >retrieving revision 1.13 >diff -a -u -r1.13 Rpm.java >--- src/main/org/apache/tools/ant/taskdefs/optional/Rpm.java 10 Feb 2003 14:13:45 -0000 1.13 >+++ src/main/org/apache/tools/ant/taskdefs/optional/Rpm.java 8 Apr 2003 17:47:16 -0000 >@@ -71,7 +71,8 @@ > > /** > * Invokes the rpm tool to build a Linux installation file. >- * @author lucas@collab.net >+ * >+ * @author lucas@collab.net > */ > public class Rpm extends Task { > >@@ -91,6 +92,12 @@ > private String command = "-bb"; > > /** >+ * The executable to use for building the packages. >+ * @since Ant 1.5.3 >+ */ >+ private String rpmBuildCommand = "rpmbuild"; >+ >+ /** > * clean BUILD directory > */ > private boolean cleanBuildDir = false; >@@ -119,7 +126,7 @@ > > Commandline toExecute = new Commandline(); > >- toExecute.setExecutable("rpm"); >+ toExecute.setExecutable(rpmBuildCommand); > if (topDir != null) { > toExecute.createArgument().setValue("--define"); > toExecute.createArgument().setValue("_topdir" + topDir); >@@ -206,7 +213,7 @@ > } > > /** >- * What command to issue to the rpm tool; optional. >+ * What command to issue to the rpm build tool; optional. > * The default is "-bb" > */ > public void setCommand(String c) { >@@ -259,5 +266,16 @@ > */ > public void setError(File error) { > this.error = error; >+ } >+ >+ /** >+ * The executable to run when building; optional. >+ * The default is <code>rpmbuild</code>. >+ * >+ * @since Ant 1.5.3 >+ * @param c the rpm build executable >+ */ >+ public void setRpmBuildCommand(String c) { >+ this.rpmBuildCommand = c; > } > } >Index: docs/manual/OptionalTasks/rpm.html >=================================================================== >RCS file: /home/cvspublic/ant/docs/manual/OptionalTasks/rpm.html,v >retrieving revision 1.5 >diff -a -u -r1.5 rpm.html >--- docs/manual/OptionalTasks/rpm.html 9 Jul 2002 21:05:52 -0000 1.5 >+++ docs/manual/OptionalTasks/rpm.html 8 Apr 2003 17:47:16 -0000 >@@ -23,7 +23,7 @@ > </tr> > <tr> > <td valign="top">specFile</td> >- <td valign="top">The name of the spec File to be used.</td> >+ <td valign="top">The name of the spec file to be used.</td> > <td valign="top" align="center">Yes</td> > </tr> > <tr> >@@ -52,7 +52,17 @@ > to remove the sources after the build. > See the the <tt>--rmsource</tt> option of rpmbuild.</td> > <td align="center" valign="top">No</td> >- </tr> <tr> >+ </tr> >+ <tr> >+ <td valign="top">rpmBuildCommand</td> >+ <td valign="top"> >+ The executable to use for building the RPM. Defaults to >+ <tt>rpmbuild</tt>. Set this to <tt>rpm</tt> for older rpm versions that >+ don't have the <tt>rpmbuild</tt> executable. <em>Since Ant 1.5.3</em>. >+ </td> >+ <td valign="top" align="center">No</td> >+ </tr> >+ <tr> > <td valign="top">command</td> > <td valign="top">very similar idea to the cvs task. the default is "-bb"</td> > <td align="center" valign="top">No</td> >@@ -65,7 +75,7 @@ > </table> > <hr> > >-<p align="center">Copyright © 2001-2002 Apache Software Foundation. All rights >+<p align="center">Copyright © 2001-2003 Apache Software Foundation. All rights > Reserved.</p> > > </body>
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 18826
: 5711