blog.sorah.jp

Xcode 4.3 を入れました。

Xcode 4.3 を入れました。

Xcode 4.3 または CLI tools を入れた話 , デブサミ2012 の写真 - HsbtDiary(2012-02-18) 等で言及されていたのは行かの点:

  • /Developer がなくなって、/Applications/Xcode.app/Contents/Developer になるらしい
  • /usr/bin/gcc などは別パッケージになる
  • autoconf さようなら

とりあえず自分は Mac App Store で入れるのが嫌いなので dmg を developer.apple.com から引っ張ってこようと思ったら "View in Mac App Store" とか書いてあるの。

その下にある Additional Downloads から "Xcode 4.3 for Lion (xcode_4.3_for_lion.dmg)" と "Command Line Tools for Xcode (command_line_tools_for_xcode_.dmg)" をダウンロードしてきた。

Xcode 4.2 まではパッケージだったが今回から dmg には Xcode.app 一つが入っていた。Applications にコピーして終わる。 起動した後は Xcode に iOS Devices 関係のパッケージを入れろと言われたけれど。

あと、 HDD 容量 7GB ほど節約できるという内容の記事 (XcodeからCommand Line Tools for Xcodeに切り替えたらHDD使用容量が7GB減った - Glide Note - グライドノート) があったので自分でも調べた。

Filesystem      Size   Used  Avail
/dev/disk1      120G   108G   9.1G # Xcode 4.2 削除前
/dev/disk1      120G   108G    12G # Xcode 4.2 削除後
/dev/disk1      120G   112G   8.4G # Xcode.app コピー直後
/dev/disk1      120G   112G   8.4G # Xcode.app 起動後、iOS Devices の接続周りのパッケージをインストールした後
/dev/disk1      120G   112G   7.8G # CLI ツールインストール後

9.1 - 7.8 = 1.3 (GB) と Xcode 4.3 にアップデートしたら使用容量が増えました \(o)/ (iOS の開発とかするから仕方ない。我慢しよう。)

測定と Xcode 4.2 の削除は以下:

  • 容量の測定は df -H
  • Xcode 4.2 の削除は sudo /Developer/Library/uninstall-devtools --mode=all

あと、残念ながら autoconf は無かった。

homebrew-alt から引っ張ってくる。

$ brew install https://raw.github.com/adamv/homebrew-alt/master/duplicates/autoconf.rb
######################################################################## 100.0%
==> Downloading http://ftpmirror.gnu.org/autoconf/autoconf-2.68.tar.gz
######################################################################## 100.0%
==> ./configure --prefix=/Users/sorah/brew/Cellar/autoconf/2.68
==> make install
==> Caveats
This formula is keg-only, so it was not symlinked into /Users/sorah/brew.

The OSX shipped autoconf is more than 5 years old, and missing many
critical bug-fixes compared with the latest upstream.
In order to prevent conflicts with the system autoconf, this formula
is keg-only.

Generally there are no consequences of this for you.
If you build your own software and it requires this formula, you'll need
to add its lib & include paths to your build variables:

    LDFLAGS  -L/Users/sorah/brew/Cellar/autoconf/2.68/lib
    CPPFLAGS -I/Users/sorah/brew/Cellar/autoconf/2.68/include
==> Summary
/Users/sorah/brew/Cellar/autoconf/2.68: 66 files, 2.6M, built in 16 seconds
$ brew link autoconf

そして一応 xcode-switch しておく

$ sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer

これで終わり。

Backfilled at , Published at