Comments (1)
To make this work on Node8 you have to rewrite multihashing.cc like:
void quark(const FunctionCallbackInfo<Value>& args) {
Isolate* isolate = args.GetIsolate();
HandleScope scope(isolate);
if (args.Length() < 1) {
isolate->ThrowException(Exception::TypeError(
String::NewFromUtf8(isolate, "You must provide one argument.")));
return;
}
Local<Object> target = args[0]->ToObject();
if(!Buffer::HasInstance(target)) { //?
isolate->ThrowException(Exception::TypeError(
String::NewFromUtf8(isolate, "Argument should be a buffer object.")));
return;
}
char* input = Buffer::Data(target);
char output[32];
uint32_t input_len = Buffer::Length(target);
quark_hash(input, output, input_len);
args.GetReturnValue().Set(Buffer::Copy(isolate, (char*) &output, 32).ToLocalChecked());
}
// do the same for all methods
void init(Local<Object> exports) {
NODE_SET_METHOD(exports, "quark", quark);
// do the same for all methods
from node-multi-hashing.
Related Issues (20)
- Hi, I am having an issue with performing a NPM update that is looking for the multi-hashing
- Is it possible to add manually additional algorithms in node-multi-hashing?
- Feature request: Add support for Hodlcoin - 1GB AES Pattern Search POW
- r
- Add x17 algo
- Cryptonight variant for v7 seems incorrect HOT 3
- Failed at the [email protected] install script. HOT 2
- If you are looking for node bindings for an up to date version (9.5.0) HOT 2
- Using from the web
- what's the difference between this and nomp HOT 1
- NOMP npm update fail @ multihashing. HOT 4
- Please add the new / Forked Algo Support - CN-AscendingNight
- scryptjane errors compiling on Mac OS Node 10.14. Please advice.
- Monero RandomX supports HOT 1
- kawpow support
- kawpow
- Failed to build multihashing with npm > 9.11.2 HOT 1
- Is this new defacto active main? tons of forks but not seeing many commits over this one HOT 1
- Build failure / make fails
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from node-multi-hashing.