68-245-171-115:var fanshulin$ sudo port -v selfupdate
解决方法如下:
1.搜索到了官网的连接,http://trac.macports.org/ticket/36256,根据指引到达了
http://trac.macports.org/wiki/howto/PortTreeTarball
2.看到如下说明:
Configuration
Edit $prefix/etc/macports/sources.conf, comment out the rsync entry, and add a new entry as follows:
#rsync://rsync.macports.org/release/ports/ [default] http://www.macports.org/files/ports.tar.gz [default]
直接编辑source.conf 是不行的,拷贝到桌面记事本打开
添加上上去,如下:
//rsync://rsync.macports.org/release/tarballs/ports.tar [default]
#rsync://rsync.macports.org/release/ports/ [default]
http://www.macports.org/files/ports.tar.gz [default]
3.把这个文件拷贝覆盖
4. sudo port -v selfupdate
5.正常更新,21M的包,如下:
68-245-171-115:var fanshulin$ sudo port -d sync
Password:
Warning: /opt/local/etc/macports/sources.conf specifies invalid source '//rsync://rsync.macports.org/release/tarballs/ports.tar [default]', ignored.
DEBUG: Copying /Users/fanshulin/Library/Preferences/com.apple.dt.Xcode.plist to /opt/local/var/macports/home/Library/Preferences
---> Updating the ports tree
Synchronizing local ports tree from http://www.macports.org/files/ports.tar.gz
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 21.5M 100 21.5M 0 0 32451 0 0:11:36 0:11:36 --:--:-- 81848
问题解决,xxoo,路还很长啊,我本是要装opencv的。