lordmauve / lepton

Lepton: A high-performance, pluggable particle engine and API for Python
https://pythonhosted.org/lepton/
MIT License
7 stars 1 forks source link

pip install fails on OSX 10.13.1 #1

Open lordmauve opened 6 years ago

lordmauve commented 6 years ago

Reported by @numberoverzero on the Bitbucket repo.

Thanks for making an awesome library! I wanted to try out the fireworks demo, but kept running into a compile error- clang didn't recognize "-framework:OpenGL":

clang -bundle -undefined dynamic_lookup -L/usr/local/opt/tcl-tk/lib build/temp.macosx-10.13-x86_64-3.6/lepton/group.o build/temp.macosx-10.13-x86_64-3.6/lepton/groupmodule.o -L/usr/local/lib -L/usr/local/opt/openssl/lib -L/usr/local/opt/sqlite/lib -L/usr/local/opt/tcl-tk/lib -o build/lib.macosx-10.13-x86_64-3.6/lepton/group.cpython-36m-darwin.so -framework:OpenGL
clang: error: unknown argument: '-framework:OpenGL'
error: command 'clang' failed with exit status 1

I swapped line 35:

-extra_link_args = ['-framework:OpenGL']
+extra_link_args = ['-framework', 'OpenGL']

and installation succeeded with:

env CC=/usr/local/bin/gcc pip install .

It would be really nice if there were OSX wheels, but that can be tedious, esp. for platforms you don't work on. Still, it was a very nice demo. Thanks again!

lordmauve commented 6 years ago

Thank you, this is useful.

I'm not the original author though, just maintaining. The original author is Casey Duncan. I'm not sure whether the original worked in some context (perhaps we only need to change that framework argument for clang?)

I have been working on building wheels. I will try to get some wheels building on Travis, and see if this fix helps.