Home | About | Sematext search-lucene.com search-hadoop.com
 Search Lucene and all its subprojects:

Switch to Threaded View
PyLucene, mail # dev - Changes to enable easy_install of packages using JCC

Copy link to this message
Re: Changes to enable easy_install of packages using JCC
Bill Janssen 2012-02-02, 16:29
Andi Vajda <[EMAIL PROTECTED]> wrote:

> On Feb 1, 2012, at 20:49, Bill Janssen <[EMAIL PROTECTED]> wrote:
> > Andi Vajda <[EMAIL PROTECTED]> wrote:
> >
> >> Seriously, though, I think that the right thing to do to better
> >> integrate JCC with distutils/setuptools/distribute/pip/etc... is to
> >> make it into a distutils 'compiler'. This requires some work, though,
> >> and I haven't done it in all thee years. Anyone with the itch to hack
> >> on distutils is welcome to take that on.
> >
> > The future here is Python 3.3's "packaging" (aka "distutils2", on
> > earlier versions of Python):
> >
> > try:
> >    import packaging
> > except ImportError:
> >    import distutils2
> >
> >
> >> Additionally, issue 43 is all about using the distutils/setuptools
> >> compiler and linker invocation machinery for building a vanilla shared
> >> library (as opposed to a Python extension). On linux this is a bit
> >> cumbersome. On Windows, at little less so. On Mac OS X, it just works.
> >>
> >> The alternative would be to write a 'configure' script for that part
> >> of the JCC build. A configure script would also solve the chicken/egg
> >> problem of building that library on Windows (the first time, the build
> >> needs to be done twice for the import library to be in the right
> >> place).
> >>
> >> Currently, I'm leaning towards the configure script solution since
> >> none of the projects mentioned above seems to have taken issue 43 on
> >> (by simply integrating my patches) in all these years and Pylucene's
> >> issue 13 is curently blocked:
> >> https://issues.apache.org/jira/browse/PYLUCENE-13?focusedCommentId=13162273&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13162273
> >>
> >> I have very little itch to dabble in configure scripts either so I've
> >> been dragging my feet. If someone were to step forward with a patch
> >> for that, I'd be delighted in ripping out all this patching
> >> brittleness.
> >
> > I have big chunks of such a configure script written (for Windows/OS
> > X/Linux) which I'd be happy to contribute.
> That would be cool. What are the missing chunks made off ?
> Andi..

Hard to say what the *missing* chunks are made of -- chocolate?

What I've got is a configure.in script for UpLib, part of which is
designed to figure out the necessary parameters to build JCC and
PyLucene properly on those systems.  But it still uses setuptools,
which is still going to be broken.

I think the right thing to do is to

1.  re-write the current jcc setup.py to use distutils2, and then

2.  at the PyLucene level, add a configure.ac script which figures out
    the proper settings for those six or so defines in the Makefile,
    which is a fairly trivial configure script.