Node.js bindings to status-go
Go to file
Adam Babik 35a9c261b7
allow to build with node-gyp
2017-12-07 08:49:14 +01:00
.travis Clean up Travis and automate deployments (#9) 2017-12-06 09:40:23 +01:00
bin Add travis integration files (#6) 2017-11-30 13:54:14 +01:00
src Integrate node-pre-gyp (#7) 2017-12-01 14:57:05 +01:00
test Add bindings tests (#2) 2017-11-27 16:11:57 +01:00
tools/go2nodebinding Integrate node-pre-gyp (#7) 2017-12-01 14:57:05 +01:00
.gitignore Integrate node-pre-gyp (#7) 2017-12-01 14:57:05 +01:00
.npmignore Integrate node-pre-gyp (#7) 2017-12-01 14:57:05 +01:00
.travis.yml use different node.js versions 2017-12-06 10:33:31 +01:00
LICENSE.md Integrate node-pre-gyp (#7) 2017-12-01 14:57:05 +01:00
README.md Integrate node-pre-gyp (#7) 2017-12-01 14:57:05 +01:00
binding.gyp allow to build with node-gyp 2017-12-07 08:49:14 +01:00
index.js Integrate node-pre-gyp (#7) 2017-12-01 14:57:05 +01:00
package-lock.json allow to build with node-gyp 2017-12-07 08:49:14 +01:00
package.json allow to build with node-gyp 2017-12-07 08:49:14 +01:00

README.md

status-nodejs

This project is in pre-alpha version!

This package provides wrappers to status-go bindings.

Instalation

Only manual installation from the repository.

Development

First, you need to get libstatus.a:

  1. Clone status-go repository into proper directory in $GOPATH,
  2. Run make statusgo-library,
  3. Copy libstatus.a and libstatus.h from /path/to/status-go/build/bin/ to ./bin/.

Next, run npm install to build a node.js addon. After that, you should be able to successfully run tests npm test.

Autogenerate bindings from Go code

It's possible to autogenerate C++ code from status-go bindings. First, build autogenerator tool:

go build ./tools/go2nodebinding

then, run it:

./go2nodebinding /path/to/status-go/lib/library.go > ./src/status.cpp

License

Mozilla Public License 2.0.