annotatec helps you create Python packages with C embeddings.
Imagine you're developing C library and already have more than 50 functions. Sometimes you change signatures of old functions or rename them. It'll be headache to write and support all ctypes-declarations for Python wrapper. annotatec will create all Python objects for you. All you need is to provide declarations, which can be placed directly into your C code.
Minimal livable example
You have some library lib.c and it's header lib.h. These files were compiled into lib.so (or lib.dll in Windows).
lib.c source:
#include "lib.h"
int sum(int a, short b, long long c) { return a + b + c; }
lib.h source:
/* @function sum
* @return int
* @argument int
* @argument short
* @argument longlong
*/
int sum(int, short, long long);
Here's a Python wrapper:
import annotatec
libc = annotatec.Loader(
library="lib.so", headers=["lib.h"])
That's all! Now you can test it like so:
>>> libc.sum(1, 2, 3)
<<< 6
Reference
Read detailed reference in wiki-pages.
Metadata
Release files for annotatec 1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| annotatec-1.0.tar.gz | 12.0 kB | Without provenance | Details for annotatec-1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| annotatec-1.0-py3-none-any.whl | Python 3 | none | any | Details for annotatec-1.0-py3-none-any.whl |
Total release size: 14.8 kB
Release files / annotatec-1.0.tar.gz
| Download URL | annotatec-1.0.tar.gz |
|---|---|
| Size | 12.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c8a9f30ff3f24f21f3b91c4c8b8d04aab1ebd26ba1c34d8454a976263015c5ef
|
|
BLAKE2b-256 checksum How to use checksums |
a256eed223df9c63850fe401ef3479daee3567537b193e2a1c573f817f4b6fa8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.8.10
|
Release files / annotatec-1.0-py3-none-any.whl
| Download URL | annotatec-1.0-py3-none-any.whl |
|---|---|
| Size | 2.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9039b6a45aa8b0a5f996678f0d149430f7ee50473daa03a01e001b2db01dc22a
|
|
BLAKE2b-256 checksum How to use checksums |
79edc3e992fbb8769d6f1d9673e6344e729a9d2b55e1d1d224fa1d0d2dc5d118
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.8.10
|
Security for annotatec 1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.