Building Xen Orchestra from Source on FreeBSD - error in level-party



  • I'm trying to build xen orchestra from source on FreeBSD. The build process runs to completion, but when I try to run the service (sudo yarn start) I get an error:

    2019-05-01T19:27:54.132Z - xo:xo-server - [ERROR] uncaught exception
    { error:
       { Error: Could not locate the bindings file. Tried:
    

    and then a long list of exceptions and stuff. I can provide it all if you like.

    During the build I noticed an error scroll by quite fast. I though "it's probably not building correctly". So I finally isolated the package that isn't building.

    I go to ~/xen-orchestra/node_modules/level-party and run 'yarn'. It seems like level-party builds its own version of leveldown. Now, at the higher level (~/xen-orchestra/node_modules/leveldown) the package has built fine with no errors. But when yarn tries to build ~/xen-orchestra/node_modules/level-party/node_modules/leveldown, I get this error:

     CXX(target) Release/obj.target/leveldown/src/batch.o
    In file included from ../src/batch.cc:3:
    In file included from ../../nan/nan.h:192:
    ../../nan/nan_maybe_43_inl.h:112:15: error: no member named 'ForceSet' in 'v8::Object'
      return obj->ForceSet(isolate->GetCurrentContext(), key, value, attribs);
    /home/paco/.node-gyp/11.13.0/include/node/node.h:171:1: note: 'MakeCallback' has been explicitly marked deprecated here
    NODE_DEPRECATED("Use MakeCallback(..., async_context)",
    ^
    /home/paco/.node-gyp/11.13.0/include/node/node.h:91:20: note: expanded from macro 'NODE_DEPRECATED'
        __attribute__((deprecated(message))) declarator
                       ^
    

    I'm assuming, perhaps wrongly, that the two things are related. I figure if I don't get a clean build, I shouldn't expect it to run.

    I'm building master of https://github.com/vatesfr/xen-orchestra/. I'm on FreeBSD 12.0-RELEASEp3 on amd64.

    Anybody have thoughts or things I could try?

    Happy to paste more log files and more verbose errors, but these things are so large, that I didn't want to preemptively spew a ton of them into the forum.

    Thanks!



  • @paco

    What version of node is installed here? if 10.X it's not going to work. Ubuntu 19.04 also has this issue, its a node bug. Node 8 works though.



  • @DustinB Brilliant. Thanks. I was using node 11. I know absolutely nothing about node versions, so I just went with the latest available. I'll try downgrading to node 8 and see how that goes.


  • Admin

    Hi there!

    As stated in bold in our official doc:

    Please use Node 8.

    https://xen-orchestra.com/docs/from_the_sources.html#nodejs



  • @olivierlambert You expect a system administrator to read documentation!? 😛

    Anyways, that was it. Sorry I didn't look more carefully. I rebuilt using node8 and poof it was running. Thanks guys.


  • Admin

    Great! Enjoy 🙂



  • Glad I was able to help.


Log in to reply