Skip to content

m1 mac w/ homebrew workaround; display glitches #473

@bleything

Description

@bleything

I've been trying to get vpype installed on my m1 mac with homebrew and I think I've made some progress. I'm pretty new to python and I'm not sure if I'm doing anything wrong, so I wanted to share what I've figured out and get some feedback. If it all looks good I'd be happy to put together a PR for the docs.

To begin with, I read #320 and ran into the same problems as @krummrey and @notwaldorf. I tried to follow the advice in that thread, specifically installing numpy and scipy via homebrew, but pretty quickly got into dependency hell. I spent a couple of hours digging in and eventually got stuck because pip couldn't find PySide even when it was installed, linked, and usable. Maybe there's a standard way to tell pip how to find packages but I couldn't figure it out.

Ultimately I decided to start over with pyenv and pyenv-virtualenv to keep things clean. I started by installing those tools and some dependencies:

$ brew install pyenv pyenv-virtualenv geos openblas

Next I ran through the setup instructions in the pyenv and pyenv-virtualenv docs, then installed 3.9.12 and set up a new venv:

$ pyenv install 3.9.12
$ pyenv virtualenv 3.9.12 vpype
$ pyenv activate vpype

Then I installed PySide2 using these instructions but changed the build command for homebrew install dirs:

$ CLANG_INSTALL_DIR=/opt/homebrew/opt/llvm python setup.py install  \
    --qmake=/opt/homebrew/opt/qt@5/bin/qmake --build-tests --ignore-git --parallel=8 --reuse-build

After waiting forever while pyside built, it was pretty smooth sailing:

$ pip install 'vpype[all]'
$ vpype random show

However, every time I quit the viewer I get a segfault. It seems to work okay until I quit, though? There are also some graphical glitches. I took an svg from vsketch's schotter example, rendered on my windows machine where everything's working, and opened it in vpype's viewer. You can see that some of the boxes are not fully closed:

Screen Shot 2022-05-06 at 7 57 06 PM

The classic viewer (and inkscape) render the file correctly so I think it's gotta be an issue somewhere in this vpype install. Unsure if it's a bug or what.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions