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

runtime error with protobuf 2.6.x #47

Open
tumluliu opened this issue May 28, 2015 · 0 comments
Open

runtime error with protobuf 2.6.x #47

tumluliu opened this issue May 28, 2015 · 0 comments

Comments

@tumluliu
Copy link

I am on OS X 10.10.3, Python 2.7 (Homebrew version). I installed the deps via homebrew and pip, then the 2.6 version of imposm. But it seems that imposm requires 2.5 version of protobuf because I caught a runtime error:

Traceback (most recent call last):
File "osm_parser.py", line 579, in
p.parse('/Users/user/Research/data/OSM/munich.osm.pbf')
File "/Library/Python/2.7/site-packages/imposm/parser/simple.py", line 62, in parse
return self.parse_pbf_file(filename)
File "/Library/Python/2.7/site-packages/imposm/parser/simple.py", line 72, in parse_pbf_file
from imposm.parser.pbf.multiproc import PBFMultiProcParser
File "/Library/Python/2.7/site-packages/imposm/parser/pbf/multiproc.py", line 17, in
from imposm.parser.pbf.parser import PBFFile, PBFParser
File "/Library/Python/2.7/site-packages/imposm/parser/pbf/parser.py", line 23, in
from imposm.parser.pbf import OSMPBF
ImportError: dlopen(/Library/Python/2.7/site-packages/imposm/parser/pbf/OSMPBF.so, 2): Library not loaded: /usr/local/lib/libprotobuf.8.dylib
Referenced from: /Library/Python/2.7/site-packages/imposm/parser/pbf/OSMPBF.so
Reason: image not found

The latest protobuf in homebrew is 2.6.1, and the lib file is libprotobuf.9.dylib. I tried making a symbolic link to libprotobuf.9.dylib by doing

$ ln /usr/local/lib/libprotobuf.9.dylib /usr/local/lib/libprotobuf.8.dylib

But no luck and got a new error:

Traceback (most recent call last):
File "osm_parser.py", line 579, in
p.parse('/Users/user/Research/data/OSM/munich.osm.pbf')
File "/Library/Python/2.7/site-packages/imposm/parser/simple.py", line 62, in parse
return self.parse_pbf_file(filename)
File "/Library/Python/2.7/site-packages/imposm/parser/simple.py", line 72, in parse_pbf_file
from imposm.parser.pbf.multiproc import PBFMultiProcParser
File "/Library/Python/2.7/site-packages/imposm/parser/pbf/multiproc.py", line 17, in
from imposm.parser.pbf.parser import PBFFile, PBFParser
File "/Library/Python/2.7/site-packages/imposm/parser/pbf/parser.py", line 23, in
from imposm.parser.pbf import OSMPBF
ImportError: dlopen(/Library/Python/2.7/site-packages/imposm/parser/pbf/OSMPBF.so, 2): Symbol not found: __ZN6google8protobuf8internal12kEmptyStringE
Referenced from: /Library/Python/2.7/site-packages/imposm/parser/pbf/OSMPBF.so
Expected in: /usr/local/lib/libprotobuf.8.dylib
in /Library/Python/2.7/site-packages/imposm/parser/pbf/OSMPBF.so

So I installed the protobuf at its specific version of 2.5.0 via homebrew:

$ brew unlink protobuf
$ brew install /homebrew/versions/protobuf250

And the problem is solved for the moment. Does imposm really require protobuf exactly at the 2.5 version?

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

No branches or pull requests

1 participant