{"action":"created","issue":{"url":"https://api.github.com/repos/NativeScript/nativescript-cli/issues/963","labels_url":"https://api.github.com/repos/NativeScript/nativescript-cli/issues/963/labels{/name}","comments_url":"https://api.github.com/repos/NativeScript/nativescript-cli/issues/963/comments","events_url":"https://api.github.com/repos/NativeScript/nativescript-cli/issues/963/events","html_url":"https://github.com/NativeScript/nativescript-cli/issues/963","id":108273323,"number":963,"title":"Nativescript 1.3.0 installation issue in linux (Debian)","user":{"login":"enchev","id":5804953,"avatar_url":"https://avatars.githubusercontent.com/u/5804953?v=3","gravatar_id":"","url":"https://api.github.com/users/enchev","html_url":"https://github.com/enchev","followers_url":"https://api.github.com/users/enchev/followers","following_url":"https://api.github.com/users/enchev/following{/other_user}","gists_url":"https://api.github.com/users/enchev/gists{/gist_id}","starred_url":"https://api.github.com/users/enchev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/enchev/subscriptions","organizations_url":"https://api.github.com/users/enchev/orgs","repos_url":"https://api.github.com/users/enchev/repos","events_url":"https://api.github.com/users/enchev/events{/privacy}","received_events_url":"https://api.github.com/users/enchev/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-09-25T06:46:12Z","updated_at":"2015-09-25T06:48:28Z","closed_at":null,"body":"_From @paragasu on September 25, 2015 5:15_\n\nI been following the instruction http://docs.nativescript.org/setup/ns-cli-setup/ns-setup-linux.html\r\nIt failed on both my laptop and desktop computer.\r\n\r\nHere is the output of npm install -g nativescript --unsafe-perm\r\n\r\n```\r\nmake: Entering directory '/usr/local/lib/node_modules/nativescript/node_modules/ffi/build'\r\n  CC(target) Release/obj.target/ffi/deps/libffi/src/prep_cif.o\r\n  CC(target) Release/obj.target/ffi/deps/libffi/src/types.o\r\n  CC(target) Release/obj.target/ffi/deps/libffi/src/raw_api.o\r\n  CC(target) Release/obj.target/ffi/deps/libffi/src/java_raw_api.o\r\n  CC(target) Release/obj.target/ffi/deps/libffi/src/closures.o\r\n  CC(target) Release/obj.target/ffi/deps/libffi/src/x86/ffi.o\r\n  CC(target) Release/obj.target/ffi/deps/libffi/src/x86/ffi64.o\r\n../deps/libffi/src/x86/ffi64.c: In function ‘classify_argument’:\r\n../deps/libffi/src/x86/ffi64.c:181:18: warning: suggest braces around empty body in an ‘else’ statement [-Wempty-body]\r\n    FFI_ASSERT (0);\r\n                  ^\r\n  CC(target) Release/obj.target/ffi/deps/libffi/src/x86/unix64.o\r\n  CC(target) Release/obj.target/ffi/deps/libffi/src/x86/sysv.o\r\n  AR(target) Release/obj.target/deps/libffi/libffi.a\r\n  COPY Release/libffi.a\r\n  CXX(target) Release/obj.target/ffi_bindings/src/ffi.o\r\n  CXX(target) Release/obj.target/ffi_bindings/src/callback_info.o\r\nIn file included from ../src/callback_info.cc:8:0:\r\n../src/callback_info.cc: In static member function ‘static v8::Handle<v8::Value> CallbackInfo::Callback(const v8::Arguments&)’:\r\n../src/ffi.h:25:72: warning: ‘v8::Local<v8::Value> NanThrowError(const char*, int)’ is deprecated [-Wdeprecated-declarations]\r\n #define THROW_ERROR_EXCEPTION_WITH_STATUS_CODE(x, y) NanThrowError(x, y)\r\n                                                                        ^\r\n../src/callback_info.cc:139:12: note: in expansion of macro ‘THROW_ERROR_EXCEPTION_WITH_STATUS_CODE’\r\n     return THROW_ERROR_EXCEPTION_WITH_STATUS_CODE(\"ffi_prep_closure() Returned Error\", status);\r\n            ^\r\nIn file included from ../src/ffi.h:18:0,\r\n                 from ../src/callback_info.cc:8:\r\n../node_modules/nan/nan.h:1290:50: note: declared here\r\n   NAN_DEPRECATED NAN_INLINE v8::Local<v8::Value> NanThrowError(\r\n                                                  ^\r\n  CXX(target) Release/obj.target/ffi_bindings/src/threaded_callback_invokation.o\r\n  SOLINK_MODULE(target) Release/obj.target/ffi_bindings.node\r\n  COPY Release/ffi_bindings.node\r\nmake: Leaving directory '/usr/local/lib/node_modules/nativescript/node_modules/ffi/build'\r\nInstalled in `/usr/local/lib/node_modules/nativescript/node_modules/ffi/bin/linux-x64-v8-3.14/ffi_bindings.node`\r\nnpm WARN excluding symbolic link docs/stylesheets/hightlight.css -> ../../node_modules/highlight.js/src/styles/solarized_light.css\r\nnpm WARN excluding symbolic link docs/stylesheets/hightlight.css -> ../../node_modules/highlight.js/src/styles/solarized_light.css\r\n \r\n> ref@1.1.0 install /usr/local/lib/node_modules/nativescript/node_modules/ios-sim-portable/node_modules/NodObjC/node_modules/ref\r\n> node ./build.js\r\n\r\nmake: Entering directory '/usr/local/lib/node_modules/nativescript/node_modules/ios-sim-portable/node_modules/NodObjC/node_modules/ref/build'\r\n  CXX(target) Release/obj.target/binding/src/binding.o\r\nIn file included from ../src/binding.cc:8:0:\r\n../node_modules/nan/nan.h:316:47: error: ‘REPLACE_INVALID_UTF8’ is not a member of ‘v8::String’\r\n   static const unsigned kReplaceInvalidUtf8 = v8::String::REPLACE_INVALID_UTF8;\r\n                                               ^\r\nbinding.target.mk:88: recipe for target 'Release/obj.target/binding/src/binding.o' failed\r\nmake: *** [Release/obj.target/binding/src/binding.o] Error 1\r\nmake: Leaving directory '/usr/local/lib/node_modules/nativescript/node_modules/ios-sim-portable/node_modules/NodObjC/node_modules/ref/build'\r\ngyp ERR! build error \r\ngyp ERR! stack Error: `make` failed with exit code: 2\r\ngyp ERR! stack     at ChildProcess.onExit (/usr/share/node-gyp/lib/build.js:270:23)\r\ngyp ERR! stack     at ChildProcess.emit (events.js:98:17)\r\ngyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:820:12)\r\ngyp ERR! System Linux 3.16.0-4-amd64\r\ngyp ERR! command \"nodejs\" \"/usr/bin/node-gyp\" \"rebuild\"\r\ngyp ERR! cwd /usr/local/lib/node_modules/nativescript/node_modules/ios-sim-portable/node_modules/NodObjC/node_modules/ref\r\ngyp ERR! node -v v0.10.38\r\ngyp ERR! node-gyp -v v3.0.1\r\ngyp ERR! not ok \r\nBuild failed\r\nnpm WARN This failure might be due to the use of legacy binary \"node\"\r\nnpm WARN For further explanations, please read\r\n/usr/share/doc/nodejs/README.Debian\r\n \r\n \r\n> nativescript@1.3.0 preuninstall /usr/local/lib/node_modules/nativescript\r\n> node preuninstall.js\r\n\r\nTrying to kill adb server. Some running Android related operations may fail.\r\nnpm ERR! ref@1.1.0 install: `node ./build.js`\r\nnpm ERR! Exit status 1\r\nnpm ERR! \r\nnpm ERR! Failed at the ref@1.1.0 install script.\r\nnpm ERR! This is most likely a problem with the ref package,\r\nnpm ERR! not with npm itself.\r\nnpm ERR! Tell the author that this fails on your system:\r\nnpm ERR!     node ./build.js\r\nnpm ERR! You can get their info via:\r\nnpm ERR!     npm owner ls ref\r\nnpm ERR! There is likely additional logging output above.\r\n\r\nnpm ERR! System Linux 3.16.0-4-amd64\r\nnpm ERR! command \"/usr/bin/nodejs\" \"/usr/bin/npm\" \"install\" \"-g\" \"nativescript\" \"--unsafe-perm\"\r\nnpm ERR! cwd /etc/profile.d\r\nnpm ERR! node -v v0.10.38\r\nnpm ERR! npm -v 1.4.21\r\nnpm ERR! code ELIFECYCLE\r\nnpm WARN excluding symbolic link docs/stylesheets/hightlight.css -> ../../node_modules/highlight.js/src/styles/solarized_light.css\r\n\r\n> ffi@1.3.2 install /usr/local/lib/node_modules/nativescript/node_modules/ios-sim-portable/node_modules/NodObjC/node_modules/ffi\r\n> node ./build.js\r\n\r\n\r\nmodule.js:340\r\n    throw err;\r\n          ^\r\nError: Cannot find module '/usr/local/lib/node_modules/nativescript/node_modules/ios-sim-portable/node_modules/NodObjC/node_modules/ffi/build.js'\r\n    at Function.Module._resolveFilename (module.js:338:15)\r\n    at Function.Module._load (module.js:280:25)\r\n    at Function.Module.runMain (module.js:497:10)\r\n    at startup (node.js:119:16)\r\n    at node.js:906:3\r\nnpm WARN This failure might be due to the use of legacy binary \"node\"\r\nnpm WARN For further explanations, please read\r\n/usr/share/doc/nodejs/README.Debian\r\n \r\nnpm ERR! \r\nnpm ERR! Additional logging details can be found in:\r\nnpm ERR!     /etc/profile.d/npm-debug.log\r\nnpm ERR! not ok code 0\r\n```\r\n```\r\nroot@debian:/usr/bin# npm owner ls ref\r\ntootallnate <nathan@tootallnate.net>\r\n```\r\n\r\nInstalled package\r\ngradle 2.5\r\nnode v0.10.38\r\njava version \"1.8.0_60\"\r\n\r\n\n\n_Copied from original issue: NativeScript/NativeScript#824_"},"comment":{"url":"https://api.github.com/repos/NativeScript/nativescript-cli/issues/comments/143143957","html_url":"https://github.com/NativeScript/nativescript-cli/issues/963#issuecomment-143143957","issue_url":"https://api.github.com/repos/NativeScript/nativescript-cli/issues/963","id":143143957,"user":{"login":"hdeshev","id":63219,"avatar_url":"https://avatars.githubusercontent.com/u/63219?v=3","gravatar_id":"","url":"https://api.github.com/users/hdeshev","html_url":"https://github.com/hdeshev","followers_url":"https://api.github.com/users/hdeshev/followers","following_url":"https://api.github.com/users/hdeshev/following{/other_user}","gists_url":"https://api.github.com/users/hdeshev/gists{/gist_id}","starred_url":"https://api.github.com/users/hdeshev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hdeshev/subscriptions","organizations_url":"https://api.github.com/users/hdeshev/orgs","repos_url":"https://api.github.com/users/hdeshev/repos","events_url":"https://api.github.com/users/hdeshev/events{/privacy}","received_events_url":"https://api.github.com/users/hdeshev/received_events","type":"User","site_admin":false},"created_at":"2015-09-25T06:48:28Z","updated_at":"2015-09-25T06:48:28Z","body":"I looked around and [it turns out](https://github.com/nodejs/nan/issues/414) the nan library fails to build on certain Debian versions because their node headers lack the `REPLACE_INVALID_UTF8` macro. The issue I linked offers some workarounds."}}