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

add friendly instructions for installing postGIS #14

Open
derekeder opened this issue Jan 30, 2013 · 4 comments
Open

add friendly instructions for installing postGIS #14

derekeder opened this issue Jan 30, 2013 · 4 comments
Labels

Comments

@derekeder
Copy link
Collaborator

Based on what environment people have, give friendly instructions for

  • mac (homebrew or macports or postgis?)
  • linux (ubuntu)
  • windows
@mccc
Copy link
Collaborator

mccc commented Feb 2, 2013

I ultimately wound up installing PostGIS 2.0.2 from source — is there a better way?

On my slightly decrepit MacBook (OS X 10.6.8) the whole path for getting Edifice-ready was:

$ sudo port install postgresql92-server

Then to initialize a default database with Unicode (i.e. template0 and template1, I think)

$ sudo su postgres -c '/opt/local/lib/postgresql92/bin/initdb --locale=en_US.UTF-8 --encoding=UNICODE -D /opt/local/var/db/postgresql92/defaultdb'

Finally, to get the local Postgres database to start and stop on boot:

$ sudo launchctl load -w /Library/LaunchDaemons/org.macports.postgresql92-server.plist 

Then my successful compile of the PostGIS 2.0.2 source code looked like this:

~/src/postgis-2.0.2$ ./configure --with-geosconfig=/Library/Frameworks/GEOS.framework/unix/bin/geos-config  --with-projdir='/Library/Frameworks/PROJ.framework//Versions/4/unix' --with-pgconfig=/opt/local/lib/postgresql92/bin/pg_config

This was after installing the GEOS and PROJ frameworks from the http://www.kyngchaos.com/software/frameworks page (very handy -- especially if you want to get QGIS working).

If you have taken notes on other workflows, please post them and we can be as generic and/or specific as possible in the docs.

@jpvelez
Copy link
Collaborator

jpvelez commented Feb 2, 2013

There's totally a better way, but it requires upgrading to OSX 10.7:
http://postgresapp.com/

On Sat, Feb 2, 2013 at 12:56 AM, Michael Castelle
[email protected]:

I ultimately wound up installing PostGIS 2.0.2 from source — is there a
better way?

On my slightly decrepit MacBook (OS X 10.6.8) the path for installing
PostgreSQL 9.2 was:

  • sudo port install postgresql92-server

Then to initialize a default database with Unicode (i.e. template0 and
template1, I think)

  • sudo bash
  • su - postgres
  • /opt/local/lib/postgresql92/bin/initdb --locale=en_US.UTF-8
    --encoding=UNICODE -D /opt/local/var/db/postgresql92/defaultdb

Then my successful compile of the PostGIS


Reply to this email directly or view it on GitHubhttps://github.com//issues/14#issuecomment-13025704.

@mccc
Copy link
Collaborator

mccc commented Feb 2, 2013

I think someone at the last Hack Night was having a particular issue with that one-stop install, but I can't remember if we resolved it or not, or if it was unrelated. Derek?

(From reading this: http://postgresapp.com/documentation , I could imagine there being an issue in that the psql client being used (i.e. the one that ships with OS X 10.7) is not going to be of the same version as the server, but maybe not.)

@mccc
Copy link
Collaborator

mccc commented Feb 6, 2013

So, the issue with the one-stop installer is that setup_edifice.py needs various command-line binaries, including dropdb, createdb, pg_restore, etc. that may not be included inside something that solely goes in your /Applications directory. I can see the appeal (as newer OS Xs include a /usr/bin/psql client), but I don't think this is appropriate..

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

No branches or pull requests

3 participants