[C++-sig] Multiple modules in a single pyd

Olivier Voyer olivier.voyer at gmail.com
Tue Nov 15 16:52:28 CET 2011


Bingo! But I'm not sure how to do that... at this moment I'm using SWIG as
a C++ wrapper. Do I only need to modify the __init__py file at the root of
my package?

On Tue, Nov 15, 2011 at 10:47 AM, Wichert Akkerman <wichert at wiggy.net>wrote:

> On 11/15/2011 04:42 PM, Olivier Voyer wrote:
>
>> Yes, that's exactly what I want to do. But, from what I understand, each
>> module or submodule (.py file) must link to its own .pyd file, ie
>> module1.py -> _module1.pyd, module2.py -> _module2.pyd.
>>
>> What I would really love to have is:
>>
>> myPackage/
>> myPackage/__init__.py
>> myPackage/module1.py -> linked to _mySingleAPI.pyd
>> myPackage/module2.py -> linked to _mySingleAPI.pyd
>>
>
> Why not make mySingleAPI.pyd a single extension myPackage.pyd module that
> creates myPackage, myPackage.module1, etc. all at once? You don't need to
> have separate files for each module if you do that.
>
> Wichert.
>
>
> ______________________________**_________________
> Cplusplus-sig mailing list
> Cplusplus-sig at python.org
> http://mail.python.org/**mailman/listinfo/cplusplus-sig<http://mail.python.org/mailman/listinfo/cplusplus-sig>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/cplusplus-sig/attachments/20111115/7a157a64/attachment.html>


More information about the Cplusplus-sig mailing list