iOS Real-Computer debugging

Source: Internet
Author: User

Note: Modify the configuration file, prepare the script, etc. before this stage, only need to do once. But the operation of this stage, for each need to debug the real machine to do the work once.

① Disabling the Xcode automatic signature operation

All of the Code signing options in the project configuration "Build Settings" are set to "T code sign".

② Add a custom post-build script in build phases, click the "+" sign in the upper-left corner, add a "New Run script Phase" and enter the following script:

Export codesign_allocate=/applications/xcode.app/contents/developer/platforms/iphoneos.platform/developer/usr/ Bin/codesign_allocate
if ["${platform_name}" = = "Iphoneos"] | | ["${platform_name}" = = "Ipados"]; Then
/applications/xcode.app/contents/developer/iphoneentitlements/gen_entitlements.py "My.company.${PROJECT_NAME}" " ${built_products_dir}/${wrapper_name}/${project_name}.xcent ";
Codesign-f-S "IPhone Developer"--entitlements "${built_products_dir}/${wrapper_name}/${project_name}.xcent" "${ built_products_dir}/${wrapper_name}/"
Fi

Shell Script Invocation error solution appears in Xcode real-time test

Solution:

See if the run script in build phase is written correctly, and you can delete it if necessary.

or tick the run script only when installing

iOS Real-Computer debugging

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.