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

Link protobuf statically #14

Merged
merged 8 commits into from Jul 4, 2022
Merged

Link protobuf statically #14

merged 8 commits into from Jul 4, 2022

Conversation

nilsnolde
Copy link
Member

@nilsnolde nilsnolde commented Jun 13, 2022

WIP

this will allow the python bindings to link to a static protobuf library which will circumvent problems with the qgis python console. it's a little patchy still, at some point we might want to include tile building and depend on spatialite which will cause the same problem. there's a good chance though that spatialite static is in debian's package manager and is compiled with position-independent-code 🤞

still needs:

  • choose a protobuf tag. probably latest, cmake wasn't introduced until very recently
  • smth is messed up with pre-commit
  • update the manylinux image to have the image built protobuf from source
  • adapt and test windows in qgis (comment: couldn't make static linking of protobuf work on windows, maybe bcs libvalhalla is linking dynamically.. actually it took the protobuf-lite.lib but still the resulting .pyd would, maybe additionally, link to the .dll)
  • adapt and test mac os in qgis 🤞 (didn't actually test it works in qgis, but only built the lib on mac)

@nilsnolde
Copy link
Member Author

so this seems to work for linux now. I'll push the manylinux package for python 3.10 to the network analyst repo, so we have smth to work with in dev. adding macos and win can come later, but should happen before we push to master.

@nilsnolde
Copy link
Member Author

valhalla was also updated to the latest commit

setup.py Outdated Show resolved Hide resolved
nilsnolde and others added 3 commits June 16, 2022 13:31
…for protobuf, maybe it's because libvalhalla is linked dynamically; in any case: seems like QGIS 3.24 is happy with the dynamic protobuf link as well, no weird errors
@nilsnolde nilsnolde merged commit fc3dae9 into master Jul 4, 2022
@nilsnolde nilsnolde deleted the nn-static-protobuf branch July 4, 2022 12:45
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

Successfully merging this pull request may close these issues.

None yet

1 participant