M1 Mac Install Help

60 views
Skip to first unread message

geoffs...@gmail.com

unread,
Dec 19, 2020, 2:44:16 PM12/19/20
to weewx-development
Have got weewx running on M1 mac with python 3.8.2, but a few issues.

Needed to install libjpeg and freetype from source to get a working PIL. This seems to need to be done under the rosetta version of the terminal.

When I start using:
cd /Users/Shared/weewx python3 ./bin/weewxd weewx.conf

It starts fine and runs as expected. In both the console and weewx debug it runs as x86

If I start using:
sudo launchctl load /Library/LaunchDaemons/com.weewx.weewxd.plist

It runs as ARM64 on the console, but is listed as x86 in the debugger output. It has all sorts of problems not being able to mostly find things related to the PIL install.

I've also tried to get the PIL to install using the native terminal, but I get 

/Library/Python/3.8/site-packages/PIL/_imaging.cpython-38-darwin.so: mach-o, but wrong architecture

When I use "import Image from PIL"

Image imports fine when using the rosetta version of the terminal.

Any ideas on either getting a working ARM64 PIL or getting the startup script to run x86?

geoffs...@gmail.com

unread,
Dec 28, 2020, 1:04:07 PM12/28/20
to weewx-development
Solved this by getting python 3.9.1 installed, using ARM64 version of Homebrew to install pyenv for the python install and libjpeg and Freetype to build pillow from source and then installed weewx. All runs as native ARM64.

Vince Skahan

unread,
Dec 28, 2020, 2:09:46 PM12/28/20
to weewx-development
Wow that is a lot of work.  I think I'll hold off for two or three years :-)
Reply all
Reply to author
Forward
0 new messages