1、XCode7無(wú)證書(shū)真機(jī)調(diào)試教程
1、xcode版本大于等于7
2、進(jìn)入xcode,在菜單欄選擇xcode->preferences,在Accounts選項(xiàng)卡添加自己的Apple ID。
3、在項(xiàng)目導(dǎo)航欄中選擇要真機(jī)調(diào)試的項(xiàng)目,在工作區(qū)的targets選擇要測(cè)試的項(xiàng)目(一般就是項(xiàng)目名稱)
4、選擇General選項(xiàng)卡,展開(kāi)Identity項(xiàng),修改下面的team選項(xiàng)為你剛才添加的Apple ID
5、把你需要真機(jī)調(diào)試的設(shè)備連上電腦
6、在剛才team選項(xiàng)的下面此時(shí)多了一個(gè)警告,點(diǎn)擊Fix Issue,等待xcode處理完,這個(gè)警告就消失了。
7、在Build Settings中設(shè)置Code Signing Identify和Provisioning Profile。
設(shè)置Code Signing Identify為剛剛添加的AppleID,Profile設(shè)置為Automatic即可。
2、Xcode真機(jī)測(cè)試could not find developer disk image解決方法
在使用Xcode進(jìn)行真機(jī)調(diào)試的時(shí)候,有時(shí)根據(jù)真機(jī)的系統(tǒng)不同,會(huì)出現(xiàn)could not find developer disk image 錯(cuò)誤,這是由于真機(jī)系統(tǒng)過(guò)高或者過(guò)低,Xcode中沒(méi)有匹配的配置包文件,我們可以通過(guò)這個(gè)路徑進(jìn)入配置包的存放目錄:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport
里面有類似這樣的一些文件夾,如果這些文件夾中沒(méi)有包含我們真機(jī)的系統(tǒng),則不能進(jìn)行真機(jī)測(cè)試。但是我們可以通過(guò)將相應(yīng)的配置包添加入這個(gè)文件夾來(lái)解決問(wèn)題
這個(gè)鏈接里面有從iOS4.2到9.1所有版本的配置包
3、錯(cuò)誤
Xcode 7 運(yùn)行項(xiàng)目報(bào)錯(cuò):
錯(cuò)誤1. Undefined symbols for architecture armv7:
"_compress2", referenced from:
+[UMANDeflated deflatedDataPrefixedWith:level:source:] in libMobClickLibrary.a(UMDeflated.o)
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
錯(cuò)誤2. *** does not contain bitcode. You must rebuild it with bitcode enabled (Xcode setting ENABLE_BITCODE), obtain an updated library from the vendor, or disable bitcode for this target. for architecture armv7
Xcode默認(rèn)是要支持bitcode的,而且如果支持的話,其中所有的二進(jìn)制庫(kù)和framework都必須包含bitcode.至于什么是bitcode,請(qǐng)看這里: http://blog.csdn.net/soindy/article/details/48518717
解決方法:
在Build Settings中把bitcode關(guān)掉。

4、問(wèn)題
launch failed: Security
解決方法:
在真機(jī)的設(shè)置中,找到通用,在通用里面找到設(shè)備管理。點(diǎn)擊開(kāi)發(fā)商應(yīng)用,信任開(kāi)發(fā)者,就可以了。