2

I've got a new machine with a fresh install of OSX 10.9, and am having trouble getting esri's file geodatabase api to work correctly with my brewed gdal.

This is a known issue, noted here: http://forums.arcgis.com/threads/95958-OS-X-Mavericks

I've tried John Tull's noted workaround:

# install gcc
brew install --enable-cxx gcc49

# noted fgdb/gdal dependency:
brew install libdap --cc="gcc-4.9"

# gdal 
brew install gdal --enable-unsupported --with-postgresql -v --cc="gcc-4.9"

# this points the fgdb libraries at gcc4.9 somehow
install_name_tool -change /usr/lib/libstdc++.6.dylib /usr/local/Cellar/gcc49/4.9-20131103/lib/gcc/x86_64-apple-darwin13.0.0/4.9.0/libstdc++.dylib /usr/local/opt/FileGDB_API/lib/libFileGDBAPI.dylib
install_name_tool -change /usr/lib/libstdc++.6.dylib /usr/local/Cellar/gcc49/4.9-20131103/lib/gcc/x86_64-apple-darwin13.0.0/4.9.0/libstdc++.dylib /usr/local/opt/FileGDB_API/lib/libfgdbunixrtl.dylib

This helps - ogr2info --formats now shows FileGDB as a valid format. However, running ogr2info on a valid filegdb gives this error:

ogrinfo(45386,0x7fff74779310) malloc: *** error for object 0x10b49dde0: pointer being freed was not allocated
*** set a breakpoint in malloc_error_break to debug

Any idea what I'm doing wrong? I tried removing all of the gdal dependencies and letting homebrew reinstall them when calling brew install gdal with the --c"gcc-49" flag but that didn't change anything.

edit - I now see that this issue already has a thread here Homebrew OGR with FGDB support on OSX 10.9

2
  • found the problem. I didn't check the install_name_tool arguments closely enough.
    – snorris
    Jan 2, 2014 at 23:09
  • nope. Fixed the path but that didn't work. I don't understand well enough what the install_name_tool is doing to debug - presuming that is the problem.
    – snorris
    Jan 3, 2014 at 17:33

1 Answer 1

1

Question is answered well enough (by @dakcarto) for my purposes here:

https://github.com/dakcarto/homebrew-osgeo4mac/issues/8

http://forums.arcgis.com/threads/95958-OS-X-Mavericks?p=355416#post355416

Installing the api as a shared gdal plugin seems to be the key.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.