ksaitoの日記

日々試したことの覚え書き

Macのパッケージ管理システム MacPorts

移転しました。

自動的にリダイレクトします。

Macには、Debianのaptに相当するMacPortsというパッケージ管理システムがあります。
Mac PortsからMacPorts-1.7.1.pkgをダウンロードしてインストールすると使えるようになります。

インストール後の動作確認は、下記コマンドでMacPortsのバージョンが表示されます。

bash-3.2$ port version
Version: 1.710
bash-3.2$

aptでよく使うコマンドは、MacPortsでは、下記のようになります。

apt MacPorts
利用可能パッケージ一覧表示 apt-cache pkgnames port list
パッケージのインストール aptptitude install [パッケージ名] port install [パッケージ名]
インストール済みパッケージ一覧表示 dpkg -l port installed
パッケージのファイル一覧表示 dpkg -L [パッケージ名] port contents [パッケージ名]
パッケージリストの更新 aptitude update port sync
パッケージのアップグレード aptitude safe-upgrade port upgrade outdated
パッケージの削除 aptitude purge [パッケージ名] port uninstall [パッケージ名]
パッケージのクリーンナップ port -f install installed
パッケージ管理システム自身のアップグレード port selfupdate