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

Installation Steps for OSX #88

Closed
cybertoast opened this Issue Mar 15, 2012 · 3 comments

Comments

Projects
None yet
3 participants
@cybertoast
Contributor

cybertoast commented Mar 15, 2012

Some clarification on installation on OSX, and possible trouble-shooting steps for newbies. Hopefully this will help someone.

# Install node
brew install node  # You'll now have the latest node version (0.6.x)
cd /usr/local/Cellar/node
brew versions node
git checkout -b node-0.4.9 10b3ded # The commit will be in the versions output
brew install node # You'll now have version 0.4.9
brew switch node 0.4.9

# Install npm for the appropriate Node version
curl http://npmjs.org/install.sh | sh

# Install tilestream
git clone tilestream
cd tilestream

npm install

Troubleshooting

If you run into problems during install, such as unfound dependent versions, first try deleting the node_modules/ folder and re-run node install. It seems that some errors leave the installation in an unclean state (for example if you accidentally switched node versions during the install in the hopes of making things work!).

Build failures:

npm install may cause:

Waf: Leaving directory `/Users/sundar/Projects/tilestream/node_modules/sqlite3/build'
Build failed:
 -> task failed (err #1): 
    {task: cxx statement.cc -> statement_1.o}
 -> task failed (err #1): 
    {task: cxx database.cc -> database_1.o}
 -> task failed (err #1): 
    {task: cxx sqlite3.cc -> sqlite3_1.o}
npm ERR! sqlite3@2.1.1 preinstall: `node-waf clean || (exit 0); node-waf configure build`
npm ERR! `sh "-c" "node-waf clean || (exit 0); node-waf configure build"` failed with 1
npm ERR! 
npm ERR! Failed at the sqlite3@2.1.1 preinstall script.

Manually installing sqlite3 via npm install sqlite3 resolved this issue. Then re-run npm install in the tilestream folder:

npm install sqlite3
npm install

If you STILL get errors when launching index.js, there may be more modules to install manually. This is the list that worked for me:

npm install sqlite3
npm install mbtiles
npm install jsdom
npm install uglify-js
npm install connect
npm install qs
npm install mime
@willwhite

This comment has been minimized.

Show comment
Hide comment
@willwhite

willwhite Mar 15, 2012

Hi @cybertoast,
Thanks for the post. It you have a moment a pull request against the README in this repo would be appreciated. That will make sure everyone sees these steps.

Thanks,
Will

willwhite commented Mar 15, 2012

Hi @cybertoast,
Thanks for the post. It you have a moment a pull request against the README in this repo would be appreciated. That will make sure everyone sees these steps.

Thanks,
Will

@cybertoast

This comment has been minimized.

Show comment
Hide comment
@cybertoast

cybertoast Mar 20, 2012

Contributor

Done.

Contributor

cybertoast commented Mar 20, 2012

Done.

@avanderpluijm

This comment has been minimized.

Show comment
Hide comment
@avanderpluijm

avanderpluijm Mar 21, 2012

Thanks, this helped me to make it work!

avanderpluijm commented Mar 21, 2012

Thanks, this helped me to make it work!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment