LoginSignup
8
8

More than 5 years have passed since last update.

MacPortsのアンインストール&Homebrewのインストール

Last updated at Posted at 2014-05-16

はてなにメモってた過去記事を再掲シリーズ(ちょっと古いかもしれない)

問題

ある時から
$ sudo port selfupdate
すると

--->  Updating MacPorts base sources using rsync
MacPorts base version 2.0.3 installed,
MacPorts base version 2.1.3 downloaded.
--->  Updating the ports tree
--->  MacPorts base is outdated, installing new version 2.1.3
Installing new MacPorts release in /opt/local as root:admin; permissions 0755; Tcl-Package in /Library/Tcl

Error: /opt/local/bin/port: port selfupdate failed: Error installing new MacPorts base: shell command failed (see log for details)

て言われるように。

まずはMacPortsのアンインストール

$ sudo port -fp uninstall --follow-dependents installed

%% sudo rm -rf \
    /opt/local \
    /Applications/DarwinPorts \
    /Applications/MacPorts \
    /Library/LaunchDaemons/org.macports.* \
    /Library/Receipts/DarwinPorts*.pkg \
    /Library/Receipts/MacPorts*.pkg \
    /Library/StartupItems/DarwinPortsStartup \
    /Library/Tcl/darwinports1.0 \
    /Library/Tcl/macports1.0 \
    ~/.macports

環境変数から/opt/local系を削除

$ emacs ~/.bash_profile

次にHomebrewのインストール

$ ruby -e "$(curl -fsSL https://raw.github.com/mxcl/homebrew/go)"

試しに何かインストール

$ brew install git

8
8
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
8
8