OSGeo / homebrew-osgeo4mac

Mac homebrew tap for maintaining a stable work environment for the OSGeo.org geospatial toolset
https://git.io/fhh3X
BSD 3-Clause "New" or "Revised" License
364 stars 112 forks source link

CREATE EXTENSION postgis fails with Symbol not found: _AllocSetContextCreateExtended #1335

Closed kevinstadler closed 4 years ago

kevinstadler commented 4 years ago

I've...

Describe the bug

After a fresh install of the latest versions of osgeo-postgresql(v12.1) and osgeo-postgis (v2.5), CREATE EXTENSION postgis on a completely new database fails. This is presumably because of some version mismatch, but I haven't been able to get the postgis extension to work with any other postgres installation either (in particular not osgeo-postgresql@10).

This is not the same as #1124, #1174, but may be related to #1283?

2020-02-05 12:43:40.125 CET [42967] ERROR:  could not load library "/usr/local/lib/postgresql/postgis-2.5.so": dlopen(/usr/local/lib/postgresql/postgis-2.5.so, 10): Symbol not found: _AllocSetContextCreateExtended
      Referenced from: /usr/local/lib/postgresql/postgis-2.5.so
      Expected in: /usr/local/Cellar/osgeo-postgresql/12.1/bin/postgres
     in /usr/local/lib/postgresql/postgis-2.5.so
2020-02-05 12:43:40.125 CET [42967] STATEMENT:  CREATE EXTENSION postgis;
ERROR:  could not load library "/usr/local/lib/postgresql/postgis-2.5.so": dlopen(/usr/local/lib/postgresql/postgis-2.5.so, 10): Symbol not found: _AllocSetContextCreateExtended
  Referenced from: /usr/local/lib/postgresql/postgis-2.5.so
  Expected in: /usr/local/Cellar/osgeo-postgresql/12.1/bin/postgres
 in /usr/local/lib/postgresql/postgis-2.5.so

To Reproduce

Steps to reproduce the behavior:

brew install osgeo-postgresql osgeo-postgis
initdb -D dummy
pc_ctl -D dummy start
createdb dummydb
psql -d dummydb
CREATE EXTENSION postgis;

Expected behavior

The postgis extension should be installed on the current database, so that geodata can be impoted.

Additional context

This is my first installation of postgres and postgis, so it is not an issue with upgrading postgis.

fjperini commented 4 years ago

@kevinstadler We are updating the formulas, I fix this!

fjperini commented 4 years ago

@kevinstadler try after merging #1337

alazarolop commented 4 years ago

It should be fixed with the latest release (https://github.com/OSGeo/homebrew-osgeo4mac/pull/1354), could you confirm @kevinstadler ?