dabeaz/bitey — pull request #2 by dtcaciuc (2012-08-10 05:35:16+00:00)
Title: Distutils additions for building Bitey modules

Not sure if this is going along with the vision, but should be better than running separate makefile.

Builder creates a package which imports bitey itself and all specified compiled source files. See documentation for ``bitey.disutils.bitey_kwargs`` for details.

Couple of uncertain points:

* Resulting package star-import all symbols from all .o files into the resulting module namespace (eg, given resulting package ``foo`` and ``b.o``, you can do ``from foo import myfunc``). An alternative would be to import the .o files but not their symbols so you would have to ``from foo.b import myfunc``.
* The way .o files are built are not exactly in line with how Extension objects are built; currently, .o files are written directly into ``build/lib`` while Extensions are written to separate directory (and possibly combined with python modules if ``--inplace`` is used). Not quite sure what are the repercussions.

By the way, seems like everything including ``llvm-py`` compiles fine with stock ``clang`` release tarball provided on LLVM website; I did not have to rebuild it with shared libraries even though it provides only static ones (at least for the existing test case)