Sébastien Pierre wrote:
Le lundi 17 décembre 2001, à 09:59 PM, M.-A. Lemburg a écrit :
Sébastien Pierre wrote:
Hi all,
I have a module a module "spam" that contains the "foo.py" file, plus some other files like "burps.xsl" or "bar.xml". What I want to do is when making a "setup.py install" that the "burps.xsl" and "bar.xml" get installed directly into the site-packages in the "spam" module.
Actually distutils seems to ignore non "*.py" files. How can I override this?
You should try to install them using the data_files option. If that doesn't help, you can always subclass the various commands to better fit your needs. See mxSetup.py in egenix-mx-base for an example.
I have looked (quickly) into mxSetup but have not found what I am looking fore. It seems like the data_files do not allow to specify source and target locations in the file system.
If I specify the "spam/bar.xml" in the data_files, will it we outputted in sitepackages/spam/bar.xml ?
Well, you'll have to check the distutils source code for this. AFAIR, it doesn't and that's why I had to add support to distutils to enable this in mxSetup.py (in order to have the docs and license files live inside the package dirs). -- Marc-Andre Lemburg CEO eGenix.com Software GmbH ______________________________________________________________________ Company & Consulting: http://www.egenix.com/ Python Software: http://www.egenix.com/files/python/