[Nipy-devel] Setup.py and platform specific shared objects

Yaroslav Halchenko lists@onerussian....
Wed Jan 12 12:07:57 CST 2011


Hi Eleftherios,

Great to see that you are leaping forward toward the release!  We should
start cooking Debian packaging for DiPy.

Unfortunately I cannot give a complete and exhaustive answer to your
question (how to setup the distribution), in part because it is
not clear either we are talking about source, binary distribution or you
are trying to meld those two together.  In the other part -- I am myself
not very experienced with distribution outside of the Linux (and Debian
in particular) world; distutils, setuptools (distribute), easy_install,
pip, ...  -- variety and Python-specificity somewhat scares me there
especially when I think about users who are not (yet) Python-savvy.

Nevertheless let me point out few aspects

Generic aspect of "binaries" in VCS:

Quite a few projects (especially among Matlab toolboxes) meld binary and
source distribution together by keeping pre-built binary blobs in
the same version control/branch as the source tree.  Although it makes
things somewhat simpler (especially for users/contributors who just
check out necessary revision and could use/tune the tool without
building anything), it severely impairs repository handling, especially
in the case of centralized VCS as SVN.  Therefore, if you decided to go
that way (keeping pre-built binary blobs under VCS, GIT in your case), I
would strongly advise to use appropriate mechanism to keep source tree
pristine.  You could either carry them in a separate branch
(release-binary) where you pre-build those and which you advice to use
for the users, or just stuck them all in a separate repository which you
link to your repository as a git submodule.  Imho 2nd one is preferable
since it would keep your source repository size not growing wildly, thus
handling better, and  so that in the future you could easily drop this
approach and shrink your repository without rewriting it entirely.

OSX Bundles:

Initially convenient  way of bundling everything together for OSX users,
might create more complications in the long run, especially since
DiPy is a module and users might want to incorporate it into analysis
pipelines which use tools which are not available within the bundle...
then they would need, if possible, to  bring Dipy in the space of other
bundles/distributions they have on the system (i.e. via .pth files).


Linux

should be no difficulty for people to have it built/installed in general
especially if .c code for .pyx is shipped along within source
distribution (VCS) -- compiler is nearly always there ;-)  so simple
setup.py using distutils (setuptools) should be enough for those
desiring build it themselves.

external dependencies (e.g. nibabel) probably should not be a part
of it, but rather, upon demand easily installable (easy_install, unless
OS provides them via system-level tools, e.g. apt on Debian systems)

Sorry if this does not answer your question... I can only promise that
on Debian systems installation will be a breeze and dipy would become
easily usable with any other python module people would like to use
along with dipy ;-)

Best regards,
Yarik

On Wed, 12 Jan 2011, Eleftherios Garyfallidis wrote:
>    We want to make dipy to be installed very easily to all 3 platforms
>    Linux,Windows and Mac. As you know in dipy we use cython and although
>    you can install cython even with easy_install these day you need to
>    have a compiler on your system which could be a problem for some users.
>    Therefore we would prefer to provide the compiled code for the cython
>    modules with our installation and to be platform specific.
-- 
=------------------------------------------------------------------=
Keep in touch                                     www.onerussian.com
Yaroslav Halchenko                 www.ohloh.net/accounts/yarikoptic



More information about the Nipy-devel mailing list