Xcode7 Creating a PCH File

Source: Internet
Author: User

1. Open the Xcode 7.2 Project, on the toolbar at the top of the screen, select File>new>file. >IOS>OTHER>PCH File, click "Next" Next

2. File name, if the project name is "ABC", then the PCH file name is "Abc-prefix.pch",

3. The content of the newly created PCH file is as follows;

4. Click Project projet> Bulid Settings > Search "Prefix Header";

5. After searching, locate the Apple LLVM 7.0-language > Double-click the Prefix Header;

6. Enter PROJECTNAME/PROJECTNAME-PREFIX.PCH. Just like the "abc/abc-prefix.pch" we created;

7. Set the Precomplie Prefix Header to Yes, and the precompiled PCH file will be cached to improve compilation speed.

8.Clean and Build Project Project

Note: $ (srcroot) is now invalid, so set to a relative path in the project folder, such as project name/project name-PREFIX.PCH. Also, simply dragging the PCH file into the header generates an absolute path rather than a relative path;

PS: Thank the original author, looked for several, this just get it done. If it's helpful to you, go and give the original author a reward.

Text/Dongshen Notes "Jane book author"
Original link: Xcode7 add pch File
Copyright belongs to the author, please contact the author to obtain authorization, and Mark "book author".

Xcode7 Creating a PCH File

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.