Bug 707950

Summary: abrt breaks python rpm packaging process
Product: Red Hat Enterprise Linux 6 Reporter: Francisco Lopez <flopezyg>
Component: abrtAssignee: Jiri Moskovcak <jmoskovc>
Status: CLOSED ERRATA QA Contact: Petr Šplíchal <psplicha>
Severity: high Docs Contact:
Priority: medium    
Version: 6.1CC: ahecox, dfediuck, dvlasenk, gavin, kklic, mnowak, npajkovs, ohudlick, psplicha, rvokal
Target Milestone: rc   
Target Release: 6.2   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: abrt-2.0.4-1.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-12-06 12:14:03 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:
Bug Depends On: 672043    
Bug Blocks:    

Description Francisco Lopez 2011-05-26 12:06:55 UTC
Description of problem:

"rpmbuild -bb SPECS/python.spec"  produces the following error. 

gcc -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv    -L/usr/lib6464   -Xlinker -export-dynamic -o python \

                         Modules/python.o \

                         -L. -lpython2.6 -lpthread -ldl  -lutil   -lm

'import site' failed; use -v for traceback

Traceback (most recent call last):

   File "./setup.py", line 15, in<module>

     from distutils.command.build_ext import build_ext

   File "/gpfs01/comman/home/sstraube/rpmbuild/BUILD/Python-2.6.5/Lib/distutils/command/build_ext.py", line 13, in<module>

     from site import USER_BASE, USER_SITE

   File "/gpfs01/comman/home/sstraube/rpmbuild/BUILD/Python-2.6.5/Lib/site.py", line 517, in<module>

     main()

   File "/gpfs01/comman/home/sstraube/rpmbuild/BUILD/Python-2.6.5/Lib/site.py", line 500, in main

     known_paths = addsitepackages(known_paths)

   File "/gpfs01/comman/home/sstraube/rpmbuild/BUILD/Python-2.6.5/Lib/site.py", line 292, in addsitepackages

     addsitedir(sitedir, known_paths)

   File "/gpfs01/comman/home/sstraube/rpmbuild/BUILD/Python-2.6.5/Lib/site.py", line 185, in addsitedir

     addpackage(sitedir, name, known_paths)

   File "/gpfs01/comman/home/sstraube/rpmbuild/BUILD/Python-2.6.5/Lib/site.py", line 155, in addpackage

     exec line

   File "<string>", line 1, in<module>

   File "/usr/lib/python2.6/site-packages/abrt_exception_handler.py", line 27, in<module>

     import syslog

ImportError: No module named syslog

make: *** [sharedmods] Error 1

error: Bad exit status from /var/tmp/rpm-tmp.iIa3ar (%build)

RPM build errors:

     Bad exit status from /var/tmp/rpm-tmp.iIa3ar (%build)

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:

1. take the spec file of the actual version of python

2. download the sources from python.org

3. run "rpmbuild -bb SPECS/python.spec"
  
Actual results:

multiple errors 

Expected results:

clean build

Additional info:

Comment 2 Dave Malcolm 2011-06-01 19:07:44 UTC
This is equivalent to Fedora bug 672043.

I wrote up some notes on it there at:
  https://bugzilla.redhat.com/show_bug.cgi?id=672043#c3

I don't think this is cleanly fixable from the Python side.

One workaround is to not have the abrt-addon-python package installed when
building python.

Another may be to patch ABRT to move the "import syslog" within
  /usr/lib/python2.6/site-packages/abrt_exception_handler.py"
into the callsites that use it, rather than in module scope.

Reassigning to "abrt"

Comment 5 Michal Nowak 2011-06-14 14:13:31 UTC
*** Bug 672483 has been marked as a duplicate of this bug. ***

Comment 8 errata-xmlrpc 2011-12-06 12:14:03 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2011-1598.html