LoginSignup
0
0

More than 5 years have passed since last update.

Clangコマンドから pchファイルの生成と使用方法

Last updated at Posted at 2015-02-21

1. pchファイルを生成する方法

clang -x [langage]-header test.h -o test.h.pch

[langage]部分は以下が存在する。

  • c
  • c++
  • objective-c

2. pchファイルを使用する方法

clang -include test.h main.c -o main.o

-include オプションで使用するpchファイルを指定する。
上記の場合、test.hのpchファイルが最初に存在するかどうかclangはチェックを行う。

0
0
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
0
0