-
Notifications
You must be signed in to change notification settings - Fork 35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add nodejs to LibraryBox #26
Comments
I tried an early build of Node.js for OpenWRT, and it was....unsuitable. Jason On Fri, Sep 18, 2015 at 9:59 PM Kevin Old [email protected] wrote:
|
Awesome! This script uses Node 0.10.25, but v4.0.0 was just released so it might make sense to try that version. I'm also interested in compiling Elixir with OpenWRT, but need a bit of guidance in understand what prerequisites are needed when compiling. I filed this issue on OpenWRT, but would ulimately love to have this on LibraryBox openwrt/packages#1786 |
I tested building nodejs into OpenWRT with the script I referenced, and I'm running into the following: I think it is because I'm using OpenWRT 15 instead of an earlier version and that it is not compatible with gcc 4.6. I found this that seems to solve it, but references gcc 4.9: https://dev.openwrt.org/ticket/18182
|
It's also worth noting that they've started compiling releases for arm with each release: https://nodejs.org/download/release/v4.1.0/node-v4.1.0-linux-armv7l.tar.gz Would I be able to just copy these builds over the TP Link MR3040? |
My Node.js on ARM experience is limited to Raspberry Pi and BeagleBone where others have figured out the porting issues (and we thank them). As a suggestion, you might look over the Omega Onion project which is rather prominently introducing Node.js on a minimal OpenWRT platform. https://github.com/OnionIoT/OpenWRT-Packages/tree/master/iojs You might find some source or discussion that could get you going. I think the Tessel 2 project may also be Node.js on OpenWRT. |
We'll look into it asap, gang. I, too, would like node.js on the platform, for server-side epub rendering. :-) Let me dig in this week and see what I can find out. |
Awesome! I've attempted to compile the iojs linked from @jfathman but am running into compile errors. I'll keep trying but probably with a v3 or v4. I've also run across nodejs/node#2948 which is relevant and could help us. |
Extremely naive question, but now that nodejs provides builds for arm, can't we use its Makefile directly |
Accidentally closed sorry, reopened |
https://github.com/nodejs/node/blob/master/Makefile Search for "arm" and you'll see the ARCH is modified accordingly. Combine that with lots of flags throughout the code for ARM architecture https://github.com/nodejs/node/search?utf8=✓&q=arm |
maybe to clear things up a bit: So, binaries aren't replacable/re-usable. The gcc of your system is only a kickstart gcc. The real gcc used in the buildchain is compiled by the OpenWrt toolchain itself. You need to add this package via a package-feed to your build environment and mark it as a "module" using "make menuconfig". After that compile it with "make -j3". |
Thanks for the clarification @MaStr. As I said, it was an extremely naive question. :) I had already started to compile iojs v2.3.0 using the reference to the Onion scripts above, but ran into a compile error. I've just kicked off a build of this https://github.com/kevinold/openwrt-nodejs which updates the script node 4.1.0. I will report back with progress. |
I've been trying to get the compile to run all day but it seems the git server that hosts the
I've tried every hour or two and it's still throwing it. Hoping the git server stops "hanging up" at some point. The web version is accessible. |
Hi,
try it again at the end of the week. According to the OpenWRT-Dev Mailing list, you are not the only one having problems- I tried it stand alone as well, without luck.
best regards
Matthias
|
I checked on IRC and the owner of that server restarted it and I'm past that issue. The compile is running now. |
I'm at the stage now where I'm compiling nodejs 4.1.0, but it needs:
The complete log:
I have 4.6.3:
From reading https://github.com/fivdi/onoff/wiki/Node.js-v4-and-native-addons, which is unrelated to this but contains some interesting info about gcc requirements for the version of node, it says that versions of node/iojs after v3 require this newer version. My question is, should I install the 4.8 version of g++ in order for this to compile? Will that be an issue for LibraryBox and/or PirateBox that is currently using g++ 4.6? |
You can give it a try, but I'm not sure if :
The PirateBox/LibraryBox packages themself are plattform-independend. |
@MaStr So should I just downgrade the version of nodejs/iojs I'm attempting to compile? |
I've update kevinold/openwrt-nodejs@2ab3ca7 to go against nodejs 0.12.7 which works with gcc 4.6.3. I'm digging into this next error:
|
Referencing https://github.com/tessel/openwrt-tessel/blob/master/package/node/iojs/Makefile. It may help with getting the config flags right. Might try to build that version. |
^^^ This iojs v2.3.0 package from tessel is compiling. |
The tessel iojs v2.3.0 compiled for a while but still failed with the following:
|
Hi,
I would like to add nodejs to my LibraryBox and have found this: https://github.com/akwrt/openwrt-nodejs but I am unclear on how I can incorporate it with the current LibraryBox builds.
Would someone be able to help?
The text was updated successfully, but these errors were encountered: