Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 236444 - numpy bug exposed via scipy build process?
Summary: numpy bug exposed via scipy build process?
Alias: None
Product: Fedora
Classification: Fedora
Component: numpy
Version: rawhide
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Jarod Wilson
QA Contact: Fedora Extras Quality Assurance
Depends On:
Blocks: 236670
TreeView+ depends on / blocked
Reported: 2007-04-14 05:01 UTC by Jef Spaleta
Modified: 2007-11-30 22:12 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2007-04-17 15:49:42 UTC

Attachments (Terms of Use)

Description Jef Spaleta 2007-04-14 05:01:00 UTC
Here's the deal.
I'm trying to track down a problem in scipy and I'm now running into problems
building scipy in the development tree. It looks to me like process is
failing to recognize that gfortran is available on the system becuase the
gfortran --version string is an unexpected value. 

All of the fcompiler detection used by is actually a part of the numpy
package. And from the traceback below it certaintly looks like the problem lies
in numpy.  Could find the cycles and try to help me figure out if there really
is a problem in numpy? Or failing that a way to work around the problem so I can
get scipy to build again?

From the numpy changelog it looks like you applied a patch to numpy just a
couple of days after i built scipy in develop.

Here's the warning and traceback that I get when trying to compile the srpm
against the current devel tree. Something has definitely changed with regard to
numpy since the last time scipy was built.   If I punt and build against f77
from compat-gcc-34-g77-3.4.6-7, things appear to work.. something is definitely
broken with the gfortran compiler detection.  I can confirm that
/usr/bin/gfortran is on the system, and the same problem happens under mock as
well as under a local environment. 

warning: build_ext: fcompiler=gnu95 is not available.
Traceback (most recent call last):
  File "", line 55, in <module>
  File "", line 47, in setup_package
    configuration=configuration )
  File "/usr/lib/python2.5/site-packages/numpy/distutils/", line 174, in
    return old_setup(**new_attr)
  File "/usr/lib/python2.5/distutils/", line 151, in setup
  File "/usr/lib/python2.5/distutils/", line 974, in run_commands
  File "/usr/lib/python2.5/distutils/", line 994, in run_command
  File "/usr/lib/python2.5/distutils/command/", line 112, in run
  File "/usr/lib/python2.5/distutils/", line 333, in run_command
  File "/usr/lib/python2.5/distutils/", line 994, in run_command
  File "/usr/lib/python2.5/site-packages/numpy/distutils/command/",
line 121, in run
  File "/usr/lib/python2.5/distutils/command/", line 407, in
  File "/usr/lib/python2.5/site-packages/numpy/distutils/command/",
line 312, in build_extension
    link = self.fcompiler.link_shared_object
AttributeError: 'NoneType' object has no attribute 'link_shared_object'

Comment 1 Jarod Wilson 2007-04-16 21:50:17 UTC
Hrm. Best as I can tell, numpy 1.0.1-3 shouldn't be behaving any differently
here than numpy 1.0.1-1 from back in december. The -2 bump only altered
obsoletes/provides, the -3 bump only included a patch to fix up cpu type
detection (and the files that patch touched aren't showing up in the spew
there). Odd.

Test rebuild of numpy itself is fine, I'll keep poking later this evening...

Comment 2 Jef Spaleta 2007-04-16 23:49:40 UTC
yeah its a little weird... i didnt do anything to the scipy codebase either. I
just attempted a rebuild to trackdown something else and blamo.   Has gfortran
been updated since numpy? It looks like it has. Perhaps gfortran is throwing a
new version string which numpy doesn't recognize? I think numpy tries to detect
compiler version by running gfortran --version

This works just fine on current fc6, and was working fine just after the last
numpy patch and rebuild. ti's a mystery.


Comment 3 Jarod Wilson 2007-04-17 01:51:45 UTC
Yep, looks like its gfortran throwing a wrench in the works.

On devel:
$ f95 --version
GNU Fortran (GCC) 4.1.2 20070403 (Red Hat 4.1.2-8)

On FC6:
$ f95 --version
GNU Fortran 95 (GCC) 4.1.1 20070105 (Red Hat 4.1.1-51)

And numpy/distutils/fcompiler/ looks for a version string starting with
"GNU Fortran 95". Now... The best way around this?... File bug against gfortran
or patch numpy somehow?

Comment 4 Jef Spaleta 2007-04-17 02:05:50 UTC
I think we need to approach the gcc-gfortran maintainer about a patch, since
that is where the underlying changed happened. If that can't be patched then
numpy will need the patch. Is upstream numpy aware of this issue already? 


Comment 5 Jarod Wilson 2007-04-17 03:26:41 UTC
Ticket filed upstream:

Comment 6 Jarod Wilson 2007-04-17 15:49:42 UTC
Okay, an updated numpy build just finished, I've been able to successfully build
and f95 scipy w/it.

Note You need to log in before you can comment on or make changes to this bug.