pytries / marisa-trie

Static memory-efficient Trie-like structures for Python based on marisa-trie C++ library.
https://marisa-trie.readthedocs.io/en/latest/
MIT License
1.03k stars 91 forks source link

Potential fix for Mac OS Mojave #54

Closed JonathanRaiman closed 2 years ago

JonathanRaiman commented 4 years ago

Dear maintainers, Running into some install issues with wrong headers or missing symbols. Current solution has been to create a single compilation unit and using env-specific C++ stdlib flags during compilation.

Do you have any better suggestions for working around this? I imagine compiling marisa as part of the extension might not be ideal if you intended to skip reinstalling marisa for users who installed it separately (1), and the compiler flags should be changed on an system by system basis (2).

(1) I could not find a way to specific compiler flags for the setup(..., libraries=[(lib, {...<flags go here ?> }]) part of the setup code. I suspect if this is possible, this should now work as intended on mojave.

(2) Detecting mac os v other systems should not be too hard. Given that issues so far have only sprung up on mac os, I am not sure we need anything fancier than "if macOS: add flag else: pass"

BoboTiG commented 3 years ago

Maybe not worth since there are now wheels?