[C++-sig] using msvc lib in python

benny at coca-kohler.de benny at coca-kohler.de
Mon Aug 18 17:55:21 CEST 2003


hi everybody,

i´m a newbie in extending python. i´ve got the following problem: i´ve got a
library created with visual c++ and some functions in a sample program which
use this library. everything is fine when i compile the library(altough i´m
not an expert in creating libraries) and my sample program also runs. now i
want to expose the functions from my sample program, so that i can use them
in python. therefore i´m using bjam. when i run bjam i get some errors from
the headerfiles. Some Datatypes in the library defined with "typedef" are
unknown. The "typedef" definition is inside a "ifdef" prepocessor statement.

this is my jamfile:

subproject libs/python/example/tutorial ;

SEARCH on python.jam = $(BOOST_BUILD_PATH) ;
include python.jam ;

extension piplib                    # Declare a Python extension called
hello
:   piplib.cpp                      # source
    <dll>../../build/boost_python   # dependencies
    # flags
:   <sysinclude>E:\openpip\lib
    <library-path>E:\openpip\lib\oplib_Debug
    <find-library>oplib

Can anybody help me? Is it possible to create the pyd-file using the Visual
Studio??? i dont wanT to use the command line.

thankz,
ben








More information about the Cplusplus-sig mailing list