[Distutils] I finally got the kiva rpm to build using bdist_rpm
Stanley A. Klein
sklein at cpcug.org
Mon Aug 20 23:15:38 CEST 2007
The overall kiva package is built by a combination of numpy distutils and
setuptools. There are multiple setup.py files involved because of the
needs of numpy distutils for compiling the extensions. Somehow the
setup() of the main setup.py is used by both numpy distutils and
setuptools. The relevant import statements are
from numpy.distutils.core import setup
The tests directory under kiva is referenced in the setup.py
configuration() there as config.add_data_dir('tests'). There is a similar
statement in the setup.py file under kiva/agg.
I tried to move the "tests" directories under both kiva and kiva/agg to
the top-level examples directory without doing an svn check-in. That
didn't seem to work, I suppose because of setuptools svn awareness.
I tried numerous other fixes, some that I came up with on my own and
others suggested by Dave Peterson and this is the only one that ran to
completion. However, I don't remember everything I tried.
One thing I did try was an in-place build (using kivabuild.py that mainly
uses numpy distutils) to get the extensions built and a relatively vanilla
setup.py file with setuptools to do the install and packaging steps. That
approach left the .so files missing from the package.
If there is a cleaner way to do the rpm package for kiva, I would prefer
to use it, but I haven't found one yet. I got the idea for this
workaround approach from a posting somewhere by someone who had a similar
problem with rpm packaging.
On Mon, August 20, 2007 1:38 pm, Phillip J. Eby wrote:
> At 12:30 PM 8/20/2007 -0400, Stanley A. Klein wrote:
> Is kiva.agg.tests a package? If so, is it listed in setup()? If
> not, are the individual modules listed as modules to be installed?
> If these are just .py files, that would explain why they're not
> listed in INSTALLED_FILES.
More information about the Distutils-SIG