[Numpy-discussion] build problem on windows: python26.dll not found

Skipper Seabold jsseabold@gmail....
Fri Jul 16 16:50:54 CDT 2010


I am way out of my element trying to build numpy on Windows, but we
are having a replicable (though somewhat inconsistently on some
machines) problem using fmin_cg on Windows that I am trying to debug.

I'm on Windows 7 64-bit with Python 2.6.4

First, I try to build numpy.  It complains about having no
C:\windows\system32\python26.dll, but note

C:\Users\skipper>dir %windir%\system32\python26.dll
 Volume in drive C has no label.
 Volume Serial Number is 182E-23CE

 Directory of C:\Windows\system32

10/26/2009  08:36 AM         2,764,288 python26.dll
               1 File(s)      2,764,288 bytes
               0 Dir(s)  72,496,721,920 bytes free


C:\Users\skipper\source\numpy>python setup.py config --compiler=mingw32 build --
compiler=mingw32 bdist_wininst
Running from numpy source directory.Forcing DISTUTILS_USE_SDK=1
F2PY Version 2_8480
blas_opt_info:
blas_mkl_info:
  libraries mkl,vml,guide not found in C:\Users\skipper\source\atlaslib32
  NOT AVAILABLE

atlas_blas_threads_info:
Setting PTATLAS=ATLAS
  libraries ptf77blas,ptcblas,atlas not found in C:\Users\skipper\source\atlasli
b32
  NOT AVAILABLE

atlas_blas_info:
  FOUND:
    libraries = ['f77blas', 'cblas', 'atlas']
    library_dirs = ['C:\\Users\\skipper\\source\\atlaslib32']
    language = c

C:\Users\skipper\source\numpy\numpy\distutils\command\config.py:397: Deprecation
Warning:
+++++++++++++++++++++++++++++++++++++++++++++++++
Usage of get_output is deprecated: please do not
use it anymore, and avoid configuration checks
involving running executable on the target machine.
+++++++++++++++++++++++++++++++++++++++++++++++++

  DeprecationWarning)
No module named msvccompiler in numpy.distutils; trying from distutils
  FOUND:
    libraries = ['f77blas', 'cblas', 'atlas']
    library_dirs = ['C:\\Users\\skipper\\source\\atlaslib32']
    language = c
    define_macros = [('ATLAS_INFO', '"\\"?.?.?\\""')]

lapack_opt_info:
lapack_mkl_info:
mkl_info:
  libraries mkl,vml,guide not found in C:\Users\skipper\source\atlaslib32
  NOT AVAILABLE

  NOT AVAILABLE

atlas_threads_info:
Setting PTATLAS=ATLAS
  libraries ptf77blas,ptcblas,atlas not found in C:\Users\skipper\source\atlasli
b32
  libraries lapack_atlas not found in C:\Users\skipper\source\atlaslib32
numpy.distutils.system_info.atlas_threads_info
  NOT AVAILABLE

atlas_info:
  libraries lapack_atlas not found in C:\Users\skipper\source\atlaslib32
numpy.distutils.system_info.atlas_info
  FOUND:
    libraries = ['lapack', 'f77blas', 'cblas', 'atlas']
    library_dirs = ['C:\\Users\\skipper\\source\\atlaslib32']
    language = f77

No module named msvccompiler in numpy.distutils; trying from distutils
  FOUND:
    libraries = ['lapack', 'f77blas', 'cblas', 'atlas']
    library_dirs = ['C:\\Users\\skipper\\source\\atlaslib32']
    language = f77
    define_macros = [('ATLAS_INFO', '"\\"?.?.?\\""')]

non-existing path in '': 'site.cfg.example'
running config
running build
running config_cc
unifing config_cc, config, build_clib, build_ext, build commands --compiler opti
ons
running config_fc
unifing config_fc, config, build_clib, build_ext, build commands --fcompiler opt
ions
running build_src
build_src
building py_modules sources
building library "npymath" sources
Looking for python26.dll
Building import library (arch=AMD64): "C:\Python26\libs\libpython26.a" (from C:\
Windows\system32\python26.dll)
C:\Windows\system32\python26.dll
C:\Python26\libs\python26.def
objdump.exe: 'C:\Windows\system32\python26.dll': No such file
Traceback (most recent call last):
  File "setup.py", line 210, in <module>
    setup_package()
  File "setup.py", line 203, in setup_package
    configuration=configuration )
  File "C:\Users\skipper\source\numpy\numpy\distutils\core.py", line 186, in set
up
    return old_setup(**new_attr)
  File "C:\Python26\lib\distutils\core.py", line 152, in setup
    dist.run_commands()
  File "C:\Python26\lib\distutils\dist.py", line 975, in run_commands
    self.run_command(cmd)
  File "C:\Python26\lib\distutils\dist.py", line 995, in run_command
    cmd_obj.run()
  File "C:\Users\skipper\source\numpy\numpy\distutils\command\build.py", line 37
, in run
    old_build.run(self)
  File "C:\Python26\lib\distutils\command\build.py", line 134, in run
    self.run_command(cmd_name)
  File "C:\Python26\lib\distutils\cmd.py", line 333, in run_command
    self.distribution.run_command(command)
  File "C:\Python26\lib\distutils\dist.py", line 995, in run_command
    cmd_obj.run()
  File "C:\Users\skipper\source\numpy\numpy\distutils\command\build_src.py", lin
e 152, in run
    self.build_sources()
  File "C:\Users\skipper\source\numpy\numpy\distutils\command\build_src.py", lin
e 163, in build_sources
    self.build_library_sources(*libname_info)
  File "C:\Users\skipper\source\numpy\numpy\distutils\command\build_src.py", lin
e 298, in build_library_sources
    sources = self.generate_sources(sources, (lib_name, build_info))
  File "C:\Users\skipper\source\numpy\numpy\distutils\command\build_src.py", lin
e 385, in generate_sources
    source = func(extension, build_dir)
  File "numpy\core\setup.py", line 673, in get_mathlib_info
    st = config_cmd.try_link('int main(void) { return 0;}')
  File "C:\Python26\lib\distutils\command\config.py", line 257, in try_link
    self._check_compiler()
  File "C:\Users\skipper\source\numpy\numpy\distutils\command\config.py", line 4
5, in _check_compiler
    old_config._check_compiler(self)
  File "C:\Python26\lib\distutils\command\config.py", line 107, in _check_compil
er
    dry_run=self.dry_run, force=1)
  File "C:\Users\skipper\source\numpy\numpy\distutils\ccompiler.py", line 561, i
n new_compiler
    compiler = klass(None, dry_run, force)
  File "C:\Users\skipper\source\numpy\numpy\distutils\mingw32ccompiler.py", line
 91, in __init__
    build_import_library()
  File "C:\Users\skipper\source\numpy\numpy\distutils\mingw32ccompiler.py", line
 282, in build_import_library
    return _build_import_library_amd64()
  File "C:\Users\skipper\source\numpy\numpy\distutils\mingw32ccompiler.py", line
 305, in _build_import_library_amd64
    generate_def(dll_file, def_file)
  File "C:\Users\skipper\source\numpy\numpy\distutils\mingw32ccompiler.py", line
 252, in generate_def
    if i == len(dump):
UnboundLocalError: local variable 'i' referenced before assignment


More information about the NumPy-Discussion mailing list