Installing GeoDjango Dependencies with Homebrew
Homebrew seems to be the hot new package manager for OS X, so while setting up a new system last night, I figured I’d see how it handled installing all the external libraries required for GeoDjango. The answer I quickly found out was, “extremely well.” Here are the steps:
$ brew update # make sure all your formulae are up to date $ brew install postgis # this will handle installing postgres, geos, proj4, and postgis $ brew install gdal
That’s it. Three (two if you don’t count the update) steps to GeoDjango goodness. Color me impressed.
Comments
Got something to say?
Our Products
Categories
- accessiblity
- code
- company news
- django
- gondola
- open source
- portfolio
- presentation
- pro tip
- review
- screencast
- seo
- software
- subversion
- trailmapping
- wordpress
Archives
- July, 2010
- June, 2010
- May, 2010
- April, 2010
- February, 2010
- December, 2009
- November, 2009
- October, 2009
Elsewhere
What we’ve been up to online
-
forked divio/django-cms
Pete, 1 day, 1 hour ago -
Congrats on the new hires @eldarion_team ! Glad to see more growth in Django commercial services.
Pete, 5 days, 20 hours ago -
Video: The amazing John Cleese shares his wisdom…
Pete, 5 days, 23 hours ago -
Video: The amazing John Cleese shares his wisdom…
Pete, 5 days, 23 hours ago -
@caktusgroup Congrats on the new hire! Great to see the growth of other Django development companies.
Pete, 2 weeks, 6 days ago -
Just launched a Flask/App Engine mini-site we've been tinkering on http://emailed-me.appspot.com/
Pete, 1 month ago -
created repository Emailed-Me-
Pete, 1 month ago -
Our first iPhone development project hit the App Store last week and is already over 1k users! Check them out @takemyspot #iphone #geodjango
Pete, 1 month, 3 weeks ago -
Love the new sites! RT @welikesmall: We just launched two new sites. http://post.ly/mGoq
Pete, 1 month, 3 weeks ago -
Pro tip: Using pip safely for automated deployment (no more pesky prompts) http://bit.ly/b5zsPa
Pete, 2 months ago -
commented on justquick/django-mailfriend
Pete, 2 months ago -
RT @unbracketed: Excited to have @mitsuhiko joining us for some work this summer :)
Pete, 2 months, 1 week ago -
New blog post: managing supervisord with upstart http://bit.ly/db3p5N
Pete, 2 months, 1 week ago -
Troubleshooting OpenID is just like user/password. Except you have 5 of them and and you don't know which one is failing, and 3 login pages
Pete, 2 months, 1 week ago -
This gets very interesting around 42 min. Using javascript to snoop inside firewalled networks http://bit.ly/aNVPc5
Pete, 2 months, 2 weeks ago


1 step if you don’t count the update and do both formulas in one install:
brew install postgis gdal
Ha! Even better. Thanks Richard.
So… same as macports, except it’s probably easier to create new formulas than to create new ports?
surely you still must wrestle with postgresql PGDATA path, pg_config, pg_hba.conf, spatial db template, postgres users, environment paths for GDAL and GEOS, dated libraries to upgrade like libxml2….
Simon, the only thing I had to do was to create a spatial database template and create the initial application database and I was up and running with a GeoDjango site on a fresh Snow Leopard install. No issues with environment paths, dated libraries, etc.
I don’t exactly remember now, but I believe I was prompted on the Postgres install to setup my local user as a Postgres superuser using
identauthentication, so I never need to deal with creating new Postgres users.clean and up to date installs, starting from scratch, will always help. i’ve installed geo 3 times now on different archs and it has never been straight forward. something conflicts or is on an unexpected path. but if brew does it right, then okay, I’ll try it next time asked.
How does brew install packages? I prefer traditional installs like /usr/local/libl/pgsql/... rather than /Library/PostgresSql/8.4/sh…..
@simon: Homebrew will compile to ”/usr/local/Cellar/postgresql/8.4/...” and then link bin, lib, include, and so on from that location into /usr/local/bin, lib, include, and so on.
So the software packages live separated in the “Cellar” and are symlinked into /usr/local, which is known as the “prefix”.
I contributed the original postgis homebrew recipe. It’s neat to do a `git log -p` on it to see all the other people that have carried it forward since my initial stab at it.