Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   Python (http://www.velocityreviews.com/forums/f43-python.html)
-   -   dynamically loaded libraries (http://www.velocityreviews.com/forums/t358139-dynamically-loaded-libraries.html)

mhearne808 05-29-2006 05:00 AM

dynamically loaded libraries
 
I have a question about how dynamically loaded C++ modules work, which
I will phrase as a hypothetical scenario involving the Numeric module.
Please understand that I don't really care about Numeric per se, it's
just a useful example of a module that defines a generally useful data
type.

Let's say I want to create a C++ Python extension module that has
methods accepting the Numeric array type as input, and also create
these arrays as output.

In order to make this work, do I have to statically link against the
Numeric source, or do I only have to include the headers, under the
assumption (??) that the Numeric functionality will be available
because the Python executable has dynamically loaded it?

Thanks!

Mike




Diez B. Roggisch 05-29-2006 08:56 AM

Re: dynamically loaded libraries
 
mhearne808 wrote:

> I have a question about how dynamically loaded C++ modules work, which
> I will phrase as a hypothetical scenario involving the Numeric module.
> Please understand that I don't really care about Numeric per se, it's
> just a useful example of a module that defines a generally useful data
> type.
>
> Let's say I want to create a C++ Python extension module that has
> methods accepting the Numeric array type as input, and also create
> these arrays as output.
>
> In order to make this work, do I have to statically link against the
> Numeric source, or do I only have to include the headers, under the
> assumption (??) that the Numeric functionality will be available
> because the Python executable has dynamically loaded it?


You'll only need the dynamic libs. Of course they must be available on link-
as well as run-time.


Diez


All times are GMT. The time now is 01:26 AM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.