What are best practices for building CFFI modules during development?
Right now I'm using a Makefile:
mylib/_ffi.so: my_lib/build_ffi.py
python $<
And then to test I can use:
$ make && python test.py
But this seems suboptimal. Is there a better way of building CFFI modules during development?
If the project is using setuptools, python setup.py develop
appears to build the library in-place:
$ python setup.py develop
...
Finished processing dependencies for my-lib==0.1
$ ls my_lib/
_ffi.so
...
But it doesn't seem like there is a make clean
equivilent (setup.py clean
only cleans the build/
directory), so it isn't quite ideal.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With