Open cculianu opened 5 years ago
Notes from conversation with Mark:
setup.py probably should compile before install as part of the install (by running make_secp
)
the generated .so
is to be put it wherever ourlib/
.py
files get installed.
If compilation fails for whatever reason install should still proceed (?) but then users will get nagged as they run the CashShuffle edition and if they participate in shuffles (with no way to turn off the nagger) with instructions on what to do to get secp.
As discussed with Mark -- we will offer it bundled with the "srcdist" as well as nag users if we detect they don't have it, with instructions on how to install it.
A "make_secp" script will be added to contrib/ and will get installed along with the py-egg of Electron Cash.
This script will be very portable so the odd user that doesn't have x86 or x86_64 on Linux will at least be able to run this script (eg BSD users, exotic architectures) and it will auto-download and auto-build libsecp256k1.
We will be using the same commit hash that Bitcoin ABC uses of the secp lib.
The lib would ideally be built for whatever architecture the user is on but if we do also offer it bundled in the src-dist.. perhaps also bundle both x86 and x86-64 on Linux.
The setup.py auto-build will of course only build for that local machine.
Compile options for the pre-built lib should be ultra-conservative, most-compatible, no libgmp or other external deps, etc. Any native code is super fast compared to python signing and we want it to "just work".