Test failure while building cpython

Adam Bishop Adam.Bishop at ja.net
Wed Aug 20 19:05:00 EDT 2014


I'm trying to build python 3.3.2 from source packages provided by Red Hat under mock.

The build itself works,but one specific test is failing:
  
   ======================================================================
   FAIL: test_sysconfig_module (distutils.tests.test_sysconfig.SysconfigTestCase)
   ----------------------------------------------------------------------
   Traceback (most recent call last):
     File "/builddir/build/BUILD/Python-3.3.2/Lib/distutils/tests/test_sysconfig.py", line 134, in test_sysconfig_module
       self.assertEqual(global_sysconfig.get_config_var('CFLAGS'), sysconfig.get_config_var('CFLAGS'))
   AssertionError: '-Wno-unused-result -DDYNAMIC_ANNOTATIONS_ENABLED=1 -O2 -g -pipe -Wall -Wp,-D_FO [truncated]... != '-Wno-unused-result -DDYNAMIC_ANNOTATIONS_ENABLED=1 -O2 -g -pipe -Wall -Wp,-D_FO [truncated]...
   - -Wno-unused-result -DDYNAMIC_ANNOTATIONS_ENABLED=1 -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches   -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -I/usr/include-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches   -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv  -I/usr/include-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches   -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv   -O1
   ?                                                                                                                                                                                                                                                                                                                                                                                                                                       --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
   + -Wno-unused-result -DDYNAMIC_ANNOTATIONS_ENABLED=1 -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches   -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -I/usr/include-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches   -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv
   
   
   ----------------------------------------------------------------------
   Ran 189 tests in 1.778s

Obviously I could simply disable the test[1], but this requires patching the source package, which I'd rather avoid because I don't fully understand what case this test is trying to detect.

Is anyone able to indicate what the test is looking for and what might cause it to fail? I don't see how the CFLAGS used in the build process could change during the test run.

Other details: CentOS 7 x86_64, GCC 4.8.2, Python 3.3.2, mock 1.1.41

[1] https://github.com/python/cpython/blob/edc966f9c5bc9291d2b7009f600e243142cf8a22/Lib/distutils/tests/test_sysconfig.py#L127-L130

Thanks,

Adam Bishop

   gpg: 0x6609D460

Janet, the UK's research and education network.
Janet(UK) is a trading name of Jisc Collections and Janet Limited, a 
not-for-profit company which is registered in England under No. 2881024 
and whose Registered Office is at Lumen House, Library Avenue,
Harwell Oxford, Didcot, Oxfordshire. OX11 0SG. VAT No. 614944238




More information about the Python-list mailing list