ethsnarks icon indicating copy to clipboard operation
ethsnarks copied to clipboard

Submodules for different gadgets & components

Open HarryR opened this issue 7 years ago • 1 comments

It would be good to make the libsnark based gadgets available as submodules so they can be included in other projects.

Will figure out how to do this.

HarryR avatar Aug 14 '18 07:08 HarryR

I think it could be split into the following sub-repos:

  • ethsnarks-python - Python support
  • ethsnarks-js - Javascript support (hopefully)
  • ethsnarks-cxx - Gadgets and components in C++ for libsnark

Then the main ethsnarks repository combines them together, along with a libsnark distribution and build system, then ethsnarks-emscripten uses ethsnarks as a submodule to build it all for WebAssembly.

This would allow other projects to import only the functionality they need in the appropriate repository.

The ethsnarks repository would still have some C++ code where it combines the gadgets together.

My concerns are:

  • the developer complexity of integration tests across multiple repositories
  • building ethsnarks-cxx standalone, it wouldn't have libsnark as a submodule, and I don't think the CMake FindPKG would work well when it's a submodule of the ethsnarks project - or... work well at all for anybody. So it'd just have to be source code and some optional CMake files.

HarryR avatar Aug 17 '18 16:08 HarryR