Bug 530685

Summary: Python distutils 'bdist_rpm' target requires optimization enabled during build
Product: Red Hat Enterprise Linux 5 Reporter: David Ward <david.ward>
Component: pythonAssignee: Python Maintainers <python-maint>
Status: CLOSED WONTFIX QA Contact: BaseOS QE - Apps <qe-baseos-apps>
Severity: medium Docs Contact:
Priority: low    
Version: 5.4CC: bkabrda, jdigilio
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 236535 Environment:
Last Closed: 2013-10-18 05:59:59 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Force optimization (-O1) when building none

Description David Ward 2009-10-24 06:09:26 UTC
Created attachment 365924 [details]
Force optimization (-O1) when building

+++ This bug was cloned for RHEL 5 from Fedora Bug #236535 +++

When using distutils to build a Python module into an RPM, by calling from the module's source directory
   python setup.py bdist_rpm

the procedure will fail before writing the RPM, with
   error: Installed (but unpackaged) file(s) found

followed by a list of the *.pyo files that are compiled during the build process.

This has been fixed upstream in Python (http://bugs.python.org/issue1533164) by forcing optimization during the build (-O1).  I've attached the needed patch for RHEL 5, which makes the same simple change as upstream.  I verified that this resolved the error and allowed RPMs to be built successfully.

Comment 2 Joe Digilio 2010-06-16 21:40:07 UTC
What is the status of this bug?  Will the fix be included in 5.6?

Comment 4 RHEL Program Management 2010-08-09 19:16:54 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.

Comment 6 RHEL Program Management 2011-05-31 14:34:53 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.

Comment 8 RHEL Program Management 2013-05-01 06:53:58 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated
in the current release, Red Hat is unable to address this
request at this time.

Red Hat invites you to ask your support representative to
propose this request, if appropriate, in the next release of
Red Hat Enterprise Linux.

Comment 9 Bohuslav "Slavek" Kabrda 2013-10-18 05:59:59 UTC
Due to non-critical nature of this bug, the engineering will not address it in the current lifecycle stage of RHEL 5. Feel free to reopen if it keeps causing problems.