libfreetype issues on Mac OSX Big Sur

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

libfreetype issues on Mac OSX Big Sur

Starfighter
I'm running Matplotlib ver. 3.3.4 under the Anaconda distribution for
Python 3.8.5 on a Mac OS X ver. 11.2. I am getting the following error:


Traceback (most recent call last):
   File "temp.py", line 9, in <module>
     import matplotlib.pyplot as plt
   File
"/Users/user/opt/anaconda3/lib/python3.8/site-packages/matplotlib/__init__.py",
line 174, in <module>
     _check_versions()
   File
"/Users/user/opt/anaconda3/lib/python3.8/site-packages/matplotlib/__init__.py",
line 159, in _check_versions
     from . import ft2font
ImportError:
dlopen(/Users/user/opt/anaconda3/lib/python3.8/site-packages/matplotlib/ft2font.cpython-38-darwin.so,
2): Library not loaded: @rpath/libfreetype.6.dylib
   Referenced from:
/Users/user/opt/anaconda3/lib/python3.8/site-packages/matplotlib/ft2font.cpython-38-darwin.so
   Reason: Incompatible library version: ft2font.cpython-38-darwin.so
requires version 24.0.0 or later, but libfreetype.6.dylib provides
version 23.0.0
(base) user@Mac-Pro ~ %


The python script being used is


#!/Users/user/opt/anaconda3/bin/python

"""
Spyder Editor

This is a temporary script file.
"""

import matplotlib.pyplot as plt
import numpy as np

plt.style.use("ggplot")

t = np.arange(0.0, 2.0, 0.1)
s = np.sin(2 * np.pi * t)
s2 = np.cos(2 * np.pi * t)
plt.plot(t, s, "o-", lw=4.1)
plt.plot(t, s2, "o-", lw=4.1)
plt.xlabel("time (s)")
plt.ylabel("Voltage (mV)")
plt.title("Simple plot $\\frac{\\alpha}{2}$")
plt.grid(True)

plt.savefig("test.png")

plt.show()


Any ideas?


Sam Dupree.


_______________________________________________
Matplotlib-users mailing list
[hidden email]
https://mail.python.org/mailman/listinfo/matplotlib-users