[Distutils] Was I asleep? (Extension instance message)
Mark W. Alexander
Thu, 24 Aug 2000 13:42:40 -0400 (EDT)
Making setup scripts for all my old modules, I see:
warning: build_ext: old-style (ext_name, build_info) tuple found in ext_modules
for extension '(module_name)'-- please convert to Extension instance
I don't remember this on the list, and I can't find any docs, so I decipher
distutils extension.py and make something like:
myExt=Extension('module_name', ['path/source.c'], libraries=['mylib'])
and then I get:
Traceback (most recent call last):
File "setup.py", line 64, in ?
File "/opt/python-1.6b1/lib/python1.6/distutils/core.py", line 112, in setup
File "/opt/python-1.6b1/lib/python1.6/distutils/dist.py", line 776, in run_commands
File "/opt/python-1.6b1/lib/python1.6/distutils/dist.py", line 797, in run_command
File "/opt/python-1.6b1/lib/python1.6/distutils/command/build.py", line 116, in run
File "/opt/python-1.6b1/lib/python1.6/distutils/dist.py", line 807, in has_ext_modules
return self.ext_modules and len (self.ext_modules) > 0
AttributeError: 'Extension' instance has no attribute '__len__'
I went back to the "old-style" way since it works, but I'd like to buy
a clue on how to properly use an Extension instance. Anyone have a link
to a doc or a list message somewhere?