Skip to content

Instantly share code, notes, and snippets.

@tfnico

tfnico/log Secret

Created February 10, 2014 13:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tfnico/97e935548650ef4a488b to your computer and use it in GitHub Desktop.
Save tfnico/97e935548650ef4a488b to your computer and use it in GitHub Desktop.
Building git-watcher on OSX
OS X 10.8.5
node v0.10.23
npm 1.3.17
History and error:
git clone https://github.com/demian85/git-watcher.git
cd git-watcher
npm install
mv ~/Downloads/node-webkit-v0.9.0-osx-ia32 ~/dev
sudo ln -s ~/dev/node-webkit-v0.9.0-osx-ia32 /opt/node-webkit
npm install -g nw-gyp
cd node_modules/git-utils && nw-gyp rebuild --target=0.9.0
cd ..
cd mmmagic
nw-gyp rebuild --target=0.9.0
nw-gyp rebuild --target=0.9.0
gyp info it worked if it ends with ok
gyp info using nw-gyp@0.12.2
gyp info using node@0.10.23 | darwin | x64
gyp info spawn python
gyp info spawn args [ '/usr/local/share/npm/lib/node_modules/nw-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/tfnico/projects/git-watcher/node_modules/mmmagic/build/config.gypi',
gyp info spawn args '-I',
gyp info spawn args '/usr/local/share/npm/lib/node_modules/nw-gyp/addon.gypi',
gyp info spawn args '-I',
gyp info spawn args '/Users/tfnico/.nw-gyp/0.9.0/common.gypi',
gyp info spawn args '-Dlibrary=shared_library',
gyp info spawn args '-Dvisibility=default',
gyp info spawn args '-Dnode_root_dir=/Users/tfnico/.nw-gyp/0.9.0',
gyp info spawn args '-Dmodule_root_dir=/Users/tfnico/projects/git-watcher/node_modules/mmmagic',
gyp info spawn args '--depth=.',
gyp info spawn args '--generator-output',
gyp info spawn args 'build',
gyp info spawn args '-Goutput_dir=.' ]
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
CC(target) Release/obj.target/libmagic/deps/libmagic/src/apprentice.o
CC(target) Release/obj.target/libmagic/deps/libmagic/src/apptype.o
CC(target) Release/obj.target/libmagic/deps/libmagic/src/ascmagic.o
CC(target) Release/obj.target/libmagic/deps/libmagic/src/cdf.o
../deps/libmagic/src/cdf.c:299:6: warning: implicit declaration of function 'pread' is invalid in C99 [-Wimplicit-function-declaration]
if (pread(info->i_fd, buf, len, off) != (ssize_t)len)
^
1 warning generated.
CC(target) Release/obj.target/libmagic/deps/libmagic/src/cdf_time.o
CC(target) Release/obj.target/libmagic/deps/libmagic/src/compress.o
CC(target) Release/obj.target/libmagic/deps/libmagic/src/encoding.o
CC(target) Release/obj.target/libmagic/deps/libmagic/src/fsmagic.o
CC(target) Release/obj.target/libmagic/deps/libmagic/src/funcs.o
CC(target) Release/obj.target/libmagic/deps/libmagic/src/is_tar.o
CC(target) Release/obj.target/libmagic/deps/libmagic/src/magic.o
../deps/libmagic/src/magic.c:491:9: warning: incompatible pointer to integer conversion returning 'char [7]' from a function with result type 'int' [-Wint-conversion]
return MAGIC_VERSION;
^~~~~~~~~~~~~
../deps/libmagic/src/magic.h:77:24: note: expanded from macro 'MAGIC_VERSION'
#define MAGIC_VERSION "5.12.1" /* This implementation */
^~~~~~~~
1 warning generated.
CC(target) Release/obj.target/libmagic/deps/libmagic/src/print.o
CC(target) Release/obj.target/libmagic/deps/libmagic/src/readcdf.o
CC(target) Release/obj.target/libmagic/deps/libmagic/src/readelf.o
CC(target) Release/obj.target/libmagic/deps/libmagic/src/softmagic.o
LIBTOOL-STATIC Release/magic.a
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_byte_order.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_chartables.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_compile.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_config.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_dfa_exec.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_exec.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_fullinfo.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_get.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_globals.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_jit_compile.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_maketables.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_newline.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_ord2utf8.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_refcount.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_string_utils.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_study.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_tables.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_ucd.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_valid_utf8.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_version.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcre_xclass.o
CC(target) Release/obj.target/libpcre/deps/libmagic/pcre/pcreposix.o
LIBTOOL-STATIC Release/pcre.a
CXX(target) Release/obj.target/magic/src/magic.o
../src/magic.cc:32:22: error: expected class name
class Magic : public ObjectWrap {
^
../src/magic.cc:96:12: error: no member named 'Wrap' in 'Magic'
obj->Wrap(args.This());
~~~ ^
../src/magic.cc:97:12: error: no member named 'Ref' in 'Magic'
obj->Ref();
~~~ ^
../src/magic.cc:104:20: error: use of undeclared identifier 'ObjectWrap'
Magic* obj = ObjectWrap::Unwrap<Magic>(args.This());
^
../src/magic.cc:104:39: error: 'Magic' does not refer to a value
Magic* obj = ObjectWrap::Unwrap<Magic>(args.This());
^
../src/magic.cc:32:7: note: declared here
class Magic : public ObjectWrap {
^
../src/magic.cc:141:20: error: use of undeclared identifier 'ObjectWrap'
Magic* obj = ObjectWrap::Unwrap<Magic>(args.This());
^
../src/magic.cc:141:39: error: 'Magic' does not refer to a value
Magic* obj = ObjectWrap::Unwrap<Magic>(args.This());
^
../src/magic.cc:32:7: note: declared here
class Magic : public ObjectWrap {
^
../src/magic.cc:191:41: error: use of undeclared identifier 'uv_last_error'; did you mean 'uv_strerror'?
uv_last_error(uv_default_loop())));
^~~~~~~~~~~~~
uv_strerror
/Users/tfnico/.nw-gyp/0.9.0/src/../deps/uv/include/uv.h:452:23: note: 'uv_strerror' declared here
UV_EXTERN const char* uv_strerror(int err);
^
../src/magic.cc:191:55: error: cannot initialize a parameter of type 'int' with an rvalue of type 'uv_loop_t *' (aka 'uv_loop_s *')
uv_last_error(uv_default_loop())));
^~~~~~~~~~~~~~~~~
/Users/tfnico/.nw-gyp/0.9.0/src/../deps/uv/include/uv.h:452:39: note: passing argument to parameter 'err' here
UV_EXTERN const char* uv_strerror(int err);
^
../src/magic.cc:240:11: error: no matching function for call to 'New'
Local<Value>::New(Null()),
^~~~~~~~~~~~~~~~~
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:384:29: note: candidate function template not viable: requires 2 arguments, but 1 was provided
V8_INLINE static Local<T> New(Isolate* isolate,
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:382:29: note: candidate function not viable: requires 2 arguments, but 1 was provided
V8_INLINE static Local<T> New(Isolate* isolate, Handle<T> that);
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:407:29: note: candidate function not viable: requires 2 arguments, but 1 was provided
V8_INLINE static Local<T> New(Isolate* isolate, T* that);
^
../src/magic.cc:241:11: error: no matching function for call to 'New'
Local<Value>::New(baton->result
^~~~~~~~~~~~~~~~~
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:384:29: note: candidate function template not viable: requires 2 arguments, but 1 was provided
V8_INLINE static Local<T> New(Isolate* isolate,
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:382:29: note: candidate function not viable: requires 2 arguments, but 1 was provided
V8_INLINE static Local<T> New(Isolate* isolate, Handle<T> that);
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:407:29: note: candidate function not viable: requires 2 arguments, but 1 was provided
V8_INLINE static Local<T> New(Isolate* isolate, T* that);
^
../src/magic.cc:280:59: error: cannot initialize a parameter of type 'FunctionCallback' (aka 'void (*)(const FunctionCallbackInfo<v8::Value> &)') with an lvalue of type 'Handle<v8::Value> (const v8::Arguments &)': type mismatch at 1st parameter ('const FunctionCallbackInfo<v8::Value> &' vs 'const v8::Arguments &')
Local<FunctionTemplate> tpl = FunctionTemplate::New(New);
^~~
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:3379:24: note: passing argument to parameter 'callback' here
FunctionCallback callback = 0,
^
../src/magic.cc:287:33: error: no viable conversion from 'Persistent<v8::FunctionTemplate>' to 'v8::Handle<v8::FunctionTemplate>'
NODE_SET_PROTOTYPE_METHOD(constructor, "detectFile", DetectFile);
^~~~~~~~~~~
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:211:26: note: candidate constructor (the implicit copy constructor) not viable: no known conversion from 'Persistent<v8::FunctionTemplate>' to 'const v8::Handle<v8::FunctionTemplate> &' for 1st argument
template <class T> class Handle {
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:228:32: note: candidate template ignored: failed template argument deduction
template <class S> V8_INLINE Handle(Handle<S> that)
^
/Users/tfnico/.nw-gyp/0.9.0/src/node.h:185:72: note: passing argument to parameter 'recv' here
inline void NODE_SET_PROTOTYPE_METHOD(v8::Handle<v8::FunctionTemplate> recv,
^
../src/magic.cc:288:33: error: no viable conversion from 'Persistent<v8::FunctionTemplate>' to 'v8::Handle<v8::FunctionTemplate>'
NODE_SET_PROTOTYPE_METHOD(constructor, "detect", Detect);
^~~~~~~~~~~
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:211:26: note: candidate constructor (the implicit copy constructor) not viable: no known conversion from 'Persistent<v8::FunctionTemplate>' to 'const v8::Handle<v8::FunctionTemplate> &' for 1st argument
template <class T> class Handle {
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:228:32: note: candidate template ignored: failed template argument deduction
template <class S> V8_INLINE Handle(Handle<S> that)
^
/Users/tfnico/.nw-gyp/0.9.0/src/node.h:185:72: note: passing argument to parameter 'recv' here
inline void NODE_SET_PROTOTYPE_METHOD(v8::Handle<v8::FunctionTemplate> recv,
^
../src/magic.cc:290:31: error: cannot initialize a parameter of type 'FunctionCallback' (aka 'void (*)(const FunctionCallbackInfo<v8::Value> &)') with an lvalue of type 'Handle<v8::Value> (const v8::Arguments &)': type mismatch at 1st parameter ('const FunctionCallbackInfo<v8::Value> &' vs 'const v8::Arguments &')
FunctionTemplate::New(SetFallback)->GetFunction());
^~~~~~~~~~~
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:3379:24: note: passing argument to parameter 'callback' here
FunctionCallback callback = 0,
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:481:5: error: assigning to 'v8::Object *volatile' from incompatible type 'v8::Primitive *'
TYPE_CHECK(O, Primitive);
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:182:37: note: expanded from macro 'TYPE_CHECK'
*(static_cast<T* volatile*>(0)) = static_cast<S*>(0); \
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:477:5: note: in instantiation of function template specialization 'v8::NonCopyablePersistentTraits<v8::Function>::Uncompilable<v8::Object>' requested here
Uncompilable<Object>();
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:5683:6: note: in instantiation of function template specialization 'v8::NonCopyablePersistentTraits<v8::Function>::Copy<v8::Function, v8::NonCopyablePersistentTraits<v8::Function> >' requested here
M::Copy(that, this);
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:550:5: note: in instantiation of function template specialization 'v8::Persistent<v8::Function, v8::NonCopyablePersistentTraits<v8::Function> >::Copy<v8::Function, v8::NonCopyablePersistentTraits<v8::Function> >' requested here
Copy(that);
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:5650:3: note: in instantiation of member function 'v8::Persistent<v8::Function, v8::NonCopyablePersistentTraits<v8::Function> >::Persistent' requested here
return New(Isolate::GetCurrent(), that.val_);
^
../src/magic.cc:123:25: note: in instantiation of function template specialization 'v8::Persistent<v8::Function, v8::NonCopyablePersistentTraits<v8::Function> >::New<v8::Function>' requested here
baton->callback = Persistent<Function>::New(callback);
^
In file included from ../src/magic.cc:1:
In file included from /Users/tfnico/.nw-gyp/0.9.0/src/node.h:76:
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:481:5: error: assigning to 'v8::Object *volatile' from incompatible type 'v8::Primitive *'
TYPE_CHECK(O, Primitive);
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:182:37: note: expanded from macro 'TYPE_CHECK'
*(static_cast<T* volatile*>(0)) = static_cast<S*>(0); \
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:477:5: note: in instantiation of function template specialization 'v8::NonCopyablePersistentTraits<v8::FunctionTemplate>::Uncompilable<v8::Object>' requested here
Uncompilable<Object>();
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:5683:6: note: in instantiation of function template specialization 'v8::NonCopyablePersistentTraits<v8::FunctionTemplate>::Copy<v8::FunctionTemplate, v8::NonCopyablePersistentTraits<v8::FunctionTemplate> >' requested here
M::Copy(that, this);
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:550:5: note: in instantiation of function template specialization 'v8::Persistent<v8::FunctionTemplate, v8::NonCopyablePersistentTraits<v8::FunctionTemplate> >::Copy<v8::FunctionTemplate, v8::NonCopyablePersistentTraits<v8::FunctionTemplate> >' requested here
Copy(that);
^
/Users/tfnico/.nw-gyp/0.9.0/deps/v8/include/v8.h:5650:3: note: in instantiation of member function 'v8::Persistent<v8::FunctionTemplate, v8::NonCopyablePersistentTraits<v8::FunctionTemplate> >::Persistent' requested here
return New(Isolate::GetCurrent(), that.val_);
^
../src/magic.cc:283:21: note: in instantiation of function template specialization 'v8::Persistent<v8::FunctionTemplate, v8::NonCopyablePersistentTraits<v8::FunctionTemplate> >::New<v8::FunctionTemplate>' requested here
constructor = Persistent<FunctionTemplate>::New(tpl);
^
17 errors generated.
make: *** [Release/obj.target/magic/src/magic.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/share/npm/lib/node_modules/nw-gyp/lib/build.js:267:23)
gyp ERR! stack at ChildProcess.EventEmitter.emit (events.js:98:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:789:12)
gyp ERR! System Darwin 12.5.0
gyp ERR! command "node" "/usr/local/share/npm/bin/nw-gyp" "rebuild" "--target=0.9.0"
gyp ERR! cwd /Users/tfnico/projects/git-watcher/node_modules/mmmagic
gyp ERR! node -v v0.10.23
gyp ERR! nw-gyp -v v0.12.2
gyp ERR! not ok
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment