From: Martin v. Löwis Date: Mon, 7 Oct 2002 05:56:42 +0000 (+0000) Subject: Patch #619493: Prefer rpmbuild over rpm if available. X-Git-Tag: v2.2.2b1~24 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=975a80d785000e568664e9872e8a1ba14d0bfa6d;p=thirdparty%2FPython%2Fcpython.git Patch #619493: Prefer rpmbuild over rpm if available. --- diff --git a/Lib/distutils/command/bdist_rpm.py b/Lib/distutils/command/bdist_rpm.py index 4bc2561324ce..5e5fd61865ef 100644 --- a/Lib/distutils/command/bdist_rpm.py +++ b/Lib/distutils/command/bdist_rpm.py @@ -280,6 +280,9 @@ class bdist_rpm (Command): # build package self.announce('building RPMs') rpm_cmd = ['rpm'] + if os.path.exists('/usr/bin/rpmbuild') or \ + os.path.exists('/bin/rpmbuild'): + rpm_cmd = ['rpmbuild'] if self.source_only: # what kind of RPMs? rpm_cmd.append('-bs') elif self.binary_only: