Info

Mac OS X Package (.pkg) Installer 使えばGUI環境でインストールできるが、今回はソースコードからインストールするようにした。

1. http://distfiles.macports.org/MacPorts/ から MacPorts-*.*.*.tar.gz ファイルをダウンロード。

2. 解凍する。

$ tar xzvf MacPorts-*.*.*.tar.gz

3. インストール

$ cd MacPorts-*.*.*
$ ./configure
$ make
$ sudo make install

4. 確認

$ ls -l /opt/local/
total 8
drwxr-xr-x  7 root  admin  238  1 21 12:42 bin
drwxr-xr-x  3 root  admin  102  1 21 12:42 etc
drwxr-xr-x  2 root  admin   68  1 21 12:42 include
drwxr-xr-x  3 root  admin  102  1 21 12:42 lib
drwxr-xr-x  2 root  admin   68  1 21 12:42 libexec
lrwxr-xr-x  1 root  admin    9  1 21 12:42 man -> share/man
drwxr-xr-x  2 root  admin   68  1 21 12:42 sbin
drwxr-xr-x  7 root  admin  238  1 21 12:42 share
drwxr-xr-x  2 root  admin   68  1 21 12:42 src
drwxr-xr-x  3 root  admin  102  1 21 12:42 var
drwxr-xr-x  2 root  admin   68  1 21 12:42 www
$

5. 環境変数の追加

$ export PATH=/opt/local/bin:/opt/local/sbin/:$PATH
$ export MANPATH=/opt/local/man:$MANPATH

6. 最新状態に更新

$ sudo port selfupdate

Comments

No comments yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Basic HTML is allowed. Your email address will not be published.

Subscribe to this comment feed via RSS