Skip to content
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

Update Node.js #96

Closed
nazar-pc opened this issue Aug 20, 2017 · 9 comments
Closed

Update Node.js #96

nazar-pc opened this issue Aug 20, 2017 · 9 comments
Assignees

Comments

@nazar-pc
Copy link

nazar-pc commented Aug 20, 2017

Currently emsdk uses Node.js 4.1.1, which is quite old and doesn't support some of the newer features required by JS version of Closure Compiler in order to implement emscripten-core/emscripten#5464

Closure Compiler JS should be happy with latest release of the same v4 LTS branch, but would be also nice to upgrade it to v6 LTS or even v8 (which is planned to be LTS as well) for more performance and future-proofness.

If this is not a big undertaking, I'd be thankful for including newer Node.js version into next release.

@vvuk
Copy link

vvuk commented Sep 18, 2017

+1 for 8.x over the others, as it has mostly complete ES6 feature support.

@vvuk
Copy link

vvuk commented Sep 18, 2017

(Also as a data point, I've been using Node 8.x with emscripten for a while now with no problems)

@juj juj self-assigned this Sep 22, 2017
@juj
Copy link
Collaborator

juj commented Sep 22, 2017

Yeah, it sounds like a due time to update. I'll try to make this happen shortly.

@TimvanScherpenzeel
Copy link

TimvanScherpenzeel commented Nov 2, 2017

@TimvanScherpenzeel
Copy link

@juj any update regarding this issue? It is causing some really annoying problems as most of the newer scaffolding tools use ES2015+ javascript in Node.js which is not supported in earlier versions.

In my opinion it would be better to move away from including Node.js in the build because when activating Emscripten it overrides the existing Node binding resulting in issues with other packages.

@buu700
Copy link

buu700 commented Dec 10, 2017

Yeah, I think it'd be more convenient if emsdk install latest didn't include any version of Node.js at all (except maybe if it detected that there was no recent version already installed). If that can't/shouldn't be done, then +1 for at least bumping from 4.x to 8.x.

@juj
Copy link
Collaborator

juj commented Dec 11, 2017

Ops, sorry, this was resolved a couple of weeks ago in 9026335, but forgot to link to this issue.

We can't really drop node.js from latest, since other people depend on obtaining it via emsdk, but Emscripten SDK can be used without installing node.js (or any other tools like python or java) with it. Emsdk has a concept of "SDKs" and "tools", where SDKs are aliases to a preset list of tools. These SDK strings are expanded in the emsdk.py front end to their tool counterparts. So if you wanted to use Emscripten without any of the associated tools (but provide your own versions), instead of for example

emsdk install sdk-1.37.22-64bit

you can specify

emsdk install emscripten-tag-1.37.22-64bit binaryen-tag-1.37.22-64bit clang-tag-e1.37.22-64bit

Unfortunately though at present, there does not exist emscripten-latest-64bit meta-tools or similar to refer to the latest tag. For latest incoming branch of development, you can do

emsdk install emscripten-incoming-64bit binaryen-master-64bit clang-incoming-64bit

to avoid getting node or python. Does that help?

@juj juj closed this as completed Dec 11, 2017
@TimvanScherpenzeel
Copy link

Thank you, I wasn't aware of the ability to install without Node.js.

Great to see that Node has been updated to 8.9.1 👍 .

@buu700
Copy link

buu700 commented Dec 11, 2017

Nice, that's great news about the Node version update. As far as the different installable tools, I'm aware of that, but in this case I'm using emsdk in a bash script that just needs to get the latest of everything needed to make emscripten work without knowing what that is or what the version numbers are. This is the best workaround I've come up with:

emsdk update
emsdk install latest
emsdk uninstall $(emsdk list | grep INSTALLED | perl -pe 's/\\(?\\*\\)?//g' | grep node | awk '{print $1}')
emsdk activate latest

It'd be preferable medium-to-long-term if emsdk's Node.js could just be used by emscripten without taking a higher priority in my PATH than the one in /usr/bin, or if it could detect when the installed Node.js version is sufficient for the current emscripten and do roughly what my script currently does, but as long as we can reliably expect it to be the latest LTS release then it's basically fine for my purposes for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants