dachev / node-cld Goto Github PK
View Code? Open in Web Editor NEWLanguage detection for Javascript (Node). Based on the CLD2 (Compact Language Detector) library from Google.
License: Apache License 2.0
Language detection for Javascript (Node). Based on the CLD2 (Compact Language Detector) library from Google.
License: Apache License 2.0
The calling script declares --max_old_space_size=8000
, so it's a OOM that happens internally.
<--- Last few GCs --->
380732 ms: Mark-sweep 7855.8 (8034.6) -> 7855.8 (8034.6) MB, 5755.0 / 0.0 ms [allocation failure] [GC in old space requested].
386622 ms: Mark-sweep 7855.8 (8034.6) -> 7855.8 (8034.6) MB, 5889.0 / 0.0 ms [allocation failure] [GC in old space requested].
392326 ms: Mark-sweep 7855.8 (8034.6) -> 7856.9 (8010.6) MB, 5701.8 / 0.0 ms [last resort gc].
398245 ms: Mark-sweep 7856.9 (8010.6) -> 7858.1 (8010.6) MB, 5917.4 / 0.0 ms [last resort gc].
<--- JS stacktrace --->
==== JS stack trace =========================================
Security context: 0x150f40cfb51 <JS Object>
1: detect [//node_modules/cld/index.js:61] [pc=0x23345692ca6b] (this=0xc9cb524ca59 <an Object with map 0x17cc3fa1e611>,text=0x31a6cf836a91 <String[269]: can make you happy jump in you know these arms can feel you up jump you want to taste my kisses in the night then jump jum...
FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory
1: node::Abort() [/usr/local/bin/node]
2: node::FatalException(v8::Isolate*, v8::Local<v8::Value>, v8::Local<v8::Message>) [/usr/local/bin/node]
3: v8::internal::V8::FatalProcessOutOfMemory(char const*, bool) [/usr/local/bin/node]
4: v8::internal::Factory::NewTransitionArray(int) [/usr/local/bin/node]
5: v8::internal::TransitionArray::Insert(v8::internal::Handle<v8::internal::Map>, v8::internal::Handle<v8::internal::Name>, v8::internal::Handle<v8::internal::Map>, v8::internal::SimpleTransitionFlag) [/usr/local/bin/node]
6: v8::internal::Map::CopyReplaceDescriptors(v8::internal::Handle<v8::internal::Map>, v8::internal::Handle<v8::internal::DescriptorArray>, v8::internal::Handle<v8::internal::LayoutDescriptor>, v8::internal::TransitionFlag, v8::internal::MaybeHandle<v8::internal::Name>, char const*, v8::internal::SimpleTransitionFlag) [/usr/local/bin/node]
7: v8::internal::Map::CopyAddDescriptor(v8::internal::Handle<v8::internal::Map>, v8::internal::Descriptor*, v8::internal::TransitionFlag) [/usr/local/bin/node]
8: v8::internal::Map::CopyWithField(v8::internal::Handle<v8::internal::Map>, v8::internal::Handle<v8::internal::Name>, v8::internal::Handle<v8::internal::FieldType>, v8::internal::PropertyAttributes, v8::internal::Representation, v8::internal::TransitionFlag) [/usr/local/bin/node]
9: v8::internal::Map::TransitionToDataProperty(v8::internal::Handle<v8::internal::Map>, v8::internal::Handle<v8::internal::Name>, v8::internal::Handle<v8::internal::Object>, v8::internal::PropertyAttributes, v8::internal::Object::StoreFromKeyed) [/usr/local/bin/node]
10: v8::internal::LookupIterator::PrepareTransitionToDataProperty(v8::internal::Handle<v8::internal::JSObject>, v8::internal::Handle<v8::internal::Object>, v8::internal::PropertyAttributes, v8::internal::Object::StoreFromKeyed) [/usr/local/bin/node]
11: v8::internal::Object::AddDataProperty(v8::internal::LookupIterator*, v8::internal::Handle<v8::internal::Object>, v8::internal::PropertyAttributes, v8::internal::Object::ShouldThrow, v8::internal::Object::StoreFromKeyed) [/usr/local/bin/node]
12: v8::internal::Runtime::SetObjectProperty(v8::internal::Isolate*, v8::internal::Handle<v8::internal::Object>, v8::internal::Handle<v8::internal::Object>, v8::internal::Handle<v8::internal::Object>, v8::internal::LanguageMode) [/usr/local/bin/node]
13: v8::Object::Set(v8::Local<v8::Context>, v8::Local<v8::Value>, v8::Local<v8::Value>) [/usr/local/bin/node]
14: NodeCld::Detect(Nan::FunctionCallbackInfo<v8::Value> const&) [//node_modules/cld/build/Release/cld.node]
15: Nan::imp::FunctionCallbackWrapper(v8::FunctionCallbackInfo<v8::Value> const&) [/node_modules/cld/build/Release/cld.node]
16: v8::internal::FunctionCallbackArguments::Call(void (*)(v8::FunctionCallbackInfo<v8::Value> const&)) [/usr/local/bin/node]
17: v8::internal::MaybeHandle<v8::internal::Object> v8::internal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::Isolate*, v8::internal::(anonymous namespace)::BuiltinArguments<(v8::internal::BuiltinExtraArguments)1>) [/usr/local/bin/node]
18: v8::internal::Builtin_HandleApiCall(int, v8::internal::Object**, v8::internal::Isolate*) [/usr/local/bin/node]
19: 0x2334564092a7
Abort trap: 6
Hello.
I found that. you use callback in synchronous.
Thank you.
npm install cld
fails with the following error. Let me know if you need any testing.
$ "C:\Program Files\nodejs\npm.cmd" install cld
npm http GET https://registry.npmjs.org/cld
npm http 304 https://registry.npmjs.org/cld
npm http GET https://registry.npmjs.org/underscore
npm http GET https://registry.npmjs.org/nan
npm http 304 https://registry.npmjs.org/nan
npm http 304 https://registry.npmjs.org/underscore
-
> [email protected] install C:\Users\iki\..sl\.test-generators\.tmp\node_modules\cld
> node-gyp rebuild
C:\Users\iki\..sl\.test-generators\.tmp\node_modules\cld>node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin
\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild
Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
C:\Users\iki\..sl\.test-generators\.tmp\node_modules\cld\build\binding.sln : Solution file error MSB5004: The solution
file has two projects named "cld".
gyp ERR! build error
gyp ERR! stack Error: `msbuild` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:2
67:23)
gyp ERR! stack at ChildProcess.emit (events.js:98:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:810:12)
gyp ERR! System Windows_NT 6.2.9200
gyp ERR! command "node" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuil
d"
gyp ERR! cwd C:\Users\iki\..sl\.test-generators\.tmp\node_modules\cld
gyp ERR! node -v v0.10.32
gyp ERR! node-gyp -v v1.0.1
gyp ERR! not ok
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is most likely a problem with the cld package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls cld
npm ERR! There is likely additional logging output above.
npm ERR! System Windows_NT 6.2.9200
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js"
"install" "cld"
npm ERR! cwd C:\Users\iki\..sl\.test-generators\.tmp
npm ERR! node -v v0.10.32
npm ERR! npm -v 1.4.28
npm ERR! code ELIFECYCLE
npm ERR! not ok code 0
npm install cld
|
[email protected] install /root/xxx/node_modules/cld
node-gyp rebuild
child_process: customFds option is deprecated, use stdio instead.
make: Entering directory '/root/xxx/node_modules/cld/build'
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil_shared.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_hint_code.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_impl.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/debug.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/fixunicodevalue.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_entities.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_language.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_ulscript.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/getonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/lang_script.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/offsetmap.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/scoreonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/tote.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/utf8statetable.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_uni_prop_80.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_cjk_compatible.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_delta_bi_32.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_distinct_bi_0.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quad0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_deltaocta0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_deltaoctachrome.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_distinctocta0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_distinctoctachrome.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quadchrome_16.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quadchrome_2.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_2.o
AR(target) Release/obj.target/deps/cld/cld-c.a
COPY Release/cld-c.a
CXX(target) Release/obj.target/cld/src/constants.o
CXX(target) Release/obj.target/cld/src/cld.o
SOLINK_MODULE(target) Release/obj.target/cld.node
ld: fatal: symbol 'CLD2::kDeltaOcta_obj2' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld2_generated_deltaocta0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld2_generated_deltaoctachrome.o) type=OBJT);
ld: fatal: symbol 'CLD2::kDeltaOcta2IndSize' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld2_generated_deltaocta0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld2_generated_deltaoctachrome.o) type=OBJT);
ld: fatal: symbol 'CLD2::kDeltaOcta_obj' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld2_generated_deltaocta0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld2_generated_deltaoctachrome.o) type=OBJT);
ld: fatal: symbol 'CLD2::kDeltaOctaIndSize' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld2_generated_deltaocta0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld2_generated_deltaoctachrome.o) type=OBJT);
ld: fatal: symbol 'CLD2::kDistinctOcta_obj2' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld2_generated_distinctocta0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld2_generated_distinctoctachrome.o) type=OBJT);
ld: fatal: symbol 'CLD2::kDistinctOcta2IndSize' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld2_generated_distinctocta0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld2_generated_distinctoctachrome.o) type=OBJT);
ld: fatal: symbol 'CLD2::kDistinctOcta_obj' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld2_generated_distinctocta0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld2_generated_distinctoctachrome.o) type=OBJT);
ld: fatal: symbol 'CLD2::kDistinctOctaIndSize' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld2_generated_distinctocta0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld2_generated_distinctoctachrome.o) type=OBJT);
ld: fatal: symbol 'CLD2::kQuad_obj2' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld2_generated_quad0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld2_generated_quadchrome_16.o) type=OBJT);
ld: fatal: symbol 'CLD2::kQuad_obj' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld2_generated_quad0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld2_generated_quadchrome_16.o) type=OBJT);
ld: fatal: symbol 'CLD2::kQuad_obj2' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld2_generated_quad0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld2_generated_quadchrome_2.o) type=OBJT);
ld: fatal: symbol 'CLD2::kQuad_obj' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld2_generated_quad0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld2_generated_quadchrome_2.o) type=OBJT);
ld: fatal: symbol 'CLD2::kAvgDeltaOctaScore' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld_generated_score_quad_octa_0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld_generated_score_quad_octa_2.o) type=OBJT);
ld: fatal: symbol 'CLD2::kAvgDeltaOctaScoreSize' is multiply-defined:
(file Release/obj.target/deps/cld/cld-c.a(cld_generated_score_quad_octa_0122.o) type=OBJT; file Release/obj.target/deps/cld/cld-c.a(cld_generated_score_quad_octa_2.o) type=OBJT);
ld: fatal: file processing errors. No output written to Release/obj.target/cld.node
collect2: error: ld returned 1 exit status
SOLINK_MODULE(target) Release/obj.target/cld.node: Finished
COPY Release/cld.node
cp: cannot stat ‘Release/obj.target/cld.node’: No such file or directory
cld.target.mk:132: recipe for target 'Release/cld.node' failed
make: *** [Release/cld.node] Error 1
make: Leaving directory '/root/xxx/node_modules/cld/build'
gyp ERR! build error
gyp ERR! stack Error: make
failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/opt/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:267:23)
gyp ERR! stack at ChildProcess.emit (events.js:110:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:1067:12)
gyp ERR! System SunOS 5.11
gyp ERR! command "node" "/opt/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /root/xxx/node_modules/cld
gyp ERR! node -v v0.12.0
gyp ERR! node-gyp -v v1.0.2
gyp ERR! not ok
npm ERR! SunOS 5.11
npm ERR! argv "/opt/local/bin/node" "/opt/local/bin/npm" "install" "cld"
npm ERR! node v0.12.0
npm ERR! npm v2.5.1
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the cld package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls cld
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
Could you please help me figure it out?
npm ERR! Windows_NT 6.3.9600
npm ERR! argv "E:\Programs\nodejs\node.exe" "E:\Programs\nodejs\node_modules\npm\bin\npm-cli.js" "install"
npm ERR! node v6.11.2
npm ERR! npm v3.10.10
npm ERR! code ELIFECYCLE
npm ERR! @paulcbetts/[email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @paulcbetts/[email protected] install script 'node-gyp rebuild'. npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the @paulcbetts/cld package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with: npm ERR! npm bugs @paulcbetts/cld
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls @paulcbetts/cld
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! E:\Documents\Electron projects\spellcheck examples\electron-spellchecker\npm-debug.log
Since 2.3.2 I get the following errors when installing cld (running windows 8.1 x64):
> [email protected] postinstall C:\tmp\node_modules\cld
> rm -r ./deps/ && find ./build -type f | grep -v 'cld.node' | xargs -I{} rm {}
'rm' is not recognized as an internal or external command,
operable program or batch file.
npm ERR! Windows_NT 6.3.9600
npm ERR! argv "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "cld"
npm ERR! node v0.12.0
npm ERR! npm v2.5.1
npm ERR! code ELIFECYCLE
npm ERR! [email protected] postinstall: `rm -r ./deps/ && find ./build -type f | grep -v 'cld.node' | xargs -I{} rm {}`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall script 'rm -r ./deps/ && find ./build -type f | grep -v 'cld.node' | xargs
-I{} rm {}'.
npm ERR! This is most likely a problem with the cld package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! rm -r ./deps/ && find ./build -type f | grep -v 'cld.node' | xargs -I{} rm {}
npm ERR! You can get their info via:
npm ERR! npm owner ls cld
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! C:\tmp\npm-debug.log
No problems installing [email protected] however
I am trying to detect the following sentence, it should result in Portuguese. Instead it results in 'Failed to identify language'.
beija-flor: laíla defende maior número de parcerias e critica altos gastos
Hi! I've discovered a couple of cases when a malformed languages array is returned (v2.4.5).
const cld = require('cld');
cld.detect('完整內容:http://tr.im/5hKu5', {}, (error, result) => console.log(result));
I receive the following output:
{ reliable: false,
textBytes: 30,
languages:
[ ,
{ name: 'ChineseT', code: 'zh-Hant', percent: 42, score: 2048 } ],
chunks: [] }
This behavior replicates on 不能小看 Nokia youtube.com 中天新聞 李雯珂: https://www.facebook.com/profile.php?id=1126389663&fref=ts 非凡新聞 范育禎
string, too.
Output:
{ reliable: false,
textBytes: 165,
languages:
[ ,
{ name: 'ChineseT', code: 'zh-Hant', percent: 34, score: 1805 } ],
chunks:
[ { name: 'ChineseT', code: 'zh-Hant', offset: 31, bytes: 24 },
{ name: 'ChineseT', code: 'zh-Hant', offset: 114, bytes: 24 } ] }
Hi ,
we are trying to use node-cld in cypress but got this error, is it possible to use this lib in browser
Error: Webpack Compilation Error
../.../node_modules/cld/index.js
Module not found: Error: Can't resolve './build/Release/cld' in '.../node_modules/cld'
I've tested on node 4.0.0, 4.1.0, 4.1.1
> [email protected] install /srv/tmp/builddir/node_modules/cld
> node-gyp rebuild
make: Entering directory `/srv/tmp/builddir/node_modules/cld/build'
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil_shared.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_hint_code.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_impl.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/debug.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/fixunicodevalue.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_entities.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_language.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_ulscript.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/getonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/lang_script.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/offsetmap.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/scoreonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/tote.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/utf8statetable.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_uni_prop_80.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_cjk_compatible.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_delta_bi_32.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_distinct_bi_0.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quad0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_deltaocta0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_deltaoctachrome.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_distinctocta0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_distinctoctachrome.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quadchrome_16.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quadchrome_2.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_2.o
AR(target) Release/obj.target/deps/cld/cld-c.a
COPY Release/cld-c.a
CXX(target) Release/obj.target/cld/src/constants.o
CXX(target) Release/obj.target/cld/src/cld.o
In file included from /srv/www/.node-gyp/4.1.1/include/node/node.h:42:0,
from ../node_modules/nan/nan.h:24,
from ../src/cld.cc:4:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:336:1: error: expected unqualified-id before 'using'
/srv/www/.node-gyp/4.1.1/include/node/v8.h:469:1: error: expected unqualified-id before 'using'
/srv/www/.node-gyp/4.1.1/include/node/v8.h:852:1: error: expected unqualified-id before 'using'
In file included from ../node_modules/nan/nan.h:182:0,
from ../src/cld.cc:4:
../node_modules/nan/nan_maybe_43_inl.h:13:1: error: expected unqualified-id before 'using'
../node_modules/nan/nan_maybe_43_inl.h:16:1: error: expected unqualified-id before 'using'
../node_modules/nan/nan_maybe_43_inl.h:19:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:24:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:31:1: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:36:1: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:41:1: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:46:1: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:51:1: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:60:1: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:65:12: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:70:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:77:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:84:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:92:12: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:99:1: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:109:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:115:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:119:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:126:1: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:131:1: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:136:1: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:140:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:146:12: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:151:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:157:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:163:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:169:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:175:12: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:181:12: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:187:12: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:195:12: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:202:1: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:206:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:210:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:214:12: error: 'Maybe' does not name a type
../node_modules/nan/nan_maybe_43_inl.h:218:12: error: 'MaybeLocal' does not name a type
In file included from ../node_modules/nan/nan.h:187:0,
from ../src/cld.cc:4:
../node_modules/nan/nan_converters.h:14:11: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_converters.h:16:56: error: 'Maybe' does not name a type
../node_modules/nan/nan_converters.h:26:1: error: 'return_t' does not name a type
../node_modules/nan/nan_converters.h:27:1: error: 'return_t' does not name a type
../node_modules/nan/nan_converters.h:28:1: error: 'return_t' does not name a type
../node_modules/nan/nan_converters.h:29:1: error: 'return_t' does not name a type
../node_modules/nan/nan_converters.h:30:1: error: 'return_t' does not name a type
../node_modules/nan/nan_converters.h:31:1: error: 'return_t' does not name a type
../node_modules/nan/nan_converters.h:32:1: error: 'return_t' does not name a type
../node_modules/nan/nan_converters.h:42:1: error: 'return_t' does not name a type
../node_modules/nan/nan_converters.h:43:1: error: 'return_t' does not name a type
../node_modules/nan/nan_converters.h:44:1: error: 'return_t' does not name a type
../node_modules/nan/nan_converters.h:45:1: error: 'return_t' does not name a type
../node_modules/nan/nan_converters.h:46:1: error: 'return_t' does not name a type
In file included from ../node_modules/nan/nan_converters.h:59:0,
from ../node_modules/nan/nan.h:187,
from ../src/cld.cc:4:
../node_modules/nan/nan_converters_43_inl.h:18:1: error: 'return_t' in 'struct Nan::imp::ToFactory<v8::Boolean>' does not name a type
../node_modules/nan/nan_converters_43_inl.h:19:1: error: 'return_t' in 'struct Nan::imp::ToFactory<v8::Number>' does not name a type
../node_modules/nan/nan_converters_43_inl.h:20:1: error: 'return_t' in 'struct Nan::imp::ToFactory<v8::String>' does not name a type
../node_modules/nan/nan_converters_43_inl.h:21:1: error: 'return_t' in 'struct Nan::imp::ToFactory<v8::Object>' does not name a type
../node_modules/nan/nan_converters_43_inl.h:22:1: error: 'return_t' in 'struct Nan::imp::ToFactory<v8::Integer>' does not name a type
../node_modules/nan/nan_converters_43_inl.h:23:1: error: 'return_t' in 'struct Nan::imp::ToFactory<v8::Uint32>' does not name a type
../node_modules/nan/nan_converters_43_inl.h:24:1: error: 'return_t' in 'struct Nan::imp::ToFactory<v8::Int32>' does not name a type
../node_modules/nan/nan_converters_43_inl.h:34:1: error: 'return_t' in 'struct Nan::imp::ToFactory<bool>' does not name a type
../node_modules/nan/nan_converters_43_inl.h:35:1: error: 'return_t' in 'struct Nan::imp::ToFactory<double>' does not name a type
../node_modules/nan/nan_converters_43_inl.h:36:1: error: 'return_t' in 'struct Nan::imp::ToFactory<long int>' does not name a type
../node_modules/nan/nan_converters_43_inl.h:37:1: error: 'return_t' in 'struct Nan::imp::ToFactory<unsigned int>' does not name a type
../node_modules/nan/nan_converters_43_inl.h:38:1: error: 'return_t' in 'struct Nan::imp::ToFactory<int>' does not name a type
In file included from ../node_modules/nan/nan.h:188:0,
from ../src/cld.cc:4:
../node_modules/nan/nan_new.h: In function 'v8::Local<T> Nan::imp::To(v8::Local<v8::Integer>) [with T = v8::Integer]':
../node_modules/nan/nan_new.h:21:32: error: no matching function for call to 'To(v8::Local<v8::Integer>&)'
../node_modules/nan/nan_new.h:21:32: note: candidate is:
../node_modules/nan/nan_converters.h:53:38: note: template<class T> typename Nan::imp::ToFactory::return_t Nan::To(v8::Local<v8::Value>)
../node_modules/nan/nan_new.h: In function 'v8::Local<T> Nan::imp::To(v8::Local<v8::Integer>) [with T = v8::Int32]':
../node_modules/nan/nan_new.h:28:30: error: no matching function for call to 'To(v8::Local<v8::Integer>&)'
../node_modules/nan/nan_new.h:28:30: note: candidate is:
../node_modules/nan/nan_converters.h:53:38: note: template<class T> typename Nan::imp::ToFactory::return_t Nan::To(v8::Local<v8::Value>)
../node_modules/nan/nan_new.h: In function 'v8::Local<T> Nan::imp::To(v8::Local<v8::Integer>) [with T = v8::Uint32]':
../node_modules/nan/nan_new.h:35:31: error: no matching function for call to 'To(v8::Local<v8::Integer>&)'
../node_modules/nan/nan_new.h:35:31: note: candidate is:
../node_modules/nan/nan_converters.h:53:38: note: template<class T> typename Nan::imp::ToFactory::return_t Nan::To(v8::Local<v8::Value>)
../node_modules/nan/nan_new.h: At global scope:
../node_modules/nan/nan_new.h:43:11: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan_new.h:75:17: error: 'return_t' does not name a type
../node_modules/nan/nan_new.h:141:17: error: 'return_t' does not name a type
../node_modules/nan/nan_new.h:147:17: error: 'return_t' does not name a type
../node_modules/nan/nan_new.h:148:17: error: 'return_t' does not name a type
../node_modules/nan/nan_new.h:160:17: error: 'return_t' does not name a type
../node_modules/nan/nan_new.h:161:17: error: 'return_t' does not name a type
../node_modules/nan/nan_new.h:162:17: error: 'return_t' does not name a type
../node_modules/nan/nan_new.h:163:17: error: 'return_t' does not name a type
../node_modules/nan/nan_new.h:165:17: error: 'return_t' does not name a type
../node_modules/nan/nan_new.h:166:17: error: 'return_t' does not name a type
../node_modules/nan/nan_new.h:182:17: error: 'return_t' does not name a type
../node_modules/nan/nan_new.h:183:17: error: 'return_t' does not name a type
In file included from ../node_modules/nan/nan_new.h:189:0,
from ../node_modules/nan/nan.h:188,
from ../src/cld.cc:4:
../node_modules/nan/nan_implementation_12_inl.h:56:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::Date>' does not name a type
../node_modules/nan/nan_implementation_12_inl.h: In static member function 'static Nan::imp::FactoryBase<v8::Function>::return_t Nan::imp::Factory<v8::Function>::New(Nan::FunctionCallback, v8::Local<v8::Value>)':
../node_modules/nan/nan_implementation_12_inl.h:90:46: error: 'NewInstance' was not declared in this scope
../node_modules/nan/nan_implementation_12_inl.h: In static member function 'static Nan::imp::FactoryBase<v8::FunctionTemplate>::return_t Nan::imp::Factory<v8::FunctionTemplate>::New(Nan::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>)':
../node_modules/nan/nan_implementation_12_inl.h:118:48: error: 'NewInstance' was not declared in this scope
../node_modules/nan/nan_implementation_12_inl.h: At global scope:
../node_modules/nan/nan_implementation_12_inl.h:197:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::RegExp>' does not name a type
../node_modules/nan/nan_implementation_12_inl.h:216:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::Script>' does not name a type
../node_modules/nan/nan_implementation_12_inl.h:222:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::Script>' does not name a type
../node_modules/nan/nan_implementation_12_inl.h:254:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::String>' does not name a type
../node_modules/nan/nan_implementation_12_inl.h:262:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::String>' does not name a type
../node_modules/nan/nan_implementation_12_inl.h:268:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::String>' does not name a type
../node_modules/nan/nan_implementation_12_inl.h:275:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::String>' does not name a type
../node_modules/nan/nan_implementation_12_inl.h:281:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::String>' does not name a type
../node_modules/nan/nan_implementation_12_inl.h:286:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::String>' does not name a type
../node_modules/nan/nan_implementation_12_inl.h:347:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::UnboundScript>' does not name a type
../node_modules/nan/nan_implementation_12_inl.h:354:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::UnboundScript>' does not name a type
In file included from ../node_modules/nan/nan.h:188:0,
from ../src/cld.cc:4:
../node_modules/nan/nan_new.h:291:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::String>' does not name a type
../node_modules/nan/nan_new.h:297:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::String>' does not name a type
../node_modules/nan/nan_new.h:303:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::String>' does not name a type
../node_modules/nan/nan_new.h:309:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::String>' does not name a type
../node_modules/nan/nan_new.h:315:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::String>' does not name a type
../node_modules/nan/nan_new.h:321:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::String>' does not name a type
../node_modules/nan/nan_new.h:327:1: error: 'return_t' in 'struct Nan::imp::Factory<v8::RegExp>' does not name a type
In file included from ../src/cld.cc:4:0:
../node_modules/nan/nan.h: In function 'v8::Local<v8::Value> Nan::Error(const char*)':
../node_modules/nan/nan.h:639:3: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In function 'void Nan::ThrowError(const char*)':
../node_modules/nan/nan.h:639:3: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In function 'v8::Local<v8::Value> Nan::RangeError(const char*)':
../node_modules/nan/nan.h:640:3: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In function 'void Nan::ThrowRangeError(const char*)':
../node_modules/nan/nan.h:640:3: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In function 'v8::Local<v8::Value> Nan::ReferenceError(const char*)':
../node_modules/nan/nan.h:641:3: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In function 'void Nan::ThrowReferenceError(const char*)':
../node_modules/nan/nan.h:641:3: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In function 'v8::Local<v8::Value> Nan::SyntaxError(const char*)':
../node_modules/nan/nan.h:642:3: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In function 'void Nan::ThrowSyntaxError(const char*)':
../node_modules/nan/nan.h:642:3: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In function 'v8::Local<v8::Value> Nan::TypeError(const char*)':
../node_modules/nan/nan.h:643:3: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In function 'void Nan::ThrowTypeError(const char*)':
../node_modules/nan/nan.h:643:3: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: At global scope:
../node_modules/nan/nan.h:651:14: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan.h:673:14: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan.h:689:14: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan.h:702:14: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan.h:719:14: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan.h:725:14: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan.h:733:14: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan.h:740:14: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan.h:746:14: error: 'MaybeLocal' does not name a type
../node_modules/nan/nan.h: In member function 'void Nan::Callback::SetFunction(const v8::Local<v8::Function>&)':
../node_modules/nan/nan.h:1366:40: error: 'Set' was not declared in this scope
../node_modules/nan/nan.h:1366:40: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../node_modules/nan/nan.h: In member function 'void Nan::AsyncWorker::SaveToPersistent(const char*, const v8::Local<v8::Value>&)':
../node_modules/nan/nan.h:1488:41: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In member function 'v8::Local<v8::Value> Nan::AsyncWorker::GetFromPersistent(const char*) const':
../node_modules/nan/nan.h:1506:45: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In member function 'virtual void Nan::AsyncWorker::HandleErrorCallback()':
../node_modules/nan/nan.h:1540:58: error: no matching function for call to 'New(const char*)'
../node_modules/nan/nan.h:1540:58: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../node_modules/nan/nan.h: In function 'void Nan::SetMethod(const T&, const char*, Nan::FunctionCallback)':
../node_modules/nan/nan.h:1829:16: error: there are no arguments to 'GetFunction' that depend on a template parameter, so a declaration of 'GetFunction' must be available [-fpermissive]
../node_modules/nan/nan.h:1829:16: note: (if you use '-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)
../node_modules/nan/nan.h:1830:45: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In function 'void Nan::SetPrototypeMethod(v8::Local<v8::FunctionTemplate>, const char*, Nan::FunctionCallback)':
../node_modules/nan/nan.h:1842:32: error: 'GetFunction' was not declared in this scope
../node_modules/nan/nan.h:1843:45: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In function 'void Nan::SetAccessor(v8::Local<v8::ObjectTemplate>, v8::Local<v8::String>, Nan::GetterCallback, Nan::SetterCallback, v8::Local<v8::Value>, v8::AccessControl, v8::PropertyAttribute, Nan::imp::Sig)':
../node_modules/nan/nan.h:1868:47: error: 'NewInstance' was not declared in this scope
../node_modules/nan/nan.h: In function 'bool Nan::SetAccessor(v8::Local<v8::Object>, v8::Local<v8::String>, Nan::GetterCallback, Nan::SetterCallback, v8::Local<v8::Value>, v8::AccessControl, v8::PropertyAttribute)':
../node_modules/nan/nan.h:1911:51: error: 'NewInstance' was not declared in this scope
../node_modules/nan/nan.h: In function 'void Nan::SetNamedPropertyHandler(v8::Local<v8::ObjectTemplate>, Nan::PropertyGetterCallback, Nan::PropertySetterCallback, Nan::PropertyQueryCallback, Nan::PropertyDeleterCallback, Nan::PropertyEnumeratorCallback, v8::Local<v8::Value>)':
../node_modules/nan/nan.h:1959:47: error: 'NewInstance' was not declared in this scope
../node_modules/nan/nan.h: In function 'void Nan::SetIndexedPropertyHandler(v8::Local<v8::ObjectTemplate>, Nan::IndexGetterCallback, Nan::IndexSetterCallback, Nan::IndexQueryCallback, Nan::IndexDeleterCallback, Nan::IndexEnumeratorCallback, v8::Local<v8::Value>)':
../node_modules/nan/nan.h:2029:47: error: 'NewInstance' was not declared in this scope
In file included from ../src/cld.cc:4:0:
../node_modules/nan/nan.h: In function 'void Nan::Export(Nan::ADDON_REGISTER_FUNCTION_ARGS_TYPE, const char*, Nan::FunctionCallback)':
../node_modules/nan/nan.h:2090:35: error: no matching function for call to 'New(const char*&)'
../node_modules/nan/nan.h:2090:35: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../node_modules/nan/nan.h:2091:47: error: 'GetFunction' was not declared in this scope
../node_modules/nan/nan.h:2091:65: error: 'Set' was not declared in this scope
../node_modules/nan/nan.h:2091:65: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../node_modules/nan/nan.h: In constructor 'Nan::Tap::Tap(v8::Local<v8::Value>)':
../node_modules/nan/nan.h:2098:30: error: no matching function for call to 'To(v8::Local<v8::Value>&)'
../node_modules/nan/nan.h:2098:30: note: candidate is:
../node_modules/nan/nan_converters.h:53:38: note: template<class T> typename Nan::imp::ToFactory::return_t Nan::To(v8::Local<v8::Value>)
../node_modules/nan/nan.h: In member function 'void Nan::Tap::ok(bool, const char*)':
../node_modules/nan/nan.h:2111:33: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../node_modules/nan/nan.h: In member function 'void Nan::Tap::pass(const char*)':
../node_modules/nan/nan.h:2117:30: error: 'Nan::imp::FactoryBase<v8::Boolean>::return_t' has no member named 'ToLocalChecked'
../src/cld.cc: In function 'Nan::NAN_METHOD_RETURN_TYPE NodeCld::Detect(Nan::NAN_METHOD_ARGS_TYPE)':
../src/cld.cc:70:7: error: 'Set' is not a member of 'Nan'
../src/cld.cc:70:7: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:70:49: error: no matching function for call to 'New(const char [5])'
../src/cld.cc:70:49: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:71:78: error: no matching function for call to 'New(const char*)'
../src/cld.cc:71:78: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:72:7: error: 'Set' is not a member of 'Nan'
../src/cld.cc:72:7: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:72:49: error: no matching function for call to 'New(const char [5])'
../src/cld.cc:72:49: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:73:78: error: no matching function for call to 'New(const char*)'
../src/cld.cc:73:78: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:74:7: error: 'Set' is not a member of 'Nan'
../src/cld.cc:74:7: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:74:52: error: no matching function for call to 'New(const char [8])'
../src/cld.cc:74:52: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:76:7: error: 'Set' is not a member of 'Nan'
../src/cld.cc:76:7: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:76:50: error: no matching function for call to 'New(const char [6])'
../src/cld.cc:76:50: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:79:7: error: 'Set' is not a member of 'Nan'
../src/cld.cc:79:7: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:93:7: error: 'Set' is not a member of 'Nan'
../src/cld.cc:93:7: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:93:49: error: no matching function for call to 'New(const char [5])'
../src/cld.cc:93:49: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:94:78: error: no matching function for call to 'New(const char*)'
../src/cld.cc:94:78: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:95:7: error: 'Set' is not a member of 'Nan'
../src/cld.cc:95:7: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:95:49: error: no matching function for call to 'New(const char [5])'
../src/cld.cc:95:49: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:96:78: error: no matching function for call to 'New(const char*)'
../src/cld.cc:96:78: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:97:7: error: 'Set' is not a member of 'Nan'
../src/cld.cc:97:7: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:97:51: error: no matching function for call to 'New(const char [7])'
../src/cld.cc:97:51: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:99:7: error: 'Set' is not a member of 'Nan'
../src/cld.cc:99:7: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:99:50: error: no matching function for call to 'New(const char [6])'
../src/cld.cc:99:50: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:102:7: error: 'Set' is not a member of 'Nan'
../src/cld.cc:102:7: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:106:5: error: 'Set' is not a member of 'Nan'
../src/cld.cc:106:5: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:106:54: error: no matching function for call to 'New(const char [9])'
../src/cld.cc:106:54: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:108:5: error: 'Set' is not a member of 'Nan'
../src/cld.cc:108:5: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:108:55: error: no matching function for call to 'New(const char [10])'
../src/cld.cc:108:55: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:110:5: error: 'Set' is not a member of 'Nan'
../src/cld.cc:110:5: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:110:55: error: no matching function for call to 'New(const char [10])'
../src/cld.cc:110:55: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc:112:5: error: 'Set' is not a member of 'Nan'
../src/cld.cc:112:5: note: suggested alternative:
/srv/www/.node-gyp/4.1.1/include/node/v8.h:3021:17: note: 'v8::Set'
../src/cld.cc:112:52: error: no matching function for call to 'New(const char [7])'
../src/cld.cc:112:52: note: candidates are:
../node_modules/nan/nan_implementation_12_inl.h:390:21: note: template<class T, class M> v8::Local<T> Nan::New(const v8::Persistent<S, M>&)
../node_modules/nan/nan_implementation_12_inl.h:395:21: note: template<class T, class M> v8::Local<T> Nan::New(const Nan::Persistent<T, M>&)
../node_modules/nan/nan_new.h:201:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New()
../node_modules/nan/nan_new.h:207:1: note: template<class T, class A0> typename Nan::imp::Factory<T>::return_t Nan::New(A0)
../node_modules/nan/nan_new.h:213:1: note: template<class T, class A0, class A1> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1)
../node_modules/nan/nan_new.h:219:1: note: template<class T, class A0, class A1, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2)
../node_modules/nan/nan_new.h:225:1: note: template<class T, class A0, class A1, class A2, class A3> typename Nan::imp::Factory<T>::return_t Nan::New(A0, A1, A2, A3)
../node_modules/nan/nan_new.h:237:1: note: template<class T> typename Nan::imp::Factory::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>)
../node_modules/nan/nan_new.h:245:1: note: template<class T, class A2> typename Nan::imp::Factory<T>::return_t Nan::New(Nan::FunctionCallback, v8::Local<v8::Value>, A2)
../src/cld.cc: At global scope:
../src/cld.cc:118:29: error: variable or field 'init' declared void
../src/cld.cc:118:25: error: 'Handle' is not a member of 'v8'
../src/cld.cc:118:46: error: expected primary-expression before '>' token
../src/cld.cc:118:48: error: 'target' was not declared in this scope
../src/cld.cc:153:1: error: expected '}' at end of input
make: *** [Release/obj.target/cld/src/cld.o] Error 1
make: Leaving directory `/srv/tmp/builddir/node_modules/cld/build'
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/srv/tmp/builddir/.paasprovider/node/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:270:23)
gyp ERR! stack at emitTwo (events.js:87:13)
gyp ERR! stack at ChildProcess.emit (events.js:172:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Linux 3.13.0-63-generic
gyp ERR! command "/srv/tmp/builddir/.paasprovider/node/bin/node" "/srv/tmp/builddir/.paasprovider/node/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /srv/tmp/builddir/node_modules/cld
gyp ERR! node -v v4.1.1
gyp ERR! node-gyp -v v3.0.3
gyp ERR! not ok
npm ERR! Linux 3.13.0-63-generic
npm ERR! argv "/srv/tmp/builddir/.paasprovider/node/bin/node" "/srv/tmp/builddir/.paasprovider/node/bin/npm" "install" "--unsafe-perm" "--userconfig" "/srv/tmp/builddir/.npmrc"
npm ERR! node v4.1.1
npm ERR! npm v2.14.4
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the cld package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls cld
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /srv/tmp/builddir/npm-debug.log
I have a simple script with two lines of code.
var cld = require('cld');
console.log('cld loaded');
Running the script from command line generates error like below. Any advice, please?
E:\Test>node app.js
module.js:423
return process.dlopen(module, path._makeLong(filename));
^
Error: The specified procedure could not be found.
\\?\E:\Test\node_modules\cld\build\Release\cld.node
at Error (native)
at Object.Module._extensions..node (module.js:423:18)
at Module.load (module.js:344:32)
at Function.Module._load (module.js:301:12)
at Module.require (module.js:354:17)
at require (internal/module.js:12:17)
at Object.<anonymous> (E:\Test\node_modules\cld\index.js:2:12)
at Module._compile (module.js:398:26)
at Object.Module._extensions..js (module.js:405:10)
at Module.load (module.js:344:32)
I can confirm that the file "E:\Test\node_modules\cld\build\Release\cld.node" is existing.
I'm unable to build or use [email protected] in [email protected] (Linux).
> [email protected] install /my_home/my_app/node_modules/cld
> node-gyp rebuild
make: Entering directory '/my_home/my_app/node_modules/cld/build'
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil_shared.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_hint_code.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_impl.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/debug.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/fixunicodevalue.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_entities.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_language.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_ulscript.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/getonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/lang_script.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/offsetmap.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/scoreonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/tote.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/utf8statetable.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_uni_prop_80.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_cjk_compatible.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_delta_bi_32.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_distinct_bi_0.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quad0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_deltaocta0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_deltaoctachrome.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_distinctocta0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_distinctoctachrome.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quadchrome_16.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quadchrome_2.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_2.o
AR(target) Release/obj.target/deps/cld/cld-c.a
COPY Release/cld-c.a
CXX(target) Release/obj.target/cld/src/constants.o
CXX(target) Release/obj.target/cld/src/cld.o
../src/cld.cc: In function ‘Nan::NAN_METHOD_RETURN_TYPE NodeCld::Detect(Nan::NAN_METHOD_ARGS_TYPE)’:
../src/cld.cc:14:104: error: no matching function for call to ‘v8::String::Utf8Value::Utf8Value(v8::Isolate*, v8::Local<v8::String>)’
v8::String::Utf8Value text(v8::Isolate::GetCurrent(), Nan::To<v8::String>(info[0]).ToLocalChecked());
^
In file included from /my_home/.node-gyp/6.9.5/include/node/node.h:42:0,
from ../../nan/nan.h:54,
from ../src/cld.cc:8:
/my_home/.node-gyp/6.9.5/include/node/v8.h:2438:5: note: candidate: v8::String::Utf8Value::Utf8Value(const v8::String::Utf8Value&)
Utf8Value(const Utf8Value&);
^~~~~~~~~
/my_home/.node-gyp/6.9.5/include/node/v8.h:2438:5: note: candidate expects 1 argument, 2 provided
/my_home/.node-gyp/6.9.5/include/node/v8.h:2428:14: note: candidate: v8::String::Utf8Value::Utf8Value(v8::Local<v8::Value>)
explicit Utf8Value(Local<v8::Value> obj);
^~~~~~~~~
/my_home/.node-gyp/6.9.5/include/node/v8.h:2428:14: note: candidate expects 1 argument, 2 provided
../src/cld.cc:26:112: error: no matching function for call to ‘v8::String::Utf8Value::Utf8Value(v8::Isolate*, v8::Local<v8::String>)’
v8::String::Utf8Value languageHint(v8::Isolate::GetCurrent(), Nan::To<v8::String>(info[2]).ToLocalChecked());
^
In file included from /my_home/.node-gyp/6.9.5/include/node/node.h:42:0,
from ../../nan/nan.h:54,
from ../src/cld.cc:8:
/my_home/.node-gyp/6.9.5/include/node/v8.h:2438:5: note: candidate: v8::String::Utf8Value::Utf8Value(const v8::String::Utf8Value&)
Utf8Value(const Utf8Value&);
^~~~~~~~~
/my_home/.node-gyp/6.9.5/include/node/v8.h:2438:5: note: candidate expects 1 argument, 2 provided
/my_home/.node-gyp/6.9.5/include/node/v8.h:2428:14: note: candidate: v8::String::Utf8Value::Utf8Value(v8::Local<v8::Value>)
explicit Utf8Value(Local<v8::Value> obj);
^~~~~~~~~
/my_home/.node-gyp/6.9.5/include/node/v8.h:2428:14: note: candidate expects 1 argument, 2 provided
../src/cld.cc:27:112: error: no matching function for call to ‘v8::String::Utf8Value::Utf8Value(v8::Isolate*, v8::Local<v8::String>)’
v8::String::Utf8Value encodingHint(v8::Isolate::GetCurrent(), Nan::To<v8::String>(info[3]).ToLocalChecked());
^
In file included from /my_home/.node-gyp/6.9.5/include/node/node.h:42:0,
from ../../nan/nan.h:54,
from ../src/cld.cc:8:
/my_home/.node-gyp/6.9.5/include/node/v8.h:2438:5: note: candidate: v8::String::Utf8Value::Utf8Value(const v8::String::Utf8Value&)
Utf8Value(const Utf8Value&);
^~~~~~~~~
/my_home/.node-gyp/6.9.5/include/node/v8.h:2438:5: note: candidate expects 1 argument, 2 provided
/my_home/.node-gyp/6.9.5/include/node/v8.h:2428:14: note: candidate: v8::String::Utf8Value::Utf8Value(v8::Local<v8::Value>)
explicit Utf8Value(Local<v8::Value> obj);
^~~~~~~~~
/my_home/.node-gyp/6.9.5/include/node/v8.h:2428:14: note: candidate expects 1 argument, 2 provided
../src/cld.cc:28:107: error: no matching function for call to ‘v8::String::Utf8Value::Utf8Value(v8::Isolate*, v8::Local<v8::String>)’
v8::String::Utf8Value tldHint(v8::Isolate::GetCurrent(), Nan::To<v8::String>(info[4]).ToLocalChecked());
^
In file included from /my_home/.node-gyp/6.9.5/include/node/node.h:42:0,
from ../../nan/nan.h:54,
from ../src/cld.cc:8:
/my_home/.node-gyp/6.9.5/include/node/v8.h:2438:5: note: candidate: v8::String::Utf8Value::Utf8Value(const v8::String::Utf8Value&)
Utf8Value(const Utf8Value&);
^~~~~~~~~
/my_home/.node-gyp/6.9.5/include/node/v8.h:2438:5: note: candidate expects 1 argument, 2 provided
/my_home/.node-gyp/6.9.5/include/node/v8.h:2428:14: note: candidate: v8::String::Utf8Value::Utf8Value(v8::Local<v8::Value>)
explicit Utf8Value(Local<v8::Value> obj);
^~~~~~~~~
/my_home/.node-gyp/6.9.5/include/node/v8.h:2428:14: note: candidate expects 1 argument, 2 provided
../src/cld.cc:29:108: error: no matching function for call to ‘v8::String::Utf8Value::Utf8Value(v8::Isolate*, v8::Local<v8::String>)’
v8::String::Utf8Value httpHint(v8::Isolate::GetCurrent(), Nan::To<v8::String>(info[5]).ToLocalChecked());
^
In file included from /my_home/.node-gyp/6.9.5/include/node/node.h:42:0,
from ../../nan/nan.h:54,
from ../src/cld.cc:8:
/my_home/.node-gyp/6.9.5/include/node/v8.h:2438:5: note: candidate: v8::String::Utf8Value::Utf8Value(const v8::String::Utf8Value&)
Utf8Value(const Utf8Value&);
^~~~~~~~~
/my_home/.node-gyp/6.9.5/include/node/v8.h:2438:5: note: candidate expects 1 argument, 2 provided
/my_home/.node-gyp/6.9.5/include/node/v8.h:2428:14: note: candidate: v8::String::Utf8Value::Utf8Value(v8::Local<v8::Value>)
explicit Utf8Value(Local<v8::Value> obj);
^~~~~~~~~
/my_home/.node-gyp/6.9.5/include/node/v8.h:2428:14: note: candidate expects 1 argument, 2 provided
cld.target.mk:102: recipe for target 'Release/obj.target/cld/src/cld.o' failed
make: *** [Release/obj.target/cld/src/cld.o] Error 1
make: Leaving directory '/my_home/my_app/node_modules/cld/build'
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/nvm/versions/node/v6.9.5/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:276:23)
gyp ERR! stack at emitTwo (events.js:106:13)
gyp ERR! stack at ChildProcess.emit (events.js:191:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)
gyp ERR! System Linux 3.14.44-32.39.amzn1.x86_64
gyp ERR! command "/usr/local/nvm/versions/node/v6.9.5/bin/node" "/usr/local/nvm/versions/node/v6.9.5/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /my_home/my_app/node_modules/cld
gyp ERR! node -v v6.9.5
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok
At this moment I am unable to upgrade to the latest lts/boron and confirm there too.
#53 looks like worth looking at. I wish I could help further.
Question: although [email protected] is End-Of-Life, ad91d3 suggests you are expecting to support it. Is this assumption correct?
I run unit test on node-cld, and it not pass.
throw new assert.AssertionError({ ^ AssertionError: { message: 'Failed to identify language' } == null at D:\Projects\cld\test\runner.js:12:14 at Object.module.exports.detect (D:\Projects\cld\index.js:71:14) at D:\Projects\cld\test\runner.js:11:9 at Function._.each._.forEach (D:\projects\cld\node_modules\underscore\underscore.js:153:9) at runCoreTests (D:\Projects\cld\test\runner.js:10:5) at Objects. (D:\Projects\cld\test\runner.js:135:1) at Module._compile (module.js:434:26) at Object.Module._extensions..js (module.js:452:10) at Module.load (module.js:355:32) at Function.Module._load (module.js:310:12) npm ERR! Test failed. see above for more details.
I try some languages and it can't detect although it has in data in the unit test.
{ message: 'Failed to identify language'}
Some languages you can try: SOMALI, IGBO, HAUSA, ABKHAZIAN, AFAR, ...
Does node-cld support languages as cld2 ?
Using underscore in the latest version makes this is more bloated while this is not needed
I know that short snippets are likely to fail the language detection, but I found it confusing that the snippet
Best practices
was detected as en
on windows, but failed on linux with the error message Failed to identify language
. Do you have any idea why the cld2 behaviour is not consistent across platforms?
When I run
require('cld').detect('That man is the richest whose pleasure are the cheapest. 能处处寻求快乐的人才是最富有的人。— 梭罗', function(err, result) { console.log(result); });
It returns
{ reliable: true,
textBytes: 114,
languages:
[ { name: 'ENGLISH', code: 'en', percent: 49, score: 1517 },
{ name: 'Chinese', code: 'zh', percent: 49, score: 2066 } ],
chunks:
[ { name: 'ENGLISH', code: 'en', offset: 0, bytes: 57 },
{ name: 'Chinese', code: 'zh', offset: 57, bytes: 61 } ] }
What does this mean? Wich language is more present? English or Chinese? And what does the score mean? Is there a way to normalize the score to a 0 to 100 scale?
Getting error Error: Module version mismatch. Expected 11, got 1.
Installed it from NPM, version 0.0.6. Node v0.10.8, npm 1.2.23.
Our build process requires native node_modules to export pdb files so that we can ship them to our crash reporting server. I'm having an annoying issue with the interaction of yarn / npm and this particular package.
Basically, we use yarn as our package manager, and yarn still does not offer a real equivalent to npm rebuild
. Unfortunately, npm rebuild
always rebuilds with scripts, and the postinstall script on this package deletes all build related resources except the .node
file. A potential workaround is npm i --ignore-scripts --build-from-source=@paulcbetts/cld @paulcbetts/cld
, but this takes major issue with however yarn has laid out the node_modules folder and causes errors.
It would be radical if we could just let the pdb files through the postinstall script.
Considering this library to detect web page language i noticed that the Hebrew code is using the old code 'iw' instead of 'he'.
I forked to change it, but got the impression that this is an auto generated definition.
Can this language code be re-generated using the latest code standard?
The README says:
Once the module has been installed, the underlying C source will remain in the deps/cld folder and continue to occupy considerable space. If you are under severe constraints you can delete this folder and reclam >100M
Why can't that directory be removed with postinstall script?
Although this package builds just fine on first install, running npm rebuild
results in an error because deps
has been deleted in the post-install step.
kylehardgrave@ObvsMBP65:test $ npm rebuild
> [email protected] install /Users/kylehardgrave/test/node_modules/cld
> node-gyp rebuild
gyp: deps/cld/binding.gyp not found (cwd: /Users/kylehardgrave/test/node_modules/cld) while loading dependencies of binding.gyp while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit (/opt/boxen/nodenv/versions/v0.12.2/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:343:16)
gyp ERR! stack at ChildProcess.emit (events.js:110:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:1074:12)
gyp ERR! System Darwin 14.3.0
gyp ERR! command "node" "/opt/boxen/nodenv/versions/v0.12.2/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/kylehardgrave/test/node_modules/cld
gyp ERR! node -v v0.12.2
gyp ERR! node-gyp -v v1.0.3
gyp ERR! not ok
Note this is on Node v0.12.2, OS X Yosemite 10.10.3, cld v2.4.3.
Full npm-debug.log
below:
0 info it worked if it ends with ok
1 verbose cli [ 'node',
1 verbose cli '/opt/boxen/nodenv/versions/v0.12.2/bin/npm',
1 verbose cli 'rebuild' ]
2 info using [email protected]
3 info using [email protected]
4 info readInstalled object
5 verbose rebuild path, id [ '/Users/kylehardgrave/test', '[email protected]' ]
6 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld', '[email protected]' ]
7 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob',
7 verbose rebuild '[email protected]' ]
8 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/inflight',
8 verbose rebuild '[email protected]' ]
9 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/once',
9 verbose rebuild '[email protected]' ]
10 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/once/node_modules/wrappy',
10 verbose rebuild '[email protected]' ]
11 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/inflight/node_modules/wrappy',
11 verbose rebuild '[email protected]' ]
12 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/inherits',
12 verbose rebuild '[email protected]' ]
13 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/minimatch',
13 verbose rebuild '[email protected]' ]
14 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/minimatch/node_modules/brace-expansion',
14 verbose rebuild '[email protected]' ]
15 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/minimatch/node_modules/brace-expansion/node_modules/balanced-match',
15 verbose rebuild '[email protected]' ]
16 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/minimatch/node_modules/brace-expansion/node_modules/concat-map',
16 verbose rebuild '[email protected]' ]
17 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/path-is-absolute',
17 verbose rebuild '[email protected]' ]
18 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/nan',
18 verbose rebuild '[email protected]' ]
19 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf',
19 verbose rebuild '[email protected]' ]
20 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob',
20 verbose rebuild '[email protected]' ]
21 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/inflight',
21 verbose rebuild '[email protected]' ]
22 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/once',
22 verbose rebuild '[email protected]' ]
23 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/once/node_modules/wrappy',
23 verbose rebuild '[email protected]' ]
24 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/inflight/node_modules/wrappy',
24 verbose rebuild '[email protected]' ]
25 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/inherits',
25 verbose rebuild '[email protected]' ]
26 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/minimatch',
26 verbose rebuild '[email protected]' ]
27 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/minimatch/node_modules/brace-expansion',
27 verbose rebuild '[email protected]' ]
28 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/minimatch/node_modules/brace-expansion/node_modules/balanced-match',
28 verbose rebuild '[email protected]' ]
29 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/minimatch/node_modules/brace-expansion/node_modules/concat-map',
29 verbose rebuild '[email protected]' ]
30 verbose rebuild path, id [ '/Users/kylehardgrave/test/node_modules/cld/node_modules/underscore',
30 verbose rebuild '[email protected]' ]
31 silly rebuild set [ '/Users/kylehardgrave/test/node_modules/cld',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/inflight',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/once',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/once/node_modules/wrappy',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/inflight/node_modules/wrappy',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/inherits',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/minimatch',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/minimatch/node_modules/brace-expansion',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/minimatch/node_modules/brace-expansion/node_modules/balanced-match',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/minimatch/node_modules/brace-expansion/node_modules/concat-map',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/glob/node_modules/path-is-absolute',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/nan',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/inflight',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/once',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/once/node_modules/wrappy',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/inflight/node_modules/wrappy',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/inherits',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/minimatch',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/minimatch/node_modules/brace-expansion',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/minimatch/node_modules/brace-expansion/node_modules/balanced-match',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/rimraf/node_modules/glob/node_modules/minimatch/node_modules/brace-expansion/node_modules/concat-map',
31 silly rebuild set '/Users/kylehardgrave/test/node_modules/cld/node_modules/underscore' ]
32 info build /Users/kylehardgrave/test/node_modules/cld
33 info preinstall [email protected]
34 info linkStuff [email protected]
35 silly linkStuff [email protected] has /Users/kylehardgrave/test/node_modules as its parent node_modules
36 verbose linkBins [email protected]
37 verbose linkMans [email protected]
38 verbose rebuildBundles [email protected]
39 verbose rebuildBundles [ '.bin', 'glob', 'nan', 'rimraf', 'underscore' ]
40 info install [email protected]
41 verbose unsafe-perm in lifecycle true
42 info [email protected] Failed to exec install script
43 verbose stack Error: [email protected] install: `node-gyp rebuild`
43 verbose stack Exit status 1
43 verbose stack at EventEmitter.<anonymous> (/opt/boxen/nodenv/versions/v0.12.2/lib/node_modules/npm/lib/utils/lifecycle.js:213:16)
43 verbose stack at EventEmitter.emit (events.js:110:17)
43 verbose stack at ChildProcess.<anonymous> (/opt/boxen/nodenv/versions/v0.12.2/lib/node_modules/npm/lib/utils/spawn.js:14:12)
43 verbose stack at ChildProcess.emit (events.js:110:17)
43 verbose stack at maybeClose (child_process.js:1015:16)
43 verbose stack at Process.ChildProcess._handle.onexit (child_process.js:1087:5)
44 verbose pkgid [email protected]
45 verbose cwd /Users/kylehardgrave/test
46 error Darwin 14.3.0
47 error argv "node" "/opt/boxen/nodenv/versions/v0.12.2/bin/npm" "rebuild"
48 error node v0.12.2
49 error npm v2.7.6
50 error code ELIFECYCLE
51 error [email protected] install: `node-gyp rebuild`
51 error Exit status 1
52 error Failed at the [email protected] install script 'node-gyp rebuild'.
52 error This is most likely a problem with the cld package,
52 error not with npm itself.
52 error Tell the author that this fails on your system:
52 error node-gyp rebuild
52 error You can get their info via:
52 error npm owner ls cld
52 error There is likely additional logging output above.
53 verbose exit [ 1, true ]
Hi, I think I found a case where a malformed chunks array is returned.
var string = 'Das ist ein Test おねがいします';
cld.detect(string, function(err, result) {
console.log(result);
});
This returns:
{ reliable: true,
textBytes: 41,
languages:
[ { name: 'Japanese', code: 'ja', percent: 53, score: 3956 },
{ name: 'GERMAN', code: 'de', percent: 42, score: 1445 } ],
chunks: [ , { name: 'Japanese', code: 'ja', offset: 17, bytes: 21 } ] }
Great module btw!
This is my own creation. If there is no official position, I will post it myself.
interface Language {
readonly name: string;
readonly code: string;
readonly percent: number;
readonly score: number;
}
interface Chunk {
readonly name: string;
readonly code: string;
readonly offset: number;
readonly bytes: number;
}
interface Options {
readonly isHTML: false;
readonly languageHint: string;
readonly encodingHint: string;
readonly tldHint: string;
readonly httpHint: string;
}
interface DetectLanguage {
readonly reliable: boolean;
readonly textBytes: number;
readonly languages: Language[];
readonly chunks: Chunk[];
}
export declare module 'cld' {
declare function detect(text: string, options: Options, callback: (err: string, result: DetectLanguage) => {});
declare function detect(text: string, callback: (err: string, result: DetectLanguage) => {});
}
UPDATE: Looks like it was a RAM issue - I bumped my Ubuntu server from 512MB to 2G RAM and this seems to have solved it.
This library appears to be a dependency baked deeply into keystonejs (via limax) - so you might have some requests coming. I confirmed that I have node-gyp, build-essentials, make, and python installed.
Distributor ID: Ubuntu
Description: Ubuntu 14.04.1 LTS
Release: 14.04
Codename: trusty
Error occurs as follows:
$ npm install cld --save
-
> [email protected] install /home/ubuntu/workspace/MYPROJECT/node_modules/cld
> node-gyp rebuild
make: Entering directory `/home/ubuntu/workspace/MYPROJECT/node_modules/cld/build'
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil_shared.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_hint_code.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_impl.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/debug.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/fixunicodevalue.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_entities.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_language.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_ulscript.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/getonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/lang_script.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/offsetmap.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/scoreonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/tote.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/utf8statetable.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_uni_prop_80.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_cjk_compatible.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_delta_bi_32.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_distinct_bi_0.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quad0122.o
g++: internal compiler error: Killed (program cc1plus)
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-4.8/README.Bugs> for instructions.
make: *** [Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quad0122.o] Error 4
make: Leaving directory `/home/ubuntu/workspace/MYPROJECT/node_modules/cld/build'
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/home/ubuntu/.nvm/v0.10.35/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:267:23)
gyp ERR! stack at ChildProcess.emit (events.js:98:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:820:12)
gyp ERR! System Linux 3.14.13-c9
gyp ERR! command "node" "/home/ubuntu/.nvm/v0.10.35/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/ubuntu/workspace/MYPROJECT/node_modules/cld
gyp ERR! node -v v0.10.35
gyp ERR! node-gyp -v v1.0.1
gyp ERR! not ok
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is most likely a problem with the cld package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls cld
npm ERR! There is likely additional logging output above.
npm ERR! System Linux 3.14.13-c9
npm ERR! command "/home/ubuntu/.nvm/v0.10.35/bin/node" "/home/ubuntu/.nvm/v0.10.35/bin/npm" "install" "cld" "--save"
npm ERR! cwd /home/ubuntu/workspace/MYPROJECT
npm ERR! node -v v0.10.35
npm ERR! npm -v 1.4.28
npm ERR! code ELIFECYCLE
npm ERR! not ok code 0
An internal function of CLD2, int GetLangScore(uint32 probs, uint8 pslang) let you get the score of a language by language probability.
This is used in several points to calculate the score of a language, given the top 3 languages predicted like here:
if (indirect < static_cast<int>(obj->kCLDTableSizeOne)) {
// Up to three languages at indirect
uint32 langprob = obj->kCLDTableInd[indirect];
return GetLangScore(langprob, lang1) - GetLangScore(langprob, lang2);
}
I would like to get the opposite, hence to get the probabilities for each language, referred in the code as langprob
.
There are some internal testing function like string GetLangProbTxt(const ScoringContext* scoringcontext, uint32 langprob)
that seems to print out these probabilities here, so in theory it should be easier as
uint32 langprob = base_obj->kCLDTableInd[indirect];
retval.append(GetLangProbTxt(scoringcontext, langprob));
Hi,
I successfully installed the module with 0.4.2 node's version but with the 0.6.2 and the 0.6.4 the installation failed :
Build failed: -> task failed (err #1):
{task: cxx_link cld_1.o,cldutil_1.o,cldutil_dbg_empty_1.o,compact_lang_det_1.o,compact_lang_det_impl_1.o,ext_lang_enc_1.o,getonescriptspan_1.o,letterscript_enum_1.o,tote_1.o,cld_generated_score_quadchrome_0406_1.o,compact_lang_det_generated_cjkbis_0_1.o,compact_lang_det_generated_ctjkvz_1.o,compact_lang_det_generated_deltaoctachrome_1.o,compact_lang_det_generated_quadschrome_1.o,cld_htmlutils_windows_1.o,cld_unilib_windows_1.o,cld_utf8statetable_1.o,cld_utf8utils_windows_1.o,encodings_1.o,languages_1.o -> cld.node}
make: *** [compile] Erreur 1
npm ERR! error installing [email protected]
npm i cld
gyp ERR! stack Error: 404 status code downloading tarball
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm v2.0.1
node v2.0.2 (iojs)
Ubuntu 14.04.1
First I thought that was iojs, but I try to install into another environment with node v2.0.0 and it works like a charm.
Pastebin with the npm-debug.log:
http://pastebin.com/xrKPsR6k
Any idea?
Thanks
I downgrade by using nvm
to 2.0.0 and works like a charm. So I guess is that cld isn't compatible with 2.0.2, could be?
npm install cld
gets a bunch of warnings and here's the part where it fails:
cld_generated_score_quad_octa_0122.obj : warning LNK4006: "short const * const CLD2::kAvgDeltaOctaScore" (?kAvgDeltaOctaScore@CLD2@@3QBFB) already defined in cld_generated_score_quad_octa_2.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\deps\cld\cld-c .vcxproj]
cld_generated_score_quad_octa_0122.obj : warning LNK4006: "int const CLD2::kAvgDeltaOctaScoreSize" (?kAvgDeltaOctaScoreSize@CLD2@@3HB) already defined in cld_generated_score_quad_octa_2.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\deps\cld\cld-c.vcx proj]
cld2_generated_quadchrome_16.obj : warning LNK4006: "struct CLD2::CLD2TableSummary const CLD2::kQuad_obj" (?kQuad_obj@CLD2@@3UCLD2TableSummary@1@B) already defined in cld2_generated_quadchrome_2.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\deps\cld\ cld-c.vcxproj]
cld2_generated_quadchrome_16.obj : warning LNK4006: "struct CLD2::CLD2TableSummary const CLD2::kQuad_obj2" (?kQuad_obj2@CLD2@@3UCLD2TableSummary@1@B) already defined in cld2_generated_quadchrome_2.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\deps\cl d\cld-c.vcxproj]
cld2_generated_distinctocta0122.obj : warning LNK4006: "struct CLD2::CLD2TableSummary const CLD2::kDistinctOcta_obj2" (?kDistinctOcta_obj2@CLD2@@3UCLD2TableSummary@1@B) already defined in cld2_generated_distinctoctachrome.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_ modules\cld\build\deps\cld\cld-c.vcxproj]
cld2_generated_distinctocta0122.obj : warning LNK4006: "unsigned int const CLD2::kDistinctOcta2IndSize" (?kDistinctOcta2IndSize@CLD2@@3IB) already defined in cld2_generated_distinctoctachrome.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\deps\cld\cld -c.vcxproj]
cld2_generated_distinctocta0122.obj : warning LNK4006: "unsigned int const CLD2::kDistinctOctaIndSize" (?kDistinctOctaIndSize@CLD2@@3IB) already defined in cld2_generated_distinctoctachrome.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\deps\cld\cld-c .vcxproj]
cld2_generated_distinctocta0122.obj : warning LNK4006: "struct CLD2::CLD2TableSummary const CLD2::kDistinctOcta_obj" (?kDistinctOcta_obj@CLD2@@3UCLD2TableSummary@1@B) already defined in cld2_generated_distinctoctachrome.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_mo dules\cld\build\deps\cld\cld-c.vcxproj]
cld2_generated_deltaocta0122.obj : warning LNK4006: "struct CLD2::CLD2TableSummary const CLD2::kDeltaOcta_obj2" (?kDeltaOcta_obj2@CLD2@@3UCLD2TableSummary@1@B) already defined in cld2_generated_deltaoctachrome.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_modules\cld\ build\deps\cld\cld-c.vcxproj]
cld2_generated_deltaocta0122.obj : warning LNK4006: "unsigned int const CLD2::kDeltaOcta2IndSize" (?kDeltaOcta2IndSize@CLD2@@3IB) already defined in cld2_generated_deltaoctachrome.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\deps\cld\cld-c.vcxproj]
cld2_generated_deltaocta0122.obj : warning LNK4006: "struct CLD2::CLD2TableSummary const CLD2::kDeltaOcta_obj" (?kDeltaOcta_obj@CLD2@@3UCLD2TableSummary@1@B) already defined in cld2_generated_deltaoctachrome.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_modules\cld\bu ild\deps\cld\cld-c.vcxproj]
cld2_generated_deltaocta0122.obj : warning LNK4006: "unsigned int const CLD2::kDeltaOctaIndSize" (?kDeltaOctaIndSize@CLD2@@3IB) already defined in cld2_generated_deltaoctachrome.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\deps\cld\cld-c.vcxproj]
cld2_generated_quad0122.obj : warning LNK4006: "struct CLD2::CLD2TableSummary const CLD2::kQuad_obj" (?kQuad_obj@CLD2@@3UCLD2TableSummary@1@B) already defined in cld2_generated_quadchrome_2.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\deps\cld\cld-c .vcxproj]
cld2_generated_quad0122.obj : warning LNK4006: "struct CLD2::CLD2TableSummary const CLD2::kQuad_obj2" (?kQuad_obj2@CLD2@@3UCLD2TableSummary@1@B) already defined in cld2_generated_quadchrome_2.obj; second definition ignored [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\deps\cld\cld -c.vcxproj]
cld-c.vcxproj -> C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\Release\\cld-c.lib
constants.cc
cld.cc
win_delay_load_hook.cc
C:\Program Files (x86)\Windows Kits\10\Include\10.0.10240.0\ucrt\corecrt_terminate.h(33): error C2872: 'terminate_handler': ambiguous symbol (compiling source file ..\src\cld.cc) [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\cld.vcxproj]
C:\Program Files (x86)\Windows Kits\10\Include\10.0.10240.0\ucrt\corecrt_terminate.h(18): note: could be 'void (__cdecl *__cdecl terminate_handler)(void)' (compiling source file ..\src\cld.cc)
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\exception(192): note: or 'std::terminate_handler' (compiling source file ..\src\cld.cc)
C:\Program Files (x86)\Windows Kits\10\Include\10.0.10240.0\ucrt\corecrt_terminate.h(34): error C2872: 'terminate_handler': ambiguous symbol (compiling source file ..\src\cld.cc) [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\cld.vcxproj]
C:\Program Files (x86)\Windows Kits\10\Include\10.0.10240.0\ucrt\corecrt_terminate.h(18): note: could be 'void (__cdecl *__cdecl terminate_handler)(void)' (compiling source file ..\src\cld.cc)
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\exception(192): note: or 'std::terminate_handler' (compiling source file ..\src\cld.cc)
C:\Program Files (x86)\Windows Kits\10\Include\10.0.10240.0\ucrt\corecrt_terminate.h(37): error C2872: 'terminate_handler': ambiguous symbol (compiling source file ..\src\cld.cc) [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\cld.vcxproj]
C:\Program Files (x86)\Windows Kits\10\Include\10.0.10240.0\ucrt\corecrt_terminate.h(18): note: could be 'void (__cdecl *__cdecl terminate_handler)(void)' (compiling source file ..\src\cld.cc)
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\exception(192): note: or 'std::terminate_handler' (compiling source file ..\src\cld.cc)
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\eh.h(35): error C2872: 'unexpected_handler': ambiguous symbol (compiling source file ..\src\cld.cc) [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\cld.vcxproj]
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\eh.h(19): note: could be 'void (__cdecl *__cdecl unexpected_handler)(void)' (compiling source file ..\src\cld.cc)
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\exception(193): note: or 'std::unexpected_handler' (compiling source file ..\src\cld.cc)
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\eh.h(36): error C2872: 'unexpected_handler': ambiguous symbol (compiling source file ..\src\cld.cc) [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\cld.vcxproj]
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\eh.h(19): note: could be 'void (__cdecl *__cdecl unexpected_handler)(void)' (compiling source file ..\src\cld.cc)
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\exception(193): note: or 'std::unexpected_handler' (compiling source file ..\src\cld.cc)
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\eh.h(39): error C2872: 'unexpected_handler': ambiguous symbol (compiling source file ..\src\cld.cc) [C:\Users\homer\Documents\Learning\cld\node_modules\cld\build\cld.vcxproj]
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\eh.h(19): note: could be 'void (__cdecl *__cdecl unexpected_handler)(void)' (compiling source file ..\src\cld.cc)
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\exception(193): note: or 'std::unexpected_handler' (compiling source file ..\src\cld.cc)
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:276:23)
gyp ERR! stack at emitTwo (events.js:87:13)
gyp ERR! stack at ChildProcess.emit (events.js:172:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Windows_NT 6.3.9600
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\Users\homer\Documents\Learning\cld\node_modules\cld
gyp ERR! node -v v4.4.2
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok
npm ERR! Windows_NT 6.3.9600
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "cld"
npm ERR! node v4.4.2
npm ERR! npm v2.15.0
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the cld package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs cld
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!
npm ERR! npm owner ls cld
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! C:\Users\homer\Documents\Learning\cld\npm-debug.log
I just found this module. Looks great so far! But I also noticed that the CLD packaged is from 2011. I researched and found that 2013 version cld2 was release.
Would it be possible to get this working with the new version?
Hi, I am having an issue when installing the library in my dockerized Linux image.
`
[email protected] install /var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/cld
node-gyp rebuild
gyp WARN EACCES user "undefined" does not have permission to access the dev dir "/.node-gyp/9.11.2"
gyp WARN EACCES attempting to reinstall using temporary dev dir "/tmp/.node-gyp"
make: Entering directory '/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/cld/build'
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil_shared.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_hint_code.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_impl.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/debug.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/fixunicodevalue.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_entities.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_language.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_ulscript.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/getonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/lang_script.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/offsetmap.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/scoreonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/tote.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/utf8statetable.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_uni_prop_80.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_cjk_compatible.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_delta_bi_32.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_distinct_bi_0.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quad0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_deltaocta0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_deltaoctachrome.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_distinctocta0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_distinctoctachrome.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quadchrome_16.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quadchrome_2.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_2.o
AR(target) Release/obj.target/deps/cld/cld-c.a
COPY Release/cld-c.a
CXX(target) Release/obj.target/cld/src/constants.o
CXX(target) Release/obj.target/cld/src/cld.o
In file included from ../src/cld.cc:12:0:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi.h:2173:49: error: expected ‘)’ before ‘tsFunctionValue’
ThreadSafeFunction(napi_threadsafe_function tsFunctionValue);
^~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi.h:2175:14: error: expected type-specifier before ‘napi_threadsafe_function’
operator napi_threadsafe_function() const;
^~~~~~~~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi.h:2241:25: error: ‘napi_threadsafe_function_call_mode’ has not been declared
napi_threadsafe_function_call_mode mode) const;
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi.h:2248:5: error: ‘napi_threadsafe_function’ does not name a type
napi_threadsafe_function _tsfn;
^~~~~~~~~~~~~~~~~~~~~~~~
In file included from /var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi.h:2426:0,
from ../src/cld.cc:12:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In constructor ‘Napi::ThreadSafeFunction::ThreadSafeFunction()’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4475:5: error: class ‘Napi::ThreadSafeFunction’ does not have any field named ‘_tsfn’
: _tsfn() {
^~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: At global scope:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4479:5: error: ISO C++ forbids declaration of ‘ThreadSafeFunction’ with no type [-fpermissive]
napi_threadsafe_function tsfn)
^~~~~~~~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4479:5: error: ‘Napi::ThreadSafeFunction::ThreadSafeFunction’ declared as an ‘inline’ variable
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4479:5: error: ‘int Napi::ThreadSafeFunction::ThreadSafeFunction’ is not a static data member of ‘class Napi::ThreadSafeFunction’
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4479:5: error: ‘napi_threadsafe_function’ was not declared in this scope
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4483:37: error: expected type-specifier before ‘napi_threadsafe_function’
inline ThreadSafeFunction::operator napi_threadsafe_function() const {
^~~~~~~~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘napi_status Napi::ThreadSafeFunction::BlockingCall() const’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4488:32: error: ‘napi_tsfn_blocking’ was not declared in this scope
return CallInternal(nullptr, napi_tsfn_blocking);
^~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘napi_status Napi::ThreadSafeFunction::BlockingCall(Callback) const [with Callback = void*]’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4494:40: error: ‘_tsfn’ was not declared in this scope
return napi_call_threadsafe_function(_tsfn, data, napi_tsfn_blocking);
^~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4494:53: error: ‘napi_tsfn_blocking’ was not declared in this scope
return napi_call_threadsafe_function(_tsfn, data, napi_tsfn_blocking);
^~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4494:71: error: ‘napi_call_threadsafe_function’ was not declared in this scope
return napi_call_threadsafe_function(_tsfn, data, napi_tsfn_blocking);
^
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘napi_status Napi::ThreadSafeFunction::BlockingCall(Callback) const’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4500:54: error: ‘napi_tsfn_blocking’ was not declared in this scope
return CallInternal(new CallbackWrapper(callback), napi_tsfn_blocking);
^~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘napi_status Napi::ThreadSafeFunction::BlockingCall(DataType*, Callback) const’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4509:53: error: ‘napi_tsfn_blocking’ was not declared in this scope
return CallInternal(new CallbackWrapper(wrapper), napi_tsfn_blocking);
^~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘napi_status Napi::ThreadSafeFunction::NonBlockingCall() const’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4513:32: error: ‘napi_tsfn_nonblocking’ was not declared in this scope
return CallInternal(nullptr, napi_tsfn_nonblocking);
^~~~~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘napi_status Napi::ThreadSafeFunction::NonBlockingCall(Callback) const [with Callback = void*]’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4519:40: error: ‘_tsfn’ was not declared in this scope
return napi_call_threadsafe_function(_tsfn, data, napi_tsfn_nonblocking);
^~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4519:53: error: ‘napi_tsfn_nonblocking’ was not declared in this scope
return napi_call_threadsafe_function(_tsfn, data, napi_tsfn_nonblocking);
^~~~~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4519:74: error: ‘napi_call_threadsafe_function’ was not declared in this scope
return napi_call_threadsafe_function(_tsfn, data, napi_tsfn_nonblocking);
^
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘napi_status Napi::ThreadSafeFunction::NonBlockingCall(Callback) const’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4525:54: error: ‘napi_tsfn_nonblocking’ was not declared in this scope
return CallInternal(new CallbackWrapper(callback), napi_tsfn_nonblocking);
^~~~~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘napi_status Napi::ThreadSafeFunction::NonBlockingCall(DataType*, Callback) const’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4534:53: error: ‘napi_tsfn_nonblocking’ was not declared in this scope
return CallInternal(new CallbackWrapper(wrapper), napi_tsfn_nonblocking);
^~~~~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘void Napi::ThreadSafeFunction::Ref(napi_env) const’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4538:7: error: ‘_tsfn’ was not declared in this scope
if (_tsfn != nullptr) {
^~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4539:65: error: ‘napi_ref_threadsafe_function’ was not declared in this scope
napi_status status = napi_ref_threadsafe_function(env, _tsfn);
^
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘void Napi::ThreadSafeFunction::Unref(napi_env) const’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4545:7: error: ‘_tsfn’ was not declared in this scope
if (_tsfn != nullptr) {
^~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4546:67: error: ‘napi_unref_threadsafe_function’ was not declared in this scope
napi_status status = napi_unref_threadsafe_function(env, _tsfn);
^
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘napi_status Napi::ThreadSafeFunction::Acquire() const’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4552:43: error: ‘_tsfn’ was not declared in this scope
return napi_acquire_threadsafe_function(_tsfn);
^~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4552:48: error: ‘napi_acquire_threadsafe_function’ was not declared in this scope
return napi_acquire_threadsafe_function(_tsfn);
^
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘napi_status Napi::ThreadSafeFunction::Release()’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4556:43: error: ‘_tsfn’ was not declared in this scope
return napi_release_threadsafe_function(_tsfn, napi_tsfn_release);
^~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4556:50: error: ‘napi_tsfn_release’ was not declared in this scope
return napi_release_threadsafe_function(_tsfn, napi_tsfn_release);
^~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4556:67: error: ‘napi_release_threadsafe_function’ was not declared in this scope
return napi_release_threadsafe_function(_tsfn, napi_tsfn_release);
^
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘napi_status Napi::ThreadSafeFunction::Abort()’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4560:43: error: ‘_tsfn’ was not declared in this scope
return napi_release_threadsafe_function(_tsfn, napi_tsfn_abort);
^~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4560:50: error: ‘napi_tsfn_abort’ was not declared in this scope
return napi_release_threadsafe_function(_tsfn, napi_tsfn_abort);
^~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4560:65: error: ‘napi_release_threadsafe_function’ was not declared in this scope
return napi_release_threadsafe_function(_tsfn, napi_tsfn_abort);
^
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘Napi::ThreadSafeFunction::ConvertibleContext Napi::ThreadSafeFunction::GetContext() const’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4566:61: error: ‘_tsfn’ was not declared in this scope
napi_status status = napi_get_threadsafe_function_context(_tsfn, &context);
^~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4566:76: error: ‘napi_get_threadsafe_function_context’ was not declared in this scope
napi_status status = napi_get_threadsafe_function_context(_tsfn, &context);
^
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In static member function ‘static Napi::ThreadSafeFunction Napi::ThreadSafeFunction::New(napi_env, const Napi::Function&, const Napi::Object&, ResourceString, size_t, size_t, ContextType*, Finalizer, FinalizerDataType*, napi_finalize)’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4593:53: error: ‘class Napi::ThreadSafeFunction’ has no member named ‘_tsfn’
finalizeData, wrapper, context, CallJS, &tsfn._tsfn);
^~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: At global scope:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4604:5: error: ‘napi_threadsafe_function_call_mode’ has not been declared
napi_threadsafe_function_call_mode mode) const {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h: In member function ‘napi_status Napi::ThreadSafeFunction::CallInternal(Napi::ThreadSafeFunction::CallbackWrapper*, int) const’:
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4606:7: error: ‘_tsfn’ was not declared in this scope
_tsfn, callbackWrapper, mode);
^~~~~
/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/node-addon-api/napi-inl.h:4606:35: error: ‘napi_call_threadsafe_function’ was not declared in this scope
_tsfn, callbackWrapper, mode);
^
cld.target.mk:99: recipe for target 'Release/obj.target/cld/src/cld.o' failed
make: *** [Release/obj.target/cld/src/cld.o] Error 1
make: Leaving directory '/var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/cld/build'
gyp ERR! build error
gyp ERR! stack Error: make
failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:258:23)
gyp ERR! stack at ChildProcess.emit (events.js:180:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:209:12)
gyp ERR! System Linux 4.15.0-1058-aws
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /var/lib/jenkins/workspace/I-back-end-tests-prototype_PR-18/node_modules/cld
gyp ERR! node -v v9.11.2
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN [email protected] No repository field.
npm WARN The package axios-curlirize is included as both a dev and production dependency.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
┌──────────────────────────────────────────────┐
│ npm update check failed │
│ Try running with sudo or get access │
│ to the local update config store via │
│ sudo chown -R
└──────────────────────────────────────────────┘`
Could you please help me if I missing any dependency or something?
Thanks!
Hi,
@shauntrennery recently opened an issue on one of my projects that uses cld (via limax by @lovell): keystonejs/keystone-utils#15
Just wanted to see if you can provide any insights into why this would be happening, or how we can fix it.
The error:
Application has thrown an uncaught exception and is terminated:
Error: Cannot find module './build/Release/cld'
at Function.Module._resolveFilename (module.js:336:15)
at Function.Module._load (module.js:278:25)
at Module.require (module.js:365:17)
at require (module.js:384:17)
at Object. (D:\home\site\wwwroot\node_modules\keystone-utils\node_modules\limax\node_modules\cld\index.js:2:12)
at Module._compile (module.js:460:26)
at Object.Module._extensions..js (module.js:478:10)
at Module.load (module.js:355:32)
at Function.Module._load (module.js:310:12)
at Module.require (module.js:365:17)
NodeJS: 4.9.1
NPM: 2.15.11
MacOS Catalina: 10.15.3
I'm trying to install node-cld and it gives the following error. I'm simply running npm i cld
> node-gyp rebuild
CXX(target) Release/obj.target/cld/cld/internal/cldutil.o
warning: include path for stdlibc++ headers not found; pass '-stdlib=libc++' on the command line to use the libc++ standard library instead [-Wstdlibcxx-not-found]
In file included from ../cld/internal/cldutil.cc:20:
In file included from ../cld/internal/cldutil.h:24:
../cld/internal/cldutil_shared.h:403:8: warning: 'const' type qualifier on return type has no effect [-Wignored-qualifiers]
inline const uint32 QuadHashV3Lookup4(const CLD2TableSummary* gram_obj,
^~~~~~
../cld/internal/cldutil_shared.h:431:8: warning: 'const' type qualifier on return type has no effect [-Wignored-qualifiers]
inline const uint32 OctaHashV3Lookup4(const CLD2TableSummary* gram_obj,
^~~~~~
In file included from ../cld/internal/cldutil.cc:20:
In file included from ../cld/internal/cldutil.h:25:
In file included from ../cld/internal/scoreonescriptspan.h:81:
../cld/internal/compact_lang_det_impl.h:22:10: fatal error: 'vector' file not found
#include <vector>
^~~~~~~~
3 warnings and 1 error generated.
make: *** [Release/obj.target/cld/cld/internal/cldutil.o] Error 1
It works alright when I try to install it with node v10.x. I need to build it with node v4.9.1. What's wrong here?
Hello,
in some cases, depends on string, the result contains duplicates:
{ reliable: true, textBytes: 938, languages: [ { name: 'ITALIAN', code: 'it', percent: 99, score: 420 } ], chunks: [ { name: 'ITALIAN', code: 'it', offset: 0, bytes: 170 }, { name: 'ITALIAN', code: 'it', offset: 310, bytes: 236 }, { name: 'ITALIAN', code: 'it', offset: 679, bytes: 257 } ] }
Currently building fails. Would love this supported.
Hey getting this error when trying to install on a nodejs project.
Please advise,
Thanks.
npm ERR! make: *** [Release/obj.target/cld/src/constants.o] Error 1
npm ERR! gyp ERR! build error
npm ERR! gyp ERR! stack Error: `make` failed with exit code: 2
npm ERR! gyp ERR! stack at ChildProcess.onExit (/Users/user/node_modules/node-gyp/lib/build.js:194:23)
npm ERR! gyp ERR! stack at ChildProcess.emit (node:events:390:28)
npm ERR! gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:290:12)
npm ERR! gyp ERR! System Darwin 21.2.0
npm ERR! gyp ERR! command "/usr/local/bin/node" "/Users/user/node_modules/.bin/node-gyp" "rebuild"
npm ERR! gyp ERR! cwd /Users/user/Documents/General Projects/sherfud-api/node_modules/cld
npm ERR! gyp ERR! node -v v16.13.1
npm ERR! gyp ERR! node-gyp -v v8.4.1
npm ERR! gyp ERR! not ok
I am not C++ guy but i gues it's a node-gyp problem?
make: *** [Release/obj.target/cld/src/cld.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:262:23)
gyp ERR! stack at ChildProcess.emit (events.js:200:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
Hi,
Don't know why but the installation is failing on my server (Ubuntu 14.04 AWS) but working on my mac:
tried with a lot of different node version
node -v 4.0.0
npm -v 2.14.2
gcc version 4.8.4
currently
here's the error
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_2.o
AR(target) Release/obj.target/deps/cld/cld-c.a
COPY Release/cld-c.a
CXX(target) Release/obj.target/cld/src/constants.o
In file included from ../src/constants.h:4:0,
from ../src/constants.cc:3:
../deps/cld/public/compact_lang_det.h:379:28: error: variable or field ‘DumpResultChunkVector’ declared void
void DumpResultChunkVector(FILE* f, const char* src,
^
../deps/cld/public/compact_lang_det.h:379:28: error: ‘FILE’ was not declared in this scope
../deps/cld/public/compact_lang_det.h:379:34: error: ‘f’ was not declared in this scope
void DumpResultChunkVector(FILE* f, const char* src,
^
../deps/cld/public/compact_lang_det.h:379:37: error: expected primary-expression before ‘const’
void DumpResultChunkVector(FILE* f, const char* src,
^
../deps/cld/public/compact_lang_det.h:380:45: error: expected primary-expression before ‘’ token
ResultChunkVector resultchunkvector);
^
../deps/cld/public/compact_lang_det.h:380:47: error: ‘resultchunkvector’ was not declared in this scope
ResultChunkVector* resultchunkvector);
^
make: *** [Release/obj.target/cld/src/constants.o] Error 1
and after npm error
If you have any clue, we suspect a gcc version but we updated my mac one and can still install.
Thanks a lot for your support
OSX, It seems that library works well, but the number of warnings is a bit scary. Can you explain it pleae? Thank you!
CXX(target) Release/obj.target/cld/cld/internal/cldutil.o
In file included from ../cld/internal/cldutil.cc:20:
In file included from ../cld/internal/cldutil.h:24:
../cld/internal/cldutil_shared.h:403:8: warning: 'const' type qualifier on
return type has no effect [-Wignored-qualifiers]
inline const uint32 QuadHashV3Lookup4(const CLD2TableSummary* gram_obj,
^~~~~~
../cld/internal/cldutil_shared.h:431:8: warning: 'const' type qualifier on
return type has no effect [-Wignored-qualifiers]
inline const uint32 OctaHashV3Lookup4(const CLD2TableSummary* gram_obj,
^~~~~~
../cld/internal/cldutil.cc:49:22: warning: unused variable
'kSkipSpaceVowelContinue' [-Wunused-const-variable]
static const uint8 kSkipSpaceVowelContinue[256] = {
^
../cld/internal/cldutil.cc:62:22: warning: unused variable 'kSkipSpaceContinue'
[-Wunused-const-variable]
static const uint8 kSkipSpaceContinue[256] = {
^
../cld/internal/cldutil.cc:89:22: warning: unused variable
'kAdvanceOneCharSpace' [-Wunused-const-variable]
static const uint8 kAdvanceOneCharSpace[256] = {
^
5 warnings generated.
CXX(target) Release/obj.target/cld/cld/internal/cldutil_shared.o
In file included from ../cld/internal/cldutil_shared.cc:19:
../cld/internal/cldutil_shared.h:403:8: warning: 'const' type qualifier on
return type has no effect [-Wignored-qualifiers]
inline const uint32 QuadHashV3Lookup4(const CLD2TableSummary* gram_obj,
^~~~~~
../cld/internal/cldutil_shared.h:431:8: warning: 'const' type qualifier on
return type has no effect [-Wignored-qualifiers]
inline const uint32 OctaHashV3Lookup4(const CLD2TableSummary* gram_obj,
^~~~~~
../cld/internal/cldutil_shared.cc:49:18: warning: unused variable
'kMinCJKUTF8CharBytes' [-Wunused-const-variable]
static const int kMinCJKUTF8CharBytes = 3;
^
../cld/internal/cldutil_shared.cc:51:18: warning: unused variable
'kMinGramCount' [-Wunused-const-variable]
static const int kMinGramCount = 3;
^
../cld/internal/cldutil_shared.cc:52:18: warning: unused variable
'kMaxGramCount' [-Wunused-const-variable]
static const int kMaxGramCount = 16;
^
../cld/internal/cldutil_shared.cc:54:18: warning: unused variable 'UTFmax'
[-Wunused-const-variable]
static const int UTFmax = 4; // Max number of bytes in a UTF-8 character
^
6 warnings generated.
CXX(target) Release/obj.target/cld/cld/internal/compact_lang_det.o
CXX(target) Release/obj.target/cld/cld/internal/compact_lang_det_hint_code.o
../cld/internal/compact_lang_det_hint_code.cc:788:28: warning: missing field
'onelangprior2' initializer [-Wmissing-field-initializers]
{"lu", LUXEMBOURGISH + W4},
^
../cld/internal/compact_lang_det_hint_code.cc:1060:15: warning: comparison of
integers of different signs: 'int' and 'const size_type' (aka
'const unsigned long') [-Wsign-compare]
if (comma == string::npos) {comma = langtags.size();} // fake trailing comma
~~~~~ ^ ~~~~~~~~~~~~
../cld/internal/compact_lang_det_hint_code.cc:1403:15: warning: comparison of
integers of different signs: 'int' and 'const size_type' (aka
'const unsigned long') [-Wsign-compare]
if (comma == string::npos) {comma = langtags
Trying to run cld on Elementary OS Luna (build on Ubuntu 12.04 Precise)
During npm install cld I get this error:
CXX(target) Release/obj.target/cld/src/constants.o
clang: warning: argument unused during compilation: '-fno-tree-vrp'
CXX(target) Release/obj.target/cld/src/cld.o
clang: warning: argument unused during compilation: '-fno-tree-vrp'
SOLINK_MODULE(target) Release/obj.target/cld.node
clang: error: no such file or directory: 'muldefs'
make: *** [Release/obj.target/cld.node] Error 1
make: Leaving directory /home/musichen/dev/bitbucket/wng-backend-langdetect/node_modules/cld/build' gyp ERR! build error gyp ERR! stack Error:
make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:269:23)
gyp ERR! stack at ChildProcess.emit (events.js:110:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:1074:12)
gyp ERR! System Linux 3.11.0-26-generic
gyp ERR! command "node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/musichen/dev/bitbucket/wng-backend-langdetect/node_modules/cld
gyp ERR! node -v v0.12.4
gyp ERR! node-gyp -v v2.0.2
gyp ERR! not ok
npm ERR! Linux 3.11.0-26-generic
npm ERR! argv "node" "/usr/local/bin/npm" "install"
npm ERR! node v0.12.4
npm ERR! npm v2.13.3
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the cld package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls cld
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home/musichen/dev/bitbucket/wng-backend-langdetect/npm-debug.log
It's not reliable to use this library.
I have played with it a lot and it doesn't work for some cases
require('cld').detect('Hi there', function(err, result) {
console.log(err, result);
});
Response:
{ message: 'Failed to identify language' } undefined
require('cld').detect('Nice and cool!', function(err, result) {
console.log(err, result);
});
Response:
{ message: 'Failed to identify language' } undefined
require('cld').detect('Привіт, дівко!', function(err, result) {
console.log(err, result);
});
Response:
{ message: 'Failed to identify language' } undefined
require('cld').detect('Мій пароль', function(err, result) {
console.log(err, result);
});
Response:
{ message: 'Failed to identify language' } undefined
require('cld').detect('Publique suas estampas', function(err, result) {
console.log(err, result);
});
Response:
{ message: 'Failed to identify language' } undefined
require('cld').detect('Top artistas', function(err, result) {
console.log(err, result);
});
Response:
{ message: 'Failed to identify language' } undefined
require('cld').detect('Cześć stary!', function(err, result) {
console.log(err, result);
});
Response:
{ message: 'Failed to identify language' } undefined
cat /proc/version
: Linux version 4.4.0-97-generic (buildd@lcy01-16) (gcc version 4.8.4 (Ubuntu 4.8.4-2ubuntu1~14.04.3) )node --version
: v8.10.0npm --version
: 5.7.1node-gyp --version
: v3.6.2cld
: 2.4.7I get the following build error when I run the command npm i cld
:
> [email protected] install /home/user/node-upgrade/node_modules/cld
> node-gyp rebuild
make: Entering directory `/home/user/node-upgrade/node_modules/cld/build'
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil_shared.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_hint_code.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_impl.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/debug.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/fixunicodevalue.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_entities.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_language.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_ulscript.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/getonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/lang_script.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/offsetmap.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/scoreonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/tote.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/utf8statetable.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_uni_prop_80.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_cjk_compatible.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_delta_bi_32.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_distinct_bi_0.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quad0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_deltaocta0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_deltaoctachrome.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_distinctocta0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_distinctoctachrome.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quadchrome_16.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quadchrome_2.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_2.o
AR(target) Release/obj.target/deps/cld/cld-c.a
COPY Release/cld-c.a
CXX(target) Release/obj.target/cld/src/constants.o
CXX(target) Release/obj.target/cld/src/cld.o
In file included from ../node_modules/nan/nan.h:111:0,
from ../src/cld.cc:4:
../node_modules/nan/nan_new.h: In function ‘v8::Local<T> Nan::imp::To(v8::Handle<v8::Integer>) [with T = v8::Int32; v8::Handle<v8::Integer> = v8::Local<v8::Integer>]’:
../node_modules/nan/nan_new.h:34:64: warning: ‘v8::Local<v8::Int32> v8::Value::ToInt32() const’ is deprecated (declared at /home/user/.node-gyp/8.10.0/include/node/v8.h:9796): Use maybe version [-Wdeprecated-declarations]
To<v8::Int32>(v8::Handle<v8::Integer> i) { return i->ToInt32(); }
^
../node_modules/nan/nan_new.h: In function ‘v8::Local<T> Nan::imp::To(v8::Handle<v8::Integer>) [with T = v8::Uint32; v8::Handle<v8::Integer> = v8::Local<v8::Integer>]’:
../node_modules/nan/nan_new.h:39:65: warning: ‘v8::Local<v8::Uint32> v8::Value::ToUint32() const’ is deprecated (declared at /home/user/.node-gyp/8.10.0/include/node/v8.h:9790): Use maybe version [-Wdeprecated-declarations]
To<v8::Uint32>(v8::Handle<v8::Integer> i) { return i->ToUint32(); }
^
In file included from ../node_modules/nan/nan_new.h:191:0,
from ../node_modules/nan/nan.h:111,
from ../src/cld.cc:4:
../node_modules/nan/nan_implementation_12_inl.h: In static member function ‘static Nan::imp::FactoryBase<v8::BooleanObject>::return_t Nan::imp::Factory<v8::BooleanObject>::New(bool)’:
../node_modules/nan/nan_implementation_12_inl.h:49:38: warning: ‘static v8::Local<v8::Value> v8::BooleanObject::New(bool)’ is deprecated (declared at /home/user/.node-gyp/8.10.0/include/node/v8.h:4845): Pass an isolate [-Wdeprecated-declarations]
return v8::BooleanObject::New(value).As<v8::BooleanObject>();
^
../node_modules/nan/nan_implementation_12_inl.h: In static member function ‘static Nan::imp::FactoryBase<v8::Script>::return_t Nan::imp::Factory<v8::Script>::New(v8::Local<v8::String>)’:
../node_modules/nan/nan_implementation_12_inl.h:166:69: warning: ‘static v8::Local<v8::Script> v8::ScriptCompiler::Compile(v8::Isolate*, v8::ScriptCompiler::Source*, v8::ScriptCompiler::CompileOptions)’ is deprecated (declared at /home/user/.node-gyp/8.10.0/include/node/v8.h:1423): Use maybe version [-Wdeprecated-declarations]
return v8::ScriptCompiler::Compile(v8::Isolate::GetCurrent(), &src);
^
../node_modules/nan/nan_implementation_12_inl.h: In static member function ‘static Nan::imp::FactoryBase<v8::Script>::return_t Nan::imp::Factory<v8::Script>::New(v8::Local<v8::String>, const v8::ScriptOrigin&)’:
../node_modules/nan/nan_implementation_12_inl.h:173:69: warning: ‘static v8::Local<v8::Script> v8::ScriptCompiler::Compile(v8::Isolate*, v8::ScriptCompiler::Source*, v8::ScriptCompiler::CompileOptions)’ is deprecated (declared at /home/user/.node-gyp/8.10.0/include/node/v8.h:1423): Use maybe version [-Wdeprecated-declarations]
return v8::ScriptCompiler::Compile(v8::Isolate::GetCurrent(), &src);
^
../node_modules/nan/nan_implementation_12_inl.h: In static member function ‘static Nan::imp::FactoryBase<v8::String>::return_t Nan::imp::Factory<v8::String>::New(const uint8_t*, int)’:
../node_modules/nan/nan_implementation_12_inl.h:206:42: warning: ‘static v8::Local<v8::String> v8::String::NewFromOneByte(v8::Isolate*, const uint8_t*, v8::String::NewStringType, int)’ is deprecated (declared at /home/user/.node-gyp/8.10.0/include/node/v8.h:2679): Use maybe version [-Wdeprecated-declarations]
v8::String::kNormalString, length);
^
../node_modules/nan/nan_implementation_12_inl.h: In static member function ‘static Nan::imp::FactoryBase<v8::String>::return_t Nan::imp::Factory<v8::String>::New(v8::String::ExternalStringResource*)’:
../node_modules/nan/nan_implementation_12_inl.h:217:66: warning: ‘static v8::Local<v8::String> v8::String::NewExternal(v8::Isolate*, v8::String::ExternalStringResource*)’ is deprecated (declared at /home/user/.node-gyp/8.10.0/include/node/v8.h:2718): Use maybe version [-Wdeprecated-declarations]
return v8::String::NewExternal(v8::Isolate::GetCurrent(), value);
^
../node_modules/nan/nan_implementation_12_inl.h: In static member function ‘static Nan::imp::FactoryBase<v8::UnboundScript>::return_t Nan::imp::Factory<v8::UnboundScript>::New(v8::Local<v8::String>)’:
../node_modules/nan/nan_implementation_12_inl.h:237:76: warning: ‘static v8::Local<v8::UnboundScript> v8::ScriptCompiler::CompileUnbound(v8::Isolate*, v8::ScriptCompiler::Source*, v8::ScriptCompiler::CompileOptions)’ is deprecated (declared at /home/user/.node-gyp/8.10.0/include/node/v8.h:1404): Use maybe version [-Wdeprecated-declarations]
return v8::ScriptCompiler::CompileUnbound(v8::Isolate::GetCurrent(), &src);
^
../node_modules/nan/nan_implementation_12_inl.h: In static member function ‘static Nan::imp::FactoryBase<v8::UnboundScript>::return_t Nan::imp::Factory<v8::UnboundScript>::New(v8::Local<v8::String>, const v8::ScriptOrigin&)’:
../node_modules/nan/nan_implementation_12_inl.h:244:76: warning: ‘static v8::Local<v8::UnboundScript> v8::ScriptCompiler::CompileUnbound(v8::Isolate*, v8::ScriptCompiler::Source*, v8::ScriptCompiler::CompileOptions)’ is deprecated (declared at /home/user/.node-gyp/8.10.0/include/node/v8.h:1404): Use maybe version [-Wdeprecated-declarations]
return v8::ScriptCompiler::CompileUnbound(v8::Isolate::GetCurrent(), &src);
^
In file included from ../src/cld.cc:4:0:
../node_modules/nan/nan.h: At global scope:
../node_modules/nan/nan.h:324:27: error: redefinition of ‘template<class T> v8::Local<T> Nan::imp::NanEnsureHandleOrPersistent(const v8::Local<T>&)’
NAN_INLINE v8::Local<T> NanEnsureHandleOrPersistent(const v8::Local<T> &val) {
^
../node_modules/nan/nan.h:319:17: error: ‘template<class T> v8::Handle<T> Nan::imp::NanEnsureHandleOrPersistent(v8::Handle<T>&)’ previously declared here
v8::Handle<T> NanEnsureHandleOrPersistent(const v8::Handle<T> &val) {
^
../node_modules/nan/nan.h:344:27: error: redefinition of ‘template<class T> v8::Local<T> Nan::imp::NanEnsureLocal(v8::Handle<T>&)’
NAN_INLINE v8::Local<T> NanEnsureLocal(const v8::Handle<T> &val) {
^
../node_modules/nan/nan.h:334:27: error: ‘template<class T> v8::Local<T> Nan::imp::NanEnsureLocal(const v8::Local<T>&)’ previously declared here
NAN_INLINE v8::Local<T> NanEnsureLocal(const v8::Local<T> &val) {
^
../node_modules/nan/nan.h: In function ‘bool NanIdleNotification(int)’:
../node_modules/nan/nan.h:374:71: warning: ‘bool v8::Isolate::IdleNotification(int)’ is deprecated (declared at /home/user/.node-gyp/8.10.0/include/node/v8.h:7481): use IdleNotificationDeadline() [-Wdeprecated-declarations]
return v8::Isolate::GetCurrent()->IdleNotification(idle_time_in_ms);
^
../node_modules/nan/nan.h: At global scope:
../node_modules/nan/nan.h:560:20: error: variable or field ‘NanAddGCEpilogueCallback’ declared void
v8::Isolate::GCEpilogueCallback callback
^
../node_modules/nan/nan.h:560:7: error: ‘GCEpilogueCallback’ is not a member of ‘v8::Isolate’
v8::Isolate::GCEpilogueCallback callback
^
../node_modules/nan/nan.h:561:18: error: expected primary-expression before ‘gc_type_filter’
, v8::GCType gc_type_filter = v8::kGCTypeAll) {
^
../node_modules/nan/nan.h:566:20: error: variable or field ‘NanRemoveGCEpilogueCallback’ declared void
v8::Isolate::GCEpilogueCallback callback) {
^
../node_modules/nan/nan.h:566:7: error: ‘GCEpilogueCallback’ is not a member of ‘v8::Isolate’
v8::Isolate::GCEpilogueCallback callback) {
^
../node_modules/nan/nan.h:571:20: error: variable or field ‘NanAddGCPrologueCallback’ declared void
v8::Isolate::GCPrologueCallback callback
^
../node_modules/nan/nan.h:571:7: error: ‘GCPrologueCallback’ is not a member of ‘v8::Isolate’
v8::Isolate::GCPrologueCallback callback
^
../node_modules/nan/nan.h:572:18: error: expected primary-expression before ‘gc_type_filter’
, v8::GCType gc_type_filter = v8::kGCTypeAll) {
^
../node_modules/nan/nan.h:577:20: error: variable or field ‘NanRemoveGCPrologueCallback’ declared void
v8::Isolate::GCPrologueCallback callback) {
^
../node_modules/nan/nan.h:577:7: error: ‘GCPrologueCallback’ is not a member of ‘v8::Isolate’
v8::Isolate::GCPrologueCallback callback) {
^
../node_modules/nan/nan.h:659:11: error: ‘WeakCallbackData’ in namespace ‘v8’ does not name a type
const v8::WeakCallbackData<T, _NanWeakCallbackInfo<T, P> > &data) {
^
../node_modules/nan/nan.h:659:15: error: ISO C++ forbids declaration of ‘parameter’ with no type [-fpermissive]
const v8::WeakCallbackData<T, _NanWeakCallbackInfo<T, P> > &data) {
^
../node_modules/nan/nan.h:659:31: error: expected ‘,’ or ‘...’ before ‘<’ token
const v8::WeakCallbackData<T, _NanWeakCallbackInfo<T, P> > &data) {
^
../node_modules/nan/nan.h: In function ‘void _NanWeakCallbackDispatcher(int)’:
../node_modules/nan/nan.h:660:42: error: ‘data’ was not declared in this scope
_NanWeakCallbackInfo<T, P> *info = data.GetParameter();
^
../node_modules/nan/nan.h: At global scope:
../node_modules/nan/nan.h:757:13: error: ‘node::smalloc’ has not been declared
, node::smalloc::FreeCallback callback
^
../node_modules/nan/nan.h:757:35: error: expected ‘,’ or ‘...’ before ‘callback’
, node::smalloc::FreeCallback callback
^
../node_modules/nan/nan.h: In function ‘v8::Local<v8::Object> NanNewBufferHandle(char*, size_t, int)’:
../node_modules/nan/nan.h:761:50: error: ‘callback’ was not declared in this scope
v8::Isolate::GetCurrent(), data, length, callback, hint);
^
../node_modules/nan/nan.h:761:60: error: ‘hint’ was not declared in this scope
v8::Isolate::GetCurrent(), data, length, callback, hint);
^
../node_modules/nan/nan.h: In function ‘v8::Local<v8::Object> NanNewBufferHandle(const char*, uint32_t)’:
../node_modules/nan/nan.h:768:67: error: invalid conversion from ‘const char*’ to ‘char*’ [-fpermissive]
return node::Buffer::New(v8::Isolate::GetCurrent(), data, size);
^
In file included from ../node_modules/nan/nan.h:25:0,
from ../src/cld.cc:4:
/home/user/.node-gyp/8.10.0/include/node/node_buffer.h:67:40: error: initializing argument 2 of ‘v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t)’ [-fpermissive]
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
In file included from ../src/cld.cc:4:0:
../node_modules/nan/nan.h:768:67: error: could not convert ‘node::Buffer::New(v8::Isolate::GetCurrent(), ((char*)data), ((size_t)size))’ from ‘v8::MaybeLocal<v8::Object>’ to ‘v8::Local<v8::Object>’
return node::Buffer::New(v8::Isolate::GetCurrent(), data, size);
^
../node_modules/nan/nan.h: In function ‘v8::Local<v8::Object> NanNewBufferHandle(uint32_t)’:
../node_modules/nan/nan.h:772:61: error: could not convert ‘node::Buffer::New(v8::Isolate::GetCurrent(), ((size_t)size))’ from ‘v8::MaybeLocal<v8::Object>’ to ‘v8::Local<v8::Object>’
return node::Buffer::New(v8::Isolate::GetCurrent(), size);
^
../node_modules/nan/nan.h: In function ‘v8::Local<v8::Object> NanBufferUse(char*, uint32_t)’:
../node_modules/nan/nan.h:779:12: error: ‘Use’ is not a member of ‘node::Buffer’
return node::Buffer::Use(v8::Isolate::GetCurrent(), data, size);
^
../node_modules/nan/nan.h: In function ‘v8::Local<v8::Script> NanCompileScript(v8::Local<v8::String>, const v8::ScriptOrigin&)’:
../node_modules/nan/nan.h:806:74: warning: ‘static v8::Local<v8::Script> v8::ScriptCompiler::Compile(v8::Isolate*, v8::ScriptCompiler::Source*, v8::ScriptCompiler::CompileOptions)’ is deprecated (declared at /home/user/.node-gyp/8.10.0/include/node/v8.h:1423): Use maybe version [-Wdeprecated-declarations]
return v8::ScriptCompiler::Compile(v8::Isolate::GetCurrent(), &source);
^
../node_modules/nan/nan.h: In function ‘v8::Local<v8::Script> NanCompileScript(v8::Local<v8::String>)’:
../node_modules/nan/nan.h:813:74: warning: ‘static v8::Local<v8::Script> v8::ScriptCompiler::Compile(v8::Isolate*, v8::ScriptCompiler::Source*, v8::ScriptCompiler::CompileOptions)’ is deprecated (declared at /home/user/.node-gyp/8.10.0/include/node/v8.h:1423): Use maybe version [-Wdeprecated-declarations]
return v8::ScriptCompiler::Compile(v8::Isolate::GetCurrent(), &source);
Hello, when I'm trying to install the module in iojs version 1.3, the build process failed with the following error message.
XX(target) Release/obj.target/cld-c/deps/cld/internal/scoreonescriptspan.o
../deps/cld/internal/scoreonescriptspan.cc:1145:7: error: non-constant-expression cannot be narrowed from type 'Language' to 'uint16' (aka 'unsigned short') in initializer list
[-Wc++11-narrowing]
one_one_lang, UNKNOWN_LANGUAGE, score, 1,
^~~~~~~~~~~~
../deps/cld/internal/scoreonescriptspan.cc:1145:7: note: override this message by inserting an explicit cast
one_one_lang, UNKNOWN_LANGUAGE, score, 1,
^~~~~~~~~~~~
static_cast<uint16>( )
...
...
../deps/cld/internal/scoreonescriptspan.cc:1146:51: note: override this message by inserting an explicit cast
bytes, 0, scriptspan.ulscript, reliability, reliability
^~~~~~~~~~~
static_cast<uint8>( )
6 errors generated.
The reason is that pangyp in iojs will add a "-std=gnu++0x" when compiling the native module. After add a new flag called "-Wno-c++11-narrwoing" in the deps/cld/binding.gyp, the problem solved.
The following is the git diff output:
diff --git a/deps/cld/binding.gyp b/deps/cld/binding.gyp
index e3d037a..ea614b9 100644
--- a/deps/cld/binding.gyp
+++ b/deps/cld/binding.gyp
@@ -35,7 +35,7 @@
"defines": [],
"cflags_cc": ["-w"],
"xcode_settings": {
- "OTHER_CFLAGS": ["-w"]
+ "OTHER_CFLAGS": ["-w","-Wno-c++11-narrowing"]
}
}
]
Since it's a small fix, I haven't sent a PR. Sorry bout that :)
Hello
I encountered an incompatibility while building with Node 12 on 32bit Windows machine.
Here are the logs.
[exec] d:\a\_work\428\s\.temp\node_headers\include\node\v8.h(8207): warning C4996: 'v8::MicrotasksCompletedCallback': was declared deprecated (compiling source file ..\src\cld.cc) [D:\a\_work\428\s\node_modules\cld\build\cld.vcxproj]
[exec] d:\a\_work\428\s\.temp\node_headers\include\node\v8.h(6668): note: see declaration of 'v8::MicrotasksCompletedCallback' (compiling source file ..\src\cld.cc)
[exec] d:\a\_work\428\s\.temp\node_headers\include\node\v8.h(8216): warning C4996: 'v8::MicrotasksCompletedCallback': was declared deprecated (compiling source file ..\src\cld.cc) [D:\a\_work\428\s\node_modules\cld\build\cld.vcxproj]
[exec] d:\a\_work\428\s\.temp\node_headers\include\node\v8.h(6668): note: see declaration of 'v8::MicrotasksCompletedCallback' (compiling source file ..\src\cld.cc)
[exec] d:\a\_work\428\s\node_modules\nan\nan_converters_43_inl.h(22): error C2664: 'v8::Local<v8::Boolean> v8::Value::ToBoolean(void) const': cannot convert argument 1 from 'v8::Local<v8::Context>' to 'v8::Isolate *' (compiling source file ..\src\cld.cc) [D:\a\_work\428\s\node_modules\cld\build\cld.vcxproj]
[exec] d:\a\_work\428\s\node_modules\nan\nan_converters_43_inl.h(22): note: No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called (compiling source file ..\src\cld.cc)
[exec] d:\a\_work\428\s\node_modules\nan\nan_converters_43_inl.h(22): error C2228: left of '.FromMaybe' must have class/struct/union (compiling source file ..\src\cld.cc) [D:\a\_work\428\s\node_modules\cld\build\cld.vcxproj]
[exec] d:\a\_work\428\s\node_modules\nan\nan_converters_43_inl.h(40): error C2664: 'bool v8::Value::BooleanValue(void) const': cannot convert argument 1 from 'v8::Local<v8::Context>' to 'v8::Isolate *' (compiling source file ..\src\cld.cc) [D:\a\_work\428\s\node_modules\cld\build\cld.vcxproj]
[exec] d:\a\_work\428\s\node_modules\nan\nan_converters_43_inl.h(40): note: No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called (compiling source file ..\src\cld.cc)
[exec] d:\a\_work\428\s\node_modules\nan\nan_object_wrap.h(24): error C2039: 'IsNearDeath': is not a member of 'Nan::Persistent<v8::Object,v8::NonCopyablePersistentTraits<T>>' [D:\a\_work\428\s\node_modules\cld\build\cld.vcxproj]
[exec] with
[exec] [
[exec] T=v8::Object
[exec] ] (compiling source file ..\src\cld.cc)
[exec] D:\a\_work\428\s\node_modules\nan\nan.h(1920): note: see declaration of 'Nan::Persistent<v8::Object,v8::NonCopyablePersistentTraits<T>>'
[exec] with
[exec] [
[exec] T=v8::Object
[exec] ] (compiling source file ..\src\cld.cc)
[exec] d:\a\_work\428\s\node_modules\nan\nan_object_wrap.h(127): error C2039: 'IsNearDeath': is not a member of 'Nan::Persistent<v8::Object,v8::NonCopyablePersistentTraits<T>>' [D:\a\_work\428\s\node_modules\cld\build\cld.vcxproj]
[exec] with
[exec] [
[exec] T=v8::Object
[exec] ] (compiling source file ..\src\cld.cc)
[exec] D:\a\_work\428\s\node_modules\nan\nan.h(1920): note: see declaration of 'Nan::Persistent<v8::Object,v8::NonCopyablePersistentTraits<T>>'
[exec] with
[exec] [
[exec] T=v8::Object
[exec] ] (compiling source file ..\src\cld.cc)
[exec] gyp ERR! build error
[exec] gyp ERR! stack Error: `C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\15.0\Bin\MSBuild.exe` failed with exit code: 1
[exec] gyp ERR! stack at ChildProcess.onExit (C:\Apps\nodejs\8.11.2\node_modules\npm\node_modules\node-gyp\lib\build.js:258:23)
[exec] gyp ERR! stack at emitTwo (events.js:126:13)
[exec] gyp ERR! stack at ChildProcess.emit (events.js:214:7)
[exec] gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:198:12)
[exec] gyp ERR! System Windows_NT 10.0.17134
[exec] gyp ERR! command "C:\\Apps\\nodejs\\8.11.2\\node.exe" "C:\\Apps\\nodejs\\8.11.2\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
The std::unexpected_handler
was removed in C++17:
Line 9 in 626a94e
This leads to compiler errors on the m1 macs (and probably also on other platforms that build with C++17 or newer).
This can be easily fixed by removing that line.
Here the full error message:
$ npm install
> [email protected] install
> node-gyp rebuild
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | darwin | arm64
gyp info find Python using Python version 3.9.7 found at "/opt/homebrew/opt/[email protected]/bin/python3.9"
gyp info spawn /opt/homebrew/opt/[email protected]/bin/python3.9
gyp info spawn args [
gyp info spawn args '/opt/homebrew/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args 'binding.gyp',
gyp info spawn args '-f',
gyp info spawn args 'make',
gyp info spawn args '-I',
gyp info spawn args '/Users/lars/Documents/projects/node-cld/build/config.gypi',
gyp info spawn args '-I',
gyp info spawn args '/opt/homebrew/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
gyp info spawn args '-I',
gyp info spawn args '/Users/lars/Library/Caches/node-gyp/17.0.1/include/node/common.gypi',
gyp info spawn args '-Dlibrary=shared_library',
gyp info spawn args '-Dvisibility=default',
gyp info spawn args '-Dnode_root_dir=/Users/lars/Library/Caches/node-gyp/17.0.1',
gyp info spawn args '-Dnode_gyp_dir=/opt/homebrew/lib/node_modules/npm/node_modules/node-gyp',
gyp info spawn args '-Dnode_lib_file=/Users/lars/Library/Caches/node-gyp/17.0.1/<(target_arch)/node.lib',
gyp info spawn args '-Dmodule_root_dir=/Users/lars/Documents/projects/node-cld',
gyp info spawn args '-Dnode_engine=v8',
gyp info spawn args '--depth=.',
gyp info spawn args '--no-parallel',
gyp info spawn args '--generator-output',
gyp info spawn args 'build',
gyp info spawn args '-Goutput_dir=.'
gyp info spawn args ]
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cldutil_shared.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_hint_code.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/compact_lang_det_impl.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/debug.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/fixunicodevalue.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_entities.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_language.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_ulscript.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/getonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/lang_script.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/offsetmap.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/scoreonescriptspan.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/tote.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/utf8statetable.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_uni_prop_80.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_cjk_compatible.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_cjk_delta_bi_32.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/generated_distinct_bi_0.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quad0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_deltaocta0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_deltaoctachrome.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_distinctocta0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_distinctoctachrome.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quadchrome_16.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld2_generated_quadchrome_2.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_0122.o
CXX(target) Release/obj.target/cld-c/deps/cld/internal/cld_generated_score_quad_octa_2.o
LIBTOOL-STATIC Release/cld-c.a
CXX(target) Release/obj.target/cld/src/constants.o
CXX(target) Release/obj.target/cld/src/cld.o
../src/cld.cc:10:12: error: no member named 'unexpected_handler' in namespace 'std'
using std::unexpected_handler;
~~~~~^
1 error generated.
make: *** [Release/obj.target/cld/src/cld.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/opt/homebrew/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack at ChildProcess.emit (node:events:390:28)
gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:290:12)
gyp ERR! System Darwin 20.6.0
gyp ERR! command "/opt/homebrew/Cellar/node/17.0.1/bin/node" "/opt/homebrew/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/lars/Documents/projects/node-cld
gyp ERR! node -v v17.0.1
gyp ERR! node-gyp -v v8.2.0
gyp ERR! not ok
npm ERR! code 1
npm ERR! path /Users/lars/Documents/projects/node-cld
npm ERR! command failed
npm ERR! command sh -c node-gyp rebuild
(Macbook Air M1, Macos 11.6 20G165, Xcode 13.1)
See also: #55
I'm a bit confused and looking for some clarity as to why the backward-incompatible version change was introduced as a minor version bump. I read through the other issue but I'm not clear on why it was closed.
Major version X (X.y.z | X > 0) MUST be incremented if any backwards incompatible changes are introduced to the public API. It MAY include minor and patch level changes. Patch and minor version MUST be reset to 0 when major version is incremented.
Is the current stance that dependency changes that require manual intervention are understood to be "backward compatible"? This broke the build for me and seems like a breaking change.
Thanks for your help!
Just some notes: this sort of issue is often called the diamond dependency problem and when it comes up in the semver repo the recommendation always seems to be "release breaking changes as a major version to avoid breaking builds".
There may be some context about node-cld that I'm missing, but I'd love to unbreak the build without having to only trust patch version bumps.
We are packaging our project with serverless, which uses Webpack.
The packaging fails for cld
with the following error:
ERROR in ../../cld/index.js 2:13-43 Module not found: Error: Can't resolve './build/Release/cld' in 'node_modules/cld'
Changing the way it is imported should fix the issue. Is it something that could be implemented?
Thank you!
Hello,
Is it possibile adding the end offset of language in chunks model, like this?
chunks: [ { name: 'ITALIAN', code: 'it', start: 0, end: 310, bytes: 170 }, { name: 'ENGLISH', code: 'it', start: 315, end: 670, bytes: 236 }, { name: 'ITALIAN', code: 'it', start: 675, end: 800, bytes: 257 } ]
Maybe update package with cld v3 can help you
Any plan to support the new neural network based CLD-3?
Recently, I have proposed a build without the Chromium dependency (static library only), and it seems it work now:
google/cld3#23
Thank you.
I noticed that the array of languages only ever returns one item. It would be cool if it would detect multiple languages and return all of them when typing mixed language content.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.