[Distutils] Newbie questions about setuptools

Edward Ream edreamleo at charter.net
Wed Jun 20 20:35:17 CEST 2007


> I'd suggest following up with the Catalog-SIG or the PyPI support tracker.

Perhaps the multiple mistakes you mention below contributed.  I'll fix 
setup, etc. and then see what happens...

> your setup() is broken

That's good news :-)

> Sorry, you can't not list the modules and still install correctly or build 
> correct binary distributions.

Ok.  I'm using sdist, not bdist_x.  I assume that doesn't matter?

> What is it that you intend to distribute?  Is it one package called 'leo' 
> with a bunch of  subpackages?  Or what?  Is everything in there really a 
> package?  (e.g. why is 'doc' a package?)

It seems my cluelessness has managed to confuse even you.  As you no doubt 
have guessed, this is not easy for me.

I'm not sure of the terminology, so please be patient.  What I want to do is 
distribute Leo (a pure Python application, packaged as a single entity--a 
package?) , consisting of *all* the files under cvs management in leo 
directory and subdirectories of the leo directory that contain a cvs folder.

I stumbled upon the way I chose because it seemed to work.  I added some 
__init__.py files to some folders so they would be included in the list of 
packages, but I would be happy to list individual .py files if that is 
required.  In fact, I would be positively glad to remove the recent 
__init__.py files, as they merely are confusing.

> Your sitecustomize implies that you have a bunch of modules under 'src' --  
> in which case you should list them in py_modules, and include a 
> "package_dir={'': 'src'}" along with a bunch of other tricky-to-get-right 
> things.

Ok.  I can do that.  Are you implying that this is a less-than-recommended 
approach?

>>    packages = setuptools.find_packages(),
> This looks completely hosed, because I assume these should all be 
> subpackages of "leo", not top-level packages.  And you probably don't want 
> a package called "src"!

Correct.  I'll remove this line.

>>    exclude_package_data = { '': ['*.pyc','*.pyo']},
>
> This line is unnecessary; setuptools doesn't consider those files to be 
> package data anyway, and it won't stop them from being put into any eggs 
> built by easy_install.

Thanks.  I'll remove this line.

Ok.  I've got some work to do.  Thank for pointing me in a better direction. 
I'll work on producing something halfway decent, and we can discuss finer 
points later.

Edward
--------------------------------------------------------------------
Edward K. Ream   email:  edreamleo at charter.net
Leo: http://webpages.charter.net/edreamleo/front.html
--------------------------------------------------------------------





More information about the Distutils-SIG mailing list