While browsing through a Postgres-Rails app in development, I came across a page error-ing out due to a PG error. Thinking my current Git branch's schema may have been out of sync with my database, I attempted to rake db:reset
. This caused an error (that I'm no longer able to reproduce) claiming it couldn't find the postgis.control
file (IIRC) in usr/local/Cellar/postgresql/9.3.5/share/postgresql
directory. After seeing that that control file existed in the corresponding directory for my 9.3.4 version of Postgres, I attempted many things, but eventually uninstalled my postgres-9.3.4 and brew uninstalled and then installed again PostGIS. At some point, though my every attempt to reset the database continued to fail, the error message changed to
ERROR: could not load library "/usr/local/Cellar/postgresql/9.3.5/lib/rtpostgis-2.1.so": dlopen(/usr/local/Cellar/postgresql/9.3.5/lib/rtpostgis-2.1.so, 10): Library not loaded: /usr/local/lib/libspatialite.5.dylib
I then attempted to uninstall Postgres and reinstall, but even this didn't solve the problem.
(Note: I have tried to create the extension to PostGIS in the Postgres console, but this has given the exact same error as what's listed above).