Created
February 26, 2015 21:26
-
-
Save molsches/d4ec0c18794a069b1811 to your computer and use it in GitHub Desktop.
Building Node from source on Ubuntu
This file contains 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
//Make a directory to hold the node | |
mkdir node-install-dir | |
cd node-install-dir | |
//Curl and unzip latest node | |
curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1 | |
//Install gcc and g++ | |
sudo apt-get update | |
sudo apt-get install make gcc g++ apache2 | |
//Build Node (takes awhile) | |
sudo ./configure --prefix=/opt/node && sudo make && sudo make install | |
//Add node path to your sudoer and local bash ":/opt/node/bin" | |
sudo vim /etc/environment | |
sudo vim /etc/sudoers | |
//Install npm | |
sudo curl https://www.npmjs.com/install.sh |sudo sh |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment