MagicMirror² v2.8.0 is available! For more information about this release, check out this topic.

MMM-Hotword install failure



  • Has anyone else been getting these failures when installing Hotword?

    pi@raspberrypi:~/MagicMirror/modules/MMM-Hotword/snowboy $ npm install -y
    
    > snowboy@1.3.1 install /home/pi/MagicMirror/modules/MMM-Hotword/snowboy
    > node-pre-gyp install --fallback-to-build
    
    node-pre-gyp ERR! Tried to download(403): https://snowboy-release-node.s3-us-west-2.amazonaws.com/snowboy/v1.3.1/Release/snowboy-v1.3.1-node-v64-linux-arm.tar.gz 
    node-pre-gyp ERR! Pre-built binaries not found for snowboy@1.3.1 and node@10.16.3 (node-v64 ABI, glibc) (falling back to source compile with node-gyp) 
    node-pre-gyp ERR! Tried to download(undefined): https://snowboy-release-node.s3-us-west-2.amazonaws.com/snowboy/v1.3.1/Release/snowboy-v1.3.1-node-v64-linux-arm.tar.gz 
    node-pre-gyp ERR! Pre-built binaries not found for snowboy@1.3.1 and node@10.16.3 (node-v64 ABI, glibc) (falling back to source compile with node-gyp) 
    
    

  • Module Developer

    @Bestboy4
    If you are following the instructions of docs so you go till the end and get Rebuild complete message, you can ignore some errors possible. I prepared some brute-force fallback ways to cover them. If you are doing autoinstall, what is the last messages of installation?



  • @Sean Thanks for replying. The auto-install fails. Apparently electron fails the rebuild. here is capture of the messages after things go bad.

    + electron-rebuild@1.8.6
    removed 14 packages, updated 2 packages and audited 508 packages in 17.523s
    found 8 moderate severity vulnerabilities
      run `npm audit fix` to fix them, or `npm audit` for details
    ✖ Rebuild Failed
    
    An unhandled error occurred inside electron-rebuild
    gyp info it worked if it ends with ok
    gyp info using node-gyp@5.0.3
    gyp info using node@10.16.3 | linux | arm
    gyp info find Python using Python version 2.7.16 found at "/usr/bin/python"
    gyp info spawn /usr/bin/python
    gyp info spawn args [ '/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/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   '/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/build/config.gypi',
    gyp info spawn args   '-I',
    gyp info spawn args   '/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/node-gyp/addon.gypi',
    gyp info spawn args   '-I',
    gyp info spawn args   '/home/pi/.electron-gyp/iojs-3.1.10/common.gypi',
    gyp info spawn args   '-Dlibrary=shared_library',
    gyp info spawn args   '-Dvisibility=default',
    gyp info spawn args   '-Dnode_root_dir=/home/pi/.electron-gyp/iojs-3.1.10',
    gyp info spawn args   '-Dnode_gyp_dir=/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/node-gyp',
    gyp info spawn args   '-Dnode_lib_file=/home/pi/.electron-gyp/iojs-3.1.10/(AsyncExecuteComplete)
                                                                  ^
    ../swig/Node/snowboy.cc: In constructor ‘SnowboyDetect::SnowboyDetect(const string&, const string&)’:
    ../swig/Node/snowboy.cc:38:31: warning: catching polymorphic type ‘class std::runtime_error’ by value [-Wcatch-value=]
       } catch (std::runtime_error e) {
                                   ^
    In file included from ../node_modules/nan/nan.h:54,
                     from ../swig/Node/snowboy.cc:1:
    ../swig/Node/snowboy.cc: At global scope:
    /home/pi/.electron-gyp/iojs-3.1.10/src/node.h:442:43: warning: cast between incompatible function types from ‘void (*)(Nan::ADDON_REGISTER_FUNCTION_ARGS_TYPE)’ {aka ‘void (*)(v8::Local)’} to ‘node::addon_register_func’ {aka ‘void (*)(v8::Local, v8::Local, void*)’} [-Wcast-function-type]
           (node::addon_register_func) (regfunc),                          \
                                               ^
    /home/pi/.electron-gyp/iojs-3.1.10/src/node.h:476:3: note: in expansion of macro ‘NODE_MODULE_X’
       NODE_MODULE_X(modname, regfunc, NULL, 0)  // NOLINT (readability/null_usage)
       ^~~~~~~~~~~~~
    ../swig/Node/snowboy.cc:183:1: note: in expansion of macro ‘NODE_MODULE’
     NODE_MODULE(SnowboyDetect, SnowboyDetect::Init)
     ^~~~~~~~~~~
    In file included from /home/pi/.electron-gyp/iojs-3.1.10/src/node.h:54,
                     from ../node_modules/nan/nan.h:54,
                     from ../swig/Node/snowboy.cc:1:
    /home/pi/.electron-gyp/iojs-3.1.10/deps/v8/include/v8.h: In instantiation of ‘void v8::PersistentBase::SetWeak(P*, typename v8::WeakCallbackInfo<p>::Callback, v8::WeakCallbackType) [with P = node::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo</p><p>::Callback = void (*)(const v8::WeakCallbackInfo&)]’:
    /home/pi/.electron-gyp/iojs-3.1.10/src/node_object_wrap.h:85:78:   required from here
    /home/pi/.electron-gyp/iojs-3.1.10/deps/v8/include/v8.h:9256:16: warning: cast between incompatible function types from ‘v8::WeakCallbackInfo::Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo&)’} to ‘Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo&)’} [-Wcast-function-type]
                    reinterpret_cast(callback), type);
                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    /home/pi/.electron-gyp/iojs-3.1.10/deps/v8/include/v8.h: In instantiation of ‘void v8::PersistentBase::SetWeak(P*, typename v8::WeakCallbackInfo<p>::Callback, v8::WeakCallbackType) [with P = Nan::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo</p><p>::Callback = void (*)(const v8::WeakCallbackInfo&)]’:
    ../node_modules/nan/nan_object_wrap.h:65:61:   required from here
    /home/pi/.electron-gyp/iojs-3.1.10/deps/v8/include/v8.h:9256:16: warning: cast between incompatible function types from ‘v8::WeakCallbackInfo::Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo&)’} to ‘Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo&)’} [-Wcast-function-type]
      SOLINK_MODULE(target) Release/obj.target/snowboy.node
    /usr/bin/ld: cannot find -lcblas
    collect2: error: ld returned 1 exit status
    make: *** [snowboy.target.mk:137: Release/obj.target/snowboy.node] Error 1
    make: Leaving directory '/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/build'
    gyp ERR! build error 
    gyp ERR! stack Error: `make` failed with exit code: 2
    gyp ERR! stack     at ChildProcess.onExit (/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/node-gyp/lib/build.js:196:23)
    gyp ERR! stack     at ChildProcess.emit (events.js:198:13)
    gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:248:12)
    gyp ERR! System Linux 4.19.58-v7+
    gyp ERR! command "/usr/bin/node" "/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/.bin/node-gyp" "rebuild" "--target=3.1.10" "--arch=arm" "--dist-url=https://electronjs.org/headers" "--build-from-source" "--module_name=snowboy" "--module_path=/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/lib/node/binding/Release/electron-v3.1-linux-arm" "--remote_path=./snowboy/v1.3.1/Release/" "--package_name=snowboy-v1.3.1-electron-v3.1-linux-arm.tar.gz" "--host=https://snowboy-release-node.s3-us-west-2.amazonaws.com"
    gyp ERR! cwd /home/pi/MagicMirror/modules/MMM-Hotword/snowboy
    gyp ERR! node -v v10.16.3
    gyp ERR! node-gyp -v v5.0.3
    gyp ERR! not ok 
    
    Failed with exit code: 1
    
    Error: gyp info it worked if it ends with ok
    gyp info using node-gyp@5.0.3
    gyp info using node@10.16.3 | linux | arm
    gyp info find Python using Python version 2.7.16 found at "/usr/bin/python"
    gyp info spawn /usr/bin/python
    gyp info spawn args [ '/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/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   '/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/build/config.gypi',
    gyp info spawn args   '-I',
    gyp info spawn args   '/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/node-gyp/addon.gypi',
    gyp info spawn args   '-I',
    gyp info spawn args   '/home/pi/.electron-gyp/iojs-3.1.10/common.gypi',
    gyp info spawn args   '-Dlibrary=shared_library',
    gyp info spawn args   '-Dvisibility=default',
    gyp info spawn args   '-Dnode_root_dir=/home/pi/.electron-gyp/iojs-3.1.10',
    gyp info spawn args   '-Dnode_gyp_dir=/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/node-gyp',
    gyp info spawn args   '-Dnode_lib_file=/home/pi/.electron-gyp/iojs-3.1.10/(AsyncExecuteComplete)
                                                                  ^
    ../swig/Node/snowboy.cc: In constructor ‘SnowboyDetect::SnowboyDetect(const string&, const string&)’:
    ../swig/Node/snowboy.cc:38:31: warning: catching polymorphic type ‘class std::runtime_error’ by value [-Wcatch-value=]
       } catch (std::runtime_error e) {
                                   ^
    In file included from ../node_modules/nan/nan.h:54,
                     from ../swig/Node/snowboy.cc:1:
    ../swig/Node/snowboy.cc: At global scope:
    /home/pi/.electron-gyp/iojs-3.1.10/src/node.h:442:43: warning: cast between incompatible function types from ‘void (*)(Nan::ADDON_REGISTER_FUNCTION_ARGS_TYPE)’ {aka ‘void (*)(v8::Local)’} to ‘node::addon_register_func’ {aka ‘void (*)(v8::Local, v8::Local, void*)’} [-Wcast-function-type]
           (node::addon_register_func) (regfunc),                          \
                                               ^
    /home/pi/.electron-gyp/iojs-3.1.10/src/node.h:476:3: note: in expansion of macro ‘NODE_MODULE_X’
       NODE_MODULE_X(modname, regfunc, NULL, 0)  // NOLINT (readability/null_usage)
       ^~~~~~~~~~~~~
    ../swig/Node/snowboy.cc:183:1: note: in expansion of macro ‘NODE_MODULE’
     NODE_MODULE(SnowboyDetect, SnowboyDetect::Init)
     ^~~~~~~~~~~
    In file included from /home/pi/.electron-gyp/iojs-3.1.10/src/node.h:54,
                     from ../node_modules/nan/nan.h:54,
                     from ../swig/Node/snowboy.cc:1:
    /home/pi/.electron-gyp/iojs-3.1.10/deps/v8/include/v8.h: In instantiation of ‘void v8::PersistentBase::SetWeak(P*, typename v8::WeakCallbackInfo<p>::Callback, v8::WeakCallbackType) [with P = node::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo</p><p>::Callback = void (*)(const v8::WeakCallbackInfo&)]’:
    /home/pi/.electron-gyp/iojs-3.1.10/src/node_object_wrap.h:85:78:   required from here
    /home/pi/.electron-gyp/iojs-3.1.10/deps/v8/include/v8.h:9256:16: warning: cast between incompatible function types from ‘v8::WeakCallbackInfo::Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo&)’} to ‘Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo&)’} [-Wcast-function-type]
                    reinterpret_cast(callback), type);
                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    /home/pi/.electron-gyp/iojs-3.1.10/deps/v8/include/v8.h: In instantiation of ‘void v8::PersistentBase::SetWeak(P*, typename v8::WeakCallbackInfo<p>::Callback, v8::WeakCallbackType) [with P = Nan::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo</p><p>::Callback = void (*)(const v8::WeakCallbackInfo&)]’:
    ../node_modules/nan/nan_object_wrap.h:65:61:   required from here
    /home/pi/.electron-gyp/iojs-3.1.10/deps/v8/include/v8.h:9256:16: warning: cast between incompatible function types from ‘v8::WeakCallbackInfo::Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo&)’} to ‘Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo&)’} [-Wcast-function-type]
      SOLINK_MODULE(target) Release/obj.target/snowboy.node
    /usr/bin/ld: cannot find -lcblas
    collect2: error: ld returned 1 exit status
    make: *** [snowboy.target.mk:137: Release/obj.target/snowboy.node] Error 1
    make: Leaving directory '/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/build'
    gyp ERR! build error 
    gyp ERR! stack Error: `make` failed with exit code: 2
    gyp ERR! stack     at ChildProcess.onExit (/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/node-gyp/lib/build.js:196:23)
    gyp ERR! stack     at ChildProcess.emit (events.js:198:13)
    gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:248:12)
    gyp ERR! System Linux 4.19.58-v7+
    gyp ERR! command "/usr/bin/node" "/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/.bin/node-gyp" "rebuild" "--target=3.1.10" "--arch=arm" "--dist-url=https://electronjs.org/headers" "--build-from-source" "--module_name=snowboy" "--module_path=/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/lib/node/binding/Release/electron-v3.1-linux-arm" "--remote_path=./snowboy/v1.3.1/Release/" "--package_name=snowboy-v1.3.1-electron-v3.1-linux-arm.tar.gz" "--host=https://snowboy-release-node.s3-us-west-2.amazonaws.com"
    gyp ERR! cwd /home/pi/MagicMirror/modules/MMM-Hotword/snowboy
    gyp ERR! node -v v10.16.3
    gyp ERR! node-gyp -v v5.0.3
    gyp ERR! not ok 
    
    Failed with exit code: 1
        at SafeSubscriber._error (/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/spawn-rx/lib/src/index.js:267:84)
        at SafeSubscriber.__tryOrUnsub (/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/rxjs/internal/Subscriber.js:205:16)
        at SafeSubscriber.error (/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/rxjs/internal/Subscriber.js:156:26)
        at Subscriber._error (/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/rxjs/internal/Subscriber.js:92:26)
        at Subscriber.error (/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/rxjs/internal/Subscriber.js:72:18)
        at MapSubscriber.Subscriber._error (/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/rxjs/internal/Subscriber.js:92:26)
        at MapSubscriber.Subscriber.error (/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/rxjs/internal/Subscriber.js:72:18)
        at SafeSubscriber._next (/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/spawn-rx/lib/src/index.js:242:65)
        at SafeSubscriber.__tryOrUnsub (/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/rxjs/internal/Subscriber.js:205:16)
        at SafeSubscriber.next (/home/pi/MagicMirror/modules/MMM-Hotword/snowboy/node_modules/rxjs/internal/Subscriber.js:143:22)
    node-v64-linux-arm
    ls: cannot access 'lib/node/index.js': No such file or directory
    pi@raspberrypi:~/MagicMirror/modules/MMM-Hotword $ 
    
    ```</p></p></p></p>

  • Module Developer

    @Bestboy4 said in MMM-Hotword install failure:

    /usr/bin/ld: cannot find -lcblas

    Hmmm. weird. Your system seems to have been missing some essential libraries.

    Try this and do again.

    sudo apt-get install build-essential
    


  • @Sean Unfortunately that’s not it.

    pi@raspberrypi:~/MagicMirror $ sudo apt-get install build-essential
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    build-essential is already the newest version (12.6).
    The following package was automatically installed and is no longer required:
      rpi.gpio-common
    Use 'sudo apt autoremove' to remove it.
    0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
    
    

    any other thoughts?


  • Module Developer

    @Bestboy4
    Ok then, You might have missed something on your pre-installation.
    Try this and reinstall again.

    sudo apt update
    sudo apt upgrade
    sudo apt install libmagic-dev libatlas-base-dev sox libsox-fmt-all
    cd ~/MagicMirror/modules/MMM-Hotword
    ./installer/install.sh