2011-02-18 67 views
0

爲什麼在嘗試安裝我的iPhone應用程序時出現以下錯誤?安裝iPhone應用程序時,爲什麼會出現CGContext錯誤?

warning: Unable to read symbols for /Library/MobileSubstrate/MobileSubstrate.dylib (file not found). 
warning: Unable to read symbols for /Library/Frameworks/CydiaSubstrate.framework/Libraries/SubstrateLoader.dylib (file not found). 
2011-02-18 21:57:05.038 Catalog Dev[399:307] MS:Notice: Installing: com.yourcompany.Catalog-Dev [Catalog Dev] (550.32) 
2011-02-18 21:57:05.210 Catalog Dev[399:307] MS:Notice: Loading: /Library/MobileSubstrate/DynamicLibraries/Activator.dylib 
warning: Unable to read symbols for /Library/MobileSubstrate/DynamicLibraries/Activator.dylib (file not found). 
2011-02-18 21:57:05.518 Catalog Dev[399:307] MS:Notice: Loading: /Library/MobileSubstrate/DynamicLibraries/sandcastleclient.dylib 
warning: Unable to read symbols for /Library/MobileSubstrate/DynamicLibraries/sandcastleclient.dylib (file not found). 
warning: Unable to read symbols for /Developer/Platforms/iPhoneOS.platform/DeviceSupport/4.0.2/Symbols/usr/lib/libsubstrate.dylib (file not found). 
Fri Feb 18 21:57:11 Moes-iPhone Catalog Dev[399] <Error>: CGContextDrawImage: invalid context 0x0 
Fri Feb 18 21:57:11 Moes-iPhone Catalog Dev[399] <Error>: CGContextSetStrokeColorWithColor: invalid context 0x0 
Fri Feb 18 21:57:11 Moes-iPhone Catalog Dev[399] <Error>: CGContextSetLineWidth: invalid context 0x0 
Fri Feb 18 21:57:11 Moes-iPhone Catalog Dev[399] <Error>: CGContextMoveToPoint: invalid context 0x0 
Fri Feb 18 21:57:11 Moes-iPhone Catalog Dev[399] <Error>: CGContextAddLineToPoint: invalid context 0x0 
Fri Feb 18 21:57:11 Moes-iPhone Catalog Dev[399] <Error>: CGContextAddLineToPoint: invalid context 0x0 
Fri Feb 18 21:57:11 Moes-iPhone Catalog Dev[399] <Error>: CGContextAddLineToPoint: invalid context 0x0 
Fri Feb 18 21:57:11 Moes-iPhone Catalog Dev[399] <Error>: CGContextAddLineToPoint: invalid context 0x0 
Fri Feb 18 21:57:11 Moes-iPhone Catalog Dev[399] <Error>: CGContextDrawPath: invalid context 0x0 
Fri Feb 18 21:57:11 Moes-iPhone Catalog Dev[399] <Error>: CGBitmapContextCreateImage: invalid context 0x0 
+0

玉傢伙我解決了問題,我有一個丟失的圖像文件: – user607149 2011-02-19 21:20:06

回答

0

如果您已經創建了一個應用程序,利用第三方框架(CydiaSubstrate.framework,例如),你將不得不在該框架複製到你的應用程序包內的文件夾Frameworks

在Xcode中自動執行此過程的優秀教程可以在here找到。

更新:

<Error>: CGContextDrawImage: invalid context 0x0 

此錯誤表明,你已經打了一個電話給CGContextDrawImage但沒有指定一個有效的CGContextRef說法。沒有看到相關的代碼,我不得不猜測發生了什麼。原型爲CGContextDrawImage如下:

void CGContextDrawImage (
    CGContextRef c, 
    CGRect rect, 
    CGImageRef image 
); 

第一個參數必須是一個有效graphics context,通常在當前圖形上下文,訪問如下:

CGContextRef myContext = [[NSGraphicsContext currentContext] graphicsPort]; 
... 
CGContextDrawImage(myContext, someRect, someImage); 
+0

仍然收到此錯誤的隊友, 週五02月18日22時59分28秒ralabajis-iPhone目錄開發[2633] :CGContextDrawImage:無效的上下文爲0x0 週五02月18日22時59分28秒ralabajis-iPhone目錄開發[2633] :CGContextSetStrokeColorWithColor:無效的情況下爲0x0 週五02月18日22時59分28秒ralabajis-iPhone目錄開發[2633] :CGContextSetLineWidth:無效的情況下爲0x0 – user607149 2011-02-18 20:08:38

+0

它似乎沒有找到圖像的任何解決方案? – user607149 2011-02-18 20:15:22

0

看來你要安裝的應用程序她的部署目標是大於你的iPhone操作系統版本。 Xcode抱怨說他正在搞亂你的代碼試圖使用的一些lybreris。

相關問題