LoginSignup
54
38

More than 5 years have passed since last update.

XCODEでデバッグビルドとリリースビルドを切り替える方法

Last updated at Posted at 2017-01-22

XCodeのビルドにはデバッグビルドとリリースビルドっていう2種類がある。

デバッグビルドとリリースビルドを切り替える方法

1.プロジェクト名をクリックする
スクリーンショット 2017-01-22 14.44.16.png

2.Edit Scheme...をクリクする
スクリーンショット 2017-01-22 14.42.20.png

3.Build ConfigurationでDebugとReleaseを切り替える
スクリーンショット 2017-01-22 14.52.33.png

DebugとReleaseの違い

最大の違いは、リリースビルドでは最適化が行われるということ。なのでデバッグビルドに比べて高速に動作する。

Debugビルドのときだけ実行されるコード

#ifdef DEBUG
        NSLog(@"DEBUGのときのみ実行される");
#endif
54
38
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
54
38