Getting latest node.js to run on UDOO

Discussion in 'General Programming Discussion' started by jfey, Nov 26, 2013.

  1. ftollenaar

    ftollenaar New Member

    Joined:
    Jul 27, 2014
    Messages:
    13
    Likes Received:
    2
    I have the same issue.. any progress on this?

    Tried:
    - Building from source
    - Installing using apt-get
     
  2. jrullan

    jrullan New Member

    Joined:
    Dec 11, 2014
    Messages:
    28
    Likes Received:
    4
  3. jrullan

    jrullan New Member

    Joined:
    Dec 11, 2014
    Messages:
    28
    Likes Received:
    4
    Fellow Udooers,

    I received an update on the joyent/node github forum (https://github.com/joyent/node/issues/7655#issuecomment-73444703) from one of the developers of io.js.
    As it turns out, IO.js is a fork of node from a group of core members of node.js that were unsatisfied with the development of node.

    From their https://iojs.org/en/faq.html:
    "io.js aims to provide faster and predictable release cycles. It currently merges in the latest language, API and performance improvements to V8 while also updating libuv and other base libraries. This project aims to continue development of io.js under an "open governance model" as opposed to corporate stewardship."

    I can happily :D confirm that I've been able to build it on my Udoo Quad running Udoobuntu 1.1 and, more importantly, it runs!!!!!

    A small caveat: I had to install gcc and g++ 4.8 to be able to compile on Udoobuntu 1.1. See this link for instructions: http://mortenvp.com/installing-a-newer-gccg-on-ubuntu-12-04-lts/

    Well I hope that the herd of frustrated node.js Udooers get a little bit of happiness.
     
  4. jrullan

    jrullan New Member

    Joined:
    Dec 11, 2014
    Messages:
    28
    Likes Received:
    4
    Hello,

    To update this issue, Tom Freudenburg just found out how to properly install the newest version of Node.js on the Udoo. Many thanks to Tom for his time and effort, attached is a copy of the message from Tom on the github issues page: https://github.com/4commerce-technologi ... r/issues/4

    Copied below for quick reference...


    Hi guys ( @jrullan @enicky )

    tonight I was able to create a new builder for meteor's stable release-1.0.3.1 and get through your issues.

    I downloaded a fresh UDOObuntu_quad_v1.1.zip Ubuntu image from UDOO (http://www.udoo.org/downloads/) and run following commands as root:

    Code:
    apt-get update
    apt-get dist-upgrade
    This shows some totem errors, so I corrected via:

    Code:
    apt-get install -f
    Now we need the additional packages for meteor and the universal-bundler

    Code:
    apt-get install git-core mongodb
    To run meteor we need a newer version for NodeJS than stored in repository. Therefore we have to build NodeJS by our own. The debs from ppa:chris-lea won't run at the official UDOO 1.1 image (node hung). Thanks a lot to Mortonvp (http://mortenvp.com/installing-a-newer- ... -12-04-lts). He has made my day! You need to update gcc and some libraries – otherwise any build of NodeJS v0.10.23+ will fail also!

    Update gcc and libraries

    Code:
    add-apt-repository ppa:ubuntu-toolchain-r/test
    apt-get dist-upgrade
    Here is how to proceed to build and install a running NodeJS v0.10.36
    Code:
    cd /tmp
    git clone https://github.com/joyent/node.git
    cd node
    git checkout -b v0.10.36
    ./configure --without-snapshot
    make -j4 # use 4 cores on quad or -j2 for dual to speed up build process
    make install
    NodeJS is now installed at /usr/local/bin/node and /usr/local/lib/node_modules

    Test the installation via:

    Code:
    node --version
    npm --version
    Both commands should return their info. If npm does not print anything, than your node!!! is not working.

    Next to do is meteor build:

    Code:
    cd /usr/local/lib
    git clone https://github.com/4commerce-technologies-AG/meteor.git
    cd meteor
    ./scripts/generate-dev-bundle.sh
    ln -s /usr/local/lib/meteor/meteor /usr/local/bin/meteor
    For first time installation and to check the build, just get version info

    Code:
    meteor --version
    should return something like:

    Code:
        Unreleased, running from a checkout at
    As a short test I just created one of the examples:

    Please check what I have done here, some important information may be in

    Add missing link to non-core package npm-bcrypt (see also #1)

    Code:
    cd /usr/local/lib/meteor/packages
    ln -s non-core/npm-bcrypt .
    Make sure that your LANG environments are set. This is missing on default and will cause a fail to start mongodb session!
    Code:
    export LANG=C
    export LC_ALL=C
    Now you are ready to create and run the example

    Code:
    cd /tmp
    meteor create --example todos
    cd todos
    meteor
    That's it :)
     
  5. TomFreudenberg

    TomFreudenberg Member

    Joined:
    May 12, 2014
    Messages:
    59
    Likes Received:
    2
  6. sirrab

    sirrab UDOOer

    Joined:
    Jul 26, 2014
    Messages:
    264
    Likes Received:
    32
    I get a bunch of compiler errors, following this tutorial. Suspect there are some environment variables that need to be set up, first.
     
  7. TomFreudenberg

    TomFreudenberg Member

    Joined:
    May 12, 2014
    Messages:
    59
    Likes Received:
    2
    Hi @sirrab

    It would be great if you contact me via github and send in an issue to the project at:

    https://github.com/4commerce-technologi ... eor/issues

    I have set-up meteor on a fresh downloaded UDOO original Lubuntu 1.1 image exactly as posted before. Would like to see what errors you are running in. Please send log output via gist if possible.

    Tom
     
  8. sirrab

    sirrab UDOOer

    Joined:
    Jul 26, 2014
    Messages:
    264
    Likes Received:
    32
    Not sure how to do the things you suggested... But here is the output before the make -j4 command.
    /code

    ./configure --without-snapshot
    creating ./icu_config.gypi
    { 'target_defaults': { 'cflags': [],
    'default_configuration': 'Release',
    'defines': [],
    'include_dirs': [],
    'libraries': []},
    'variables': { 'arm_float_abi': 'hard',
    'arm_fpu': 'vfpv3',
    'arm_neon': 0,
    'arm_thumb': 0,
    'arm_version': '7',
    'clang': 0,
    'gcc_version': 46,
    'host_arch': 'arm',
    'icu_small': 'false',
    'node_install_npm': 'true',
    'node_prefix': '',
    'node_shared_cares': 'false',
    'node_shared_http_parser': 'false',
    'node_shared_libuv': 'false',
    'node_shared_openssl': 'false',
    'node_shared_v8': 'false',
    'node_shared_zlib': 'false',
    'node_tag': '',
    'node_use_dtrace': 'false',
    'node_use_etw': 'false',
    'node_use_mdb': 'false',
    'node_use_openssl': 'true',
    'node_use_perfctr': 'false',
    'openssl_no_asm': 0,
    'python': '/usr/bin/python',
    'target_arch': 'arm',
    'uv_library': 'static_library',
    'uv_parent_path': '/deps/uv/',
    'uv_use_dtrace': 'false',
    'v8_enable_gdbjit': 0,
    'v8_enable_i18n_support': 0,
    'v8_no_strict_aliasing': 1,
    'v8_optimized_debug': 0,
    'v8_random_seed': 0,
    'v8_use_snapshot': 'false',
    'want_separate_host_toolset': 0}}
    creating ./config.gypi
    creating ./config.mk
    code/
     
  9. TomFreudenberg

    TomFreudenberg Member

    Joined:
    May 12, 2014
    Messages:
    59
    Likes Received:
    2
    Hi sirrab ... it is a bit difficult for me to decipher your comment

    but I just run a clean "configure" on my system for you and

    IT SHOWS EXACTLY YOUR OUTPUT

    so ... just proceed and go on ...

    Thanks for more feedback,
    Tom
     
  10. sirrab

    sirrab UDOOer

    Joined:
    Jul 26, 2014
    Messages:
    264
    Likes Received:
    32
    I am not an expert in compiling. But I am learning! Here is the latest output from "make -j4":

    /CODE

    make -j4
    make -C out BUILDTYPE=Release V=1
    make[1]: Entering directory `/home/ubuntu/tmp/node/out'
    g++ '-DV8_TARGET_ARCH_ARM' '-DCAN_USE_ARMV7_INSTRUCTIONS' '-DCAN_USE_VFP3_INSTRUCTIONS' '-DCAN_USE_VFP32DREGS' '-DENABLE_DISASSEMBLER' '-DICU_UTIL_DATA_IMPL=ICU_UTIL_DATA_STATIC' '-DENABLE_HANDLE_ZAPPING' -I../deps/v8 -pthread -Wall -Wextra -Wno-unused-parameter -fno-strict-aliasing -march=armv7-a -mfpu=vfpv3 -mfloat-abi=hard -marm -O3 -ffunction-sections -fdata-sections -fno-tree-vrp -fno-omit-frame-pointer -fdata-sections -ffunction-sections -O3 -fno-rtti -fno-exceptions -MMD -MF /home/ubuntu/tmp/node/out/Release/.deps//home/ubuntu/tmp/node/out/Release/obj.target/v8_base/deps/v8/src/compiler/gap-resolver.o.d.raw -c -o /home/ubuntu/tmp/node/out/Release/obj.target/v8_base/deps/v8/src/compiler/gap-resolver.o ../deps/v8/src/compiler/gap-resolver.cc
    g++ '-DV8_TARGET_ARCH_ARM' '-DCAN_USE_ARMV7_INSTRUCTIONS' '-DCAN_USE_VFP3_INSTRUCTIONS' '-DCAN_USE_VFP32DREGS' '-DENABLE_DISASSEMBLER' '-DICU_UTIL_DATA_IMPL=ICU_UTIL_DATA_STATIC' '-DENABLE_HANDLE_ZAPPING' -I../deps/v8 -pthread -Wall -Wextra -Wno-unused-parameter -fno-strict-aliasing -march=armv7-a -mfpu=vfpv3 -mfloat-abi=hard -marm -O3 -ffunction-sections -fdata-sections -fno-tree-vrp -fno-omit-frame-pointer -fdata-sections -ffunction-sections -O3 -fno-rtti -fno-exceptions -MMD -MF /home/ubuntu/tmp/node/out/Release/.deps//home/ubuntu/tmp/node/out/Release/obj.target/v8_base/deps/v8/src/compiler/graph-builder.o.d.raw -c -o /home/ubuntu/tmp/node/out/Release/obj.target/v8_base/deps/v8/src/compiler/graph-builder.o ../deps/v8/src/compiler/graph-builder.cc
    g++ '-DV8_TARGET_ARCH_ARM' '-DCAN_USE_ARMV7_INSTRUCTIONS' '-DCAN_USE_VFP3_INSTRUCTIONS' '-DCAN_USE_VFP32DREGS' '-DENABLE_DISASSEMBLER' '-DICU_UTIL_DATA_IMPL=ICU_UTIL_DATA_STATIC' '-DENABLE_HANDLE_ZAPPING' -I../deps/v8 -pthread -Wall -Wextra -Wno-unused-parameter -fno-strict-aliasing -march=armv7-a -mfpu=vfpv3 -mfloat-abi=hard -marm -O3 -ffunction-sections -fdata-sections -fno-tree-vrp -fno-omit-frame-pointer -fdata-sections -ffunction-sections -O3 -fno-rtti -fno-exceptions -MMD -MF /home/ubuntu/tmp/node/out/Release/.deps//home/ubuntu/tmp/node/out/Release/obj.target/v8_base/deps/v8/src/compiler/graph-reducer.o.d.raw -c -o /home/ubuntu/tmp/node/out/Release/obj.target/v8_base/deps/v8/src/compiler/graph-reducer.o ../deps/v8/src/compiler/graph-reducer.cc
    g++ '-DV8_TARGET_ARCH_ARM' '-DCAN_USE_ARMV7_INSTRUCTIONS' '-DCAN_USE_VFP3_INSTRUCTIONS' '-DCAN_USE_VFP32DREGS' '-DENABLE_DISASSEMBLER' '-DICU_UTIL_DATA_IMPL=ICU_UTIL_DATA_STATIC' '-DENABLE_HANDLE_ZAPPING' -I../deps/v8 -pthread -Wall -Wextra -Wno-unused-parameter -fno-strict-aliasing -march=armv7-a -mfpu=vfpv3 -mfloat-abi=hard -marm -O3 -ffunction-sections -fdata-sections -fno-tree-vrp -fno-omit-frame-pointer -fdata-sections -ffunction-sections -O3 -fno-rtti -fno-exceptions -MMD -MF /home/ubuntu/tmp/node/out/Release/.deps//home/ubuntu/tmp/node/out/Release/obj.target/v8_base/deps/v8/src/compiler/graph-replay.o.d.raw -c -o /home/ubuntu/tmp/node/out/Release/obj.target/v8_base/deps/v8/src/compiler/graph-replay.o ../deps/v8/src/compiler/graph-replay.cc
    g++: internal compiler error: Killed (program cc1plus)
    Please submit a full bug report,
    with preprocessed source if appropriate.
    See <file:///usr/share/doc/gcc-4.6/README.Bugs> for instructions.
    make[1]: *** [/home/ubuntu/tmp/node/out/Release/obj.target/v8_base/deps/v8/src/compiler/graph-reducer.o] Error 4
    make[1]: *** Waiting for unfinished jobs....
    g++: internal compiler error: Killed (program cc1plus)
    Please submit a full bug report,
    with preprocessed source if appropriate.
    See <file:///usr/share/doc/gcc-4.6/README.Bugs> for instructions.
    make[1]: *** [/home/ubuntu/tmp/node/out/Release/obj.target/v8_base/deps/v8/src/compiler/gap-resolver.o] Error 4
    make[1]: Leaving directory `/home/ubuntu/tmp/node/out'
    make: *** [node] Error 2

    CODE/
     
  11. TomFreudenberg

    TomFreudenberg Member

    Joined:
    May 12, 2014
    Messages:
    59
    Likes Received:
    2
    Hmm ... what I can parse from the log ...

    it seems that you don't have followed completly the guide and still use the old GCC-4.6 ?

    Just a question you haven't answer yet:

    Board: UDOO Quad or Dual?
    Image: ?

    I would like you to start with a fresh image downloaded from UDOO download page an follow the above guide from top to bottom - pretty sure that this will run.
     
  12. sirrab

    sirrab UDOOer

    Joined:
    Jul 26, 2014
    Messages:
    264
    Likes Received:
    32
    Hmmmm, I did run the command to load the latest and greatest compiler. I have the quad version. And I have the Ubuntu 1.1 version. Sigh it is not a fresh install though. I'll do that, and see what happens. Thanks! Roy
     
  13. TomFreudenberg

    TomFreudenberg Member

    Joined:
    May 12, 2014
    Messages:
    59
    Likes Received:
    2
    Hey Roy,

    looking forward to your results from a fresh installation. Thanks for keeping me informed.

    Tom
     
  14. sirrab

    sirrab UDOOer

    Joined:
    Jul 26, 2014
    Messages:
    264
    Likes Received:
    32
  15. TomFreudenberg

    TomFreudenberg Member

    Joined:
    May 12, 2014
    Messages:
    59
    Likes Received:
    2
    Hm ... hi Roy,

    Do you really follow my guide posted by jrullian at getting-latest-node-run-udoo-t431-20.html#p12044 ?

    In codeblock 3, I wrote: apt-get install git-core mongodb

    So yeah ... you have to install git before can run git clone ...

    For a git clone via the HTTPS you do not need any credentials on github ... maybe you are behind a firewall / proxy?

    Instead of git clone you can download and unpack also the archives from github

    1. https://github.com/joyent/node/archive/v0.10.36.zip
    2. https://github.com/4commerce-technologi ... versal.zip

    when you unzip the archives, check the new folder names and rename them to the proposed ones.

    This is very mystic ... I tried and did it several times as described.
     
  16. sirrab

    sirrab UDOOer

    Joined:
    Jul 26, 2014
    Messages:
    264
    Likes Received:
    32
    I was following the version from the Meteor universal blog page. Guess this isn't the most current! Doh! Trying from the place you just suggested.
     
  17. TomFreudenberg

    TomFreudenberg Member

    Joined:
    May 12, 2014
    Messages:
    59
    Likes Received:
    2
    Ah ok,

    I added a comment about git-core to that pages already. The blog is divided into several parts so for you it might be easier to follow the guide posted on this thread.

    Tom
     
  18. sirrab

    sirrab UDOOer

    Joined:
    Jul 26, 2014
    Messages:
    264
    Likes Received:
    32
    Got node to compile. Got alot of text output, which I thought was error messages..... I am a noob at compiling. And you need to know whe to use "sudo" in front of some of the commands. Fails building meteor now.... Sigh....
     
  19. TomFreudenberg

    TomFreudenberg Member

    Joined:
    May 12, 2014
    Messages:
    59
    Likes Received:
    2
    Hmmm ... as is written in the guide ... you should be logged in as user root all the time. So sudo is not neccessary in that case.

    If you like to test, I can try to push you my already compiled archive?

    Do you know services like TeamViewer.com ? I would provide you some guidiance if not getting success!

    For what do you want to use meteor? Just testing or programming?
     
  20. sirrab

    sirrab UDOOer

    Joined:
    Jul 26, 2014
    Messages:
    264
    Likes Received:
    32
    All this is just for learning....
     

Share This Page