1

I would like to install node.js on the ASUS RT-N18U with Tomato firmware version 1.28 by Shibby (http://tomato.groov.pl/download/K26ARM/132/tomato-RT-N18U-ARM--132-AIO-64K.zip)

HW configuration

root@unknown:/# cat /proc/cpuinfo
Processor       : ARMv7 Processor rev 0 (v7l)
processor       : 0
BogoMIPS        : 1599.07

Features        : swp half thumb fastmult edsp
CPU implementer : 0x41
CPU architecture: 7
CPU variant     : 0x3
CPU part        : 0xc09
CPU revision    : 0

Hardware        : Northstar Prototype
Revision        : 0000
Serial          : 0000000000000000

Try 1:

root@unknown:/# cd /opt
root@unknown:/opt# wget node-v4.2.1-linux-armv7l.tar.gz
root@unknown:/opt# tar zxvf node-v4.2.1-linux-armv7l.tar.gz
root@unknown:/opt# cd node-v4.2.1-linux-armv7l/bin
root@unknown:/opt/node-v4.2.1-linux-armv7l/bin# ls -l
  -rwxr-xr-x    1 root     root      20958710 Sep 23 03:55 node
  lrwxrwxrwx    1 root     root            38 Sep 24 17:47 npm -> ../lib/node_modules/npm/bin/npm-cli.js
root@unknown:/opt/node-v4.2.1-linux-armv7l/bin# ./node
  -sh: ./node: not found

Result: File "node" in the directory exists, but the system says "not found".

Try 2:

I've downloaded and unpacked the TomatoWare (latest version 1.0.3) and then compiled the latest version node.js

root@unknown:/opt/node-v4.2.1# ./configure --prefix=/opt/node && make && make install
...
root@unknown:/opt/node/bin# ./node -v
v4.2.1
root@unknown:/opt/node/bin# ./node
Illegal instruction

When I've deleted all files of TomatoWare

root@unknown:/opt/node/bin# ./node
-sh: ./node: not found

so the same error as in the first case!

By root@unknown:/opt# ldd /opt/node/bin/node node requires some libraries from TomatoWare.

After these files were copied into /opt/lib:

root@unknown:/opt/lib# ls -l
  -rwxr--r--    1 root     root         28701 Sep  3 18:51 ld-uClibc.so.0
  -rwxr--r--    1 root     root        576031 Sep  3 18:51 libc.so.0
  -rwxr--r--    1 root     root         16129 Sep  3 18:51 libdl.so.0
  -rwxr--r--    1 root     root       1344500 Sep  3 18:51 libgcc_s.so.1
  -rwxr--r--    1 root     root         92168 Sep  3 18:51 libm.so.0
  -rwxr--r--    1 root     root        113786 Sep  3 18:51 libpthread.so.0
  -rwxr--r--    1 root     root         19328 Sep  3 18:51 librt.so.0
  -rwxr--r--    1 root     root       4079041 Sep  3 18:51 libstdc++.so.6

then

root@unknown:/opt/node/bin# ./node
  Illegal instruction

Try 3:

I installed Optware-ng (https://www.hqt.ro/how-to-install-new-generation-optware/)

root@unknown:/# cd /opt
root@unknown:/opt# wget -c -O optware-ng-arm-setup.sh
root@unknown:/opt# chmod +x ./optware-ng-arm-setup.sh
root@unknown:/opt# ./optware-ng-arm-setup.sh
root@unknown:/opt# ipkg update
root@unknown:/opt# ipkg install gcc
root@unknown:/opt# ipkg install make
root@unknown:/opt# ipkg install python27
root@unknown:/opt# gcc --version
gcc (GCC) 5.2.0
root@unknown:/opt# wget node-v4.2.1.tar.gz
root@unknown:/opt# tar xzvf node-v4.2.1.tar.gz
root@unknown:/opt# cd node-v4.2.1
root@unknown:/opt/node-v4.2.1# ./configure --prefix=/opt/node
root@unknown:/opt/node-v4.2.1# make

result:

/opt/node-v4.2.1/out/Release/obj.target/deps/gtest/libgtest.a(gtest.o): In function `testing::UnitTest::GetInstance()':
gtest.cc:(.text._ZN7testing8UnitTest11GetInstanceEv+0x78): undefined reference to `atexit'
collect2: error: ld returned 1 exit status
cctest.target.mk:118: recipe for target '/opt/node-v4.2.1/out/Release/cctest' failed
make[1]: *** [/opt/node-v4.2.1/out/Release/cctest] Error 1
make[1]: Leaving directory '/opt/node-v4.2.1/out'
Makefile:45: recipe for target 'node' failed
make: *** [node] Error 2

Try 4:

I installed Debian, and in it nodejs

root@unknown:/# debian enter
root@unknown:/# apt-get update && apt-get upgrade
root@unknown:/# apt-get install nodejs
root@unknown:/# nodejs -v
v4.1.1
root@unknown:/# nodejs
Illegal instruction

Please can you tell me what am I doing wrong?

user2106769
  • 445
  • 5
  • 15
  • At a wild guess, your build of node and/or libraries depend on floating-point support, which your kernel doesn't appear to have. If the kernel doesn't turn on the FPU hardware, the instructions will be undefined. – Notlikethat Nov 17 '15 at 16:20
  • Is it possible to add the FPU support yourself? – Rutger van Baren Jan 31 '16 at 12:59

0 Answers0