意外删除了/ opt / local / Library / Frameworks的一部分-无法安装新的macport

时间:2019-02-04 21:33:02

标签: macos macports macos-high-sierra

在MacOS 10.13(高Sierra)上,我不小心删除了/opt/local/Library/Frameworks的一部分,例如python软件包(我没有更多的python3.6和其他相关软件包)。

当我想安装python36软件包时,我会收到很多警告,最后是错误,这些错误会阻止安装(完整日志可在this link上找到)

例如:

   sudo port -f install python36
    --->  Computing dependencies for python36
    --->  Cleaning python36
    --->  Scanning binaries for linking errors
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Cipher/_AES.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Cipher/_ARC2.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Cipher/_ARC4.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Cipher/_Blowfish.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Cipher/_CAST.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Cipher/_DES.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Cipher/_DES3.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Cipher/_XOR.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Hash/_MD2.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Hash/_MD4.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Hash/_RIPEMD160.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Hash/_SHA224.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Hash/_SHA256.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Hash/_SHA384.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Hash/_SHA512.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/PublicKey/_fastmath.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Util/_counter.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/Crypto/Util/strxor.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/libxml2mod.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/zmq/backend/cython/_device.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/zmq/backend/cython/_poll.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/zmq/backend/cython/_version.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/zmq/backend/cython/constants.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/zmq/backend/cython/context.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/zmq/backend/cython/error.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/zmq/backend/cython/message.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/zmq/backend/cython/socket.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/zmq/backend/cython/utils.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/zmq/devices/monitoredqueue.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/readline/gnureadline.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/_scandir.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pcapy.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/_pcapmodule.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/gtk-2.0/atk.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/gtk-2.0/gtk/_gtk.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/gtk-2.0/gtk/glade.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/gtk-2.0/gtkunixprint.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/gtk-2.0/pango.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/gtk-2.0/pangocairo.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/gupnp/igd.so: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/bin/wxrc-3.0: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/lib/libwx_baseu-3.0.0.4.0.dylib: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/lib/libwx_baseu_net-3.0.0.4.0.dylib: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/lib/libwx_baseu_xml-3.0.0.4.0.dylib: Error opening or reading file
    Warning: Error parsing file /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/lib/libwx_osx_cocoau_adv-3.0.0.4.0.dylib: Error opening or reading file

... ..... .....

The following ports will be rebuilt:
 fontforge @20170731+python27
 gnuplot @5.2.6+aquaterm+luaterm+pangocairo+wxwidgets+x11
 gstreamer1-gst-plugins-bad @1.14.4+x11
 libpeas @1.22.0+python27+python36
Continue? [Y/n]: Y
--->  Computing dependencies for fontforge
--->  Cleaning fontforge
--->  Computing dependencies for gnuplot
--->  Cleaning gnuplot
--->  Computing dependencies for gstreamer1-gst-plugins-bad
--->  Building gstreamer1-gst-plugins-bad
Error: Failed to build gstreamer1-gst-plugins-bad: command execution failed
Error: See /opt/local/var/macports/logs/_opt_local_var_macports_sources_www.macports.org_files_ports_gnome_gstreamer1-gst-plugins-bad/gstreamer1-gst-plugins-bad/main.log for details.
Error: rev-upgrade failed: Error rebuilding gstreamer1-gst-plugins-bad
Error: Follow https://guide.macports.org/#project.tickets to report a bug.

如何避免所有这些警告和错误?

我该怎么做才能还原以前的安装,以及必须以其他方式修复这种情况?

我已经测试了port -f install python36和其他选项,但是安装过程总是中止。

解决方案可能是macport的一些替代工具?

谢谢

0 个答案:

没有答案