-
Notifications
You must be signed in to change notification settings - Fork 4
Description
[Environment]
- OS X 10.11.4 (El capitan)
- node -v v4.4.3
- mono --version
Mono JIT compiler version 4.4.0 (mono-4.4.0-branch/a3fabf1 Fri Apr 8 13:48:29 EDT 2016)
Copyright (C) 2002-2014 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com
TLS: normal
SIGSEGV: altstack
Notification: kqueue
Architecture: x86
Disabled: none
Misc: softdebug
LLVM: yes(3.6.0svn-mono-master/a173357)
GC: sgen
I'm following the installation guid step by step.
Clone the git repositories and executed
$npm install.
Then, the error message is
Installing MacOS dependencies 2/3: Mono64. This might take a while.
Error: Command failed: /bin/sh -c brew install https://raw.githubusercontent.com/tjanczuk/edge/master/tools/mono64.rb
Error: Failure while executing: /usr/bin/curl -f#LA Homebrew/0.9.9\ (Macintosh;\ Intel\ Mac\ OS\ X\ 10.11.3)\ curl/7.43.0 https://raw.githubusercontent.com/tjanczuk/edge/master/tools/mono64.rb -o /Library/Caches/Homebrew/Formula/mono64.rb --silent
I found that loopback-sdk-generator needs mono64, and the brew install link in the install script is broken. So I installed mono64 by official homepage.
http://www.mono-project.com/download/ -> Download Mono Universal Installer
After install mono64(Wait. when I command mono --version, its architecture shows x86, not x64.Is this important?) I execute the lb-xm command
$ node bin/lb-xm /path/to/server/script
Then the error message is
Error: The edge native module is not available at /Users/HiChoi/dev/loopback.io/loopback-sdk-xamarin/node_modules/edge/build/Release/edge.node. You can use EDGE_NATIVE environment variable to provide alternate location of edge.node. If you need to build edge.node, follow build instructions for your platform at https://github.com/tjanczuk/edge
at Object.<anonymous> (/Users/HiChoi/dev/loopback.io/loopback-sdk-xamarin/node_modules/edge/lib/edge.js:34:11)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Module.require (module.js:353:17)
at require (internal/module.js:12:17)
at Object.<anonymous> (/Users/HiChoi/dev/loopback.io/loopback-sdk-xamarin/bin/lb-xm.js:9:12)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
I followed the edge build guide from https://github.com/tjanczuk/edge.
$npm install edge -> Error
No package 'mono-2' found
gyp: Call to 'pkg-config mono-2 --libs' returned exit status 1 while in binding.gyp. while trying to load binding.gyp
I searched the problem and it needs to set path PKG_CONFIG_PATH. So I executed
$export PKG_CONFIG_PATH=/Library/Frameworks/Mono.framework/Versions/Current/lib/pkgconfig
And then, again
$npm install edge -> Error
CXX(target) Release/obj.target/edge/src/mono/clractioncontext.o
In file included from ../src/mono/clractioncontext.cpp:1:
In file included from ../src/mono/edge.h:4:
In file included from ../src/mono/../common/edge_common.h:8:
../node_modules/nan/nan.h:324:27: error: redefinition of 'NanEnsureHandleOrPersistent'
NAN_INLINE v8::Local<T> NanEnsureHandleOrPersistent(const v8::Local<T> &val) {
^
../node_modules/nan/nan.h:319:17: note: previous definition is here
v8::Handle<T> NanEnsureHandleOrPersistent(const v8::Handle<T> &val) {
^
../node_modules/nan/nan.h:344:27: error: redefinition of 'NanEnsureLocal'
NAN_INLINE v8::Local<T> NanEnsureLocal(const v8::Handle<T> &val) {
^
../node_modules/nan/nan.h:334:27: note: previous definition is here
NAN_INLINE v8::Local<T> NanEnsureLocal(const v8::Local<T> &val) {
^
../node_modules/nan/nan.h:757:13: error: no member named 'smalloc' in namespace 'node'
, node::smalloc::FreeCallback callback
~~~~~~^
../node_modules/nan/nan.h:768:12: error: no matching function for call to 'New'
return node::Buffer::New(v8::Isolate::GetCurrent(), data, size);
^~~~~~~~~~~~~~~~~
/Users/HiChoi/.node-gyp/4.4.3/include/node/node_buffer.h:31:40: note: candidate function not viable: no known conversion from
'uint32_t' (aka 'unsigned int') to 'enum encoding' for 3rd argument
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/Users/HiChoi/.node-gyp/4.4.3/include/node/node_buffer.h:43:40: note: candidate function not viable: 2nd argument
('const char *') would lose const qualifier
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/Users/HiChoi/.node-gyp/4.4.3/include/node/node_buffer.h:28:40: note: candidate function not viable: requires 2 arguments, but 3
were provided
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate, size_t length);
^
/Users/HiChoi/.node-gyp/4.4.3/include/node/node_buffer.h:36:40: note: candidate function not viable: requires 5 arguments, but 3
were provided
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
In file included from ../src/mono/clractioncontext.cpp:1:
In file included from ../src/mono/edge.h:4:
In file included from ../src/mono/../common/edge_common.h:8:
../node_modules/nan/nan.h:772:12: error: no viable conversion from returned value of type 'v8::MaybeLocal<v8::Object>' to
function return type 'v8::Local<v8::Object>'
return node::Buffer::New(v8::Isolate::GetCurrent(), size);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/HiChoi/.node-gyp/4.4.3/include/node/v8.h:210:7: note: candidate constructor (the implicit copy constructor) not viable: no
known conversion from 'v8::MaybeLocal<v8::Object>' to 'const v8::Local<v8::Object> &' for 1st argument
class Local {
^
/Users/HiChoi/.node-gyp/4.4.3/include/node/v8.h:210:7: note: candidate constructor (the implicit move constructor) not viable: no
known conversion from 'v8::MaybeLocal<v8::Object>' to 'v8::Local<v8::Object> &&' for 1st argument
/Users/HiChoi/.node-gyp/4.4.3/include/node/v8.h:214:13: note: candidate template ignored: could not match 'Local' against
'MaybeLocal'
V8_INLINE Local(Local<S> that)
^
/Users/HiChoi/.node-gyp/4.4.3/include/node/v8.h:326:13: note: candidate template ignored: could not match 'S *' against
'v8::MaybeLocal<v8::Object>'
V8_INLINE Local(S* that)
^
In file included from ../src/mono/clractioncontext.cpp:1:
In file included from ../src/mono/edge.h:4:
In file included from ../src/mono/../common/edge_common.h:8:
../node_modules/nan/nan.h:779:26: error: no member named 'Use' in namespace 'node::Buffer'
return node::Buffer::Use(v8::Isolate::GetCurrent(), data, size);
~~~~~~~~~~~~~~^
In file included from ../src/mono/clractioncontext.cpp:1:
In file included from ../src/mono/edge.h:4:
In file included from ../src/mono/../common/edge_common.h:4:
/Users/HiChoi/.node-gyp/4.4.3/include/node/v8.h:221:5: error: assigning to 'v8::Primitive *volatile' from incompatible type
'v8::Value *'
TYPE_CHECK(T, S);
^~~~~~~~~~~~~~~~
/Users/HiChoi/.node-gyp/4.4.3/include/node/v8.h:180:37: note: expanded from macro 'TYPE_CHECK'
*(static_cast<T* volatile*>(0)) = static_cast<S*>(0); \
^ ~~~~~~~~~~~~~~~~~~
../node_modules/nan/nan.h:501:12: note: in instantiation of function template specialization
'v8::Local<v8::Primitive>::Local<v8::Value>' requested here
return NanEscapeScope(NanNew(v8::Undefined(v8::Isolate::GetCurrent())));
^
../node_modules/nan/nan.h:483:30: note: expanded from macro 'NanEscapeScope'
# define NanEscapeScope(val) scope.Escape(Nan::imp::NanEnsureLocal(val))
^
In file included from ../src/mono/clractioncontext.cpp:1:
In file included from ../src/mono/edge.h:4:
In file included from ../src/mono/../common/edge_common.h:4:
/Users/HiChoi/.node-gyp/4.4.3/include/node/v8.h:221:5: error: assigning to 'v8::Boolean *volatile' from incompatible type
'v8::Value *'
TYPE_CHECK(T, S);
^~~~~~~~~~~~~~~~
/Users/HiChoi/.node-gyp/4.4.3/include/node/v8.h:180:37: note: expanded from macro 'TYPE_CHECK'
*(static_cast<T* volatile*>(0)) = static_cast<S*>(0); \
^ ~~~~~~~~~~~~~~~~~~
../node_modules/nan/nan.h:511:12: note: in instantiation of function template specialization
'v8::Local<v8::Boolean>::Local<v8::Value>' requested here
return NanEscapeScope(NanNew(v8::True(v8::Isolate::GetCurrent())));
^
../node_modules/nan/nan.h:483:30: note: expanded from macro 'NanEscapeScope'
# define NanEscapeScope(val) scope.Escape(Nan::imp::NanEnsureLocal(val))
^
In file included from ../src/mono/clractioncontext.cpp:1:
In file included from ../src/mono/edge.h:4:
In file included from ../src/mono/../common/edge_common.h:4:
/Users/HiChoi/.node-gyp/4.4.3/include/node/v8.h:221:5: error: assigning to 'v8::Function *volatile' from incompatible type
'v8::Value *'
TYPE_CHECK(T, S);
^~~~~~~~~~~~~~~~
/Users/HiChoi/.node-gyp/4.4.3/include/node/v8.h:180:37: note: expanded from macro 'TYPE_CHECK'
*(static_cast<T* volatile*>(0)) = static_cast<S*>(0); \
^ ~~~~~~~~~~~~~~~~~~
../node_modules/nan/nan.h:1645:12: note: in instantiation of function template specialization
'v8::Local<v8::Function>::Local<v8::Value>' requested here
return NanEscapeScope(NanNew(handle)->Get(kCallbackIndex)
^
../node_modules/nan/nan.h:483:30: note: expanded from macro 'NanEscapeScope'
# define NanEscapeScope(val) scope.Escape(Nan::imp::NanEnsureLocal(val))
^
In file included from ../src/mono/clractioncontext.cpp:1:
In file included from ../src/mono/edge.h:4:
In file included from ../src/mono/../common/edge_common.h:4:
/Users/HiChoi/.node-gyp/4.4.3/include/node/v8.h:221:5: error: assigning to 'v8::Object *volatile' from incompatible type
'v8::Value *'
TYPE_CHECK(T, S);
^~~~~~~~~~~~~~~~
/Users/HiChoi/.node-gyp/4.4.3/include/node/v8.h:180:37: note: expanded from macro 'TYPE_CHECK'
*(static_cast<T* volatile*>(0)) = static_cast<S*>(0); \
^ ~~~~~~~~~~~~~~~~~~
../node_modules/nan/nan.h:1776:12: note: in instantiation of function template specialization
'v8::Local<v8::Object>::Local<v8::Value>' requested here
return NanEscapeScope(
^
../node_modules/nan/nan.h:483:30: note: expanded from macro 'NanEscapeScope'
# define NanEscapeScope(val) scope.Escape(Nan::imp::NanEnsureLocal(val))
^
10 errors generated.
make: *** [Release/obj.target/edge/src/mono/clractioncontext.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/Users/HiChoi/.nvm/versions/node/v4.4.3/lib/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 Darwin 15.3.0
gyp ERR! command "/Users/HiChoi/.nvm/versions/node/v4.4.3/bin/node" "/Users/HiChoi/.nvm/versions/node/v4.4.3/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "configure" "build"
gyp ERR! cwd /Users/HiChoi/dev/loopback.io/loopback-sdk-xamarin/node_modules/edge
gyp ERR! node -v v4.4.3
gyp ERR! node-gyp -v v3.3.1
gyp ERR! not ok
[email protected] node_modules/edge
├── [email protected]
└── [email protected]
I totally lost the way at this stage. What's the problem?