Skip to main content

Create python wrappers that call c functions (without the headaches).

Project description


Create python wrappers that call c functions, without the headaches.

In a nutshell:

from c2py import dispatch
m = dispatch(
    src,  # specification of the C sources (poiting to specific C functions)
	convention,  # optional convention of wrapping rules
	**configs  # specific configuration (for wrapping rules that are not covered by convention, or need to be overwritten)

m.python_wrapper_to_c_func(...)  # now m is a module containing python wrappers to the desired c functions

Other forms:

dispatch_to_file(src, target_filepath, ...)  # to get output as a persisted .py file

To install: pip install c2py

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

c2py-0.0.1.tar.gz (1.5 kB view hashes)

Uploaded source

Built Distribution

c2py-0.0.1-py3-none-any.whl (2.3 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page