Last active
March 6, 2017 16:40
-
-
Save apocas/f8889c32649e6a8f839d to your computer and use it in GitHub Desktop.
Compiling Nodejs v4 in Centos 6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#Nodejs v4.x needs gcc v4.8, Centos 6 comes with gcc v.4.4. | |
#devtools-2 comes already bundled with v4.8 | |
wget http://people.centos.org/tru/devtools-2/devtools-2.repo -O /etc/yum.repos.d/devtools-2.repo | |
yum install -y devtoolset-2-gcc devtoolset-2-binutils devtoolset-2-gcc-c++ | |
scl enable devtoolset-2 bash | |
wget https://nodejs.org/dist/latest/node-v4.0.0-linux-x64.tar.gz | |
tar -zxvf node-v4.0.0-linux-x64.tar.gz | |
cd node-v4.0.0-linux-x64 | |
./configure | |
make | |
make install | |
exit |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment