skip to navigation
skip to content

xbob.extension 0.1.6

Helps projects building Python/C++ extensions for Bob

Latest Version: 0.2.1

This package provides a pkg-config bridge for Python/C++ extensions for Bob. You use this package by including it in the setup_requires field of your file.

Building with zc.buildout is possible using the develop recipe in xbob.buildout. Follow the instructions described on that package for this recipe.

Preparing for C++ Compilation

Creating C++/Python bindings should be trivial. Firstly, edit your so that you include the following:

from xbob.extension import Extension




      pkgconfig = [ #bob modules you depend on
      include_dirs = [ #optionally, include directories
    ... #add more extensions if you wish


These modifications will allow you to compile extensions that are linked against the named pkg-config modules. You can specify the modules of Bob you want to link against. You don’t have to specify bob-python, which is automatically added. Furthermore, you can specify any pkg-config module and that will be linked in (for example, opencv). Other modules and options can be set manually using the standard options for python extensions. To hook-in the building on the package through zc.buildout, add the following section to your buildout.cfg:

recipe = xbob.buildout:develop

If you need to build multiple eggs, you will need one entry per project on your buildout.cfg. This includes, possibly, dependent projects. Currently, zc.buildout ignores the setup_requires entry on your file. The recipe above creates a new interpreter that hooks that package in and builds the project considering variables like prefixes into consideration.

File Type Py Version Uploaded on Size (md5) Source 2013-03-07 9KB
  • Downloads (All Versions):
  • 1 downloads in the last day
  • 120 downloads in the last week
  • 675 downloads in the last month