Tag:

链接器命令失败,退出代码1

我在构buildIOS项目时遇到了一些错误和警告 ld: warning: directory not found for option '-L/Users/parikshitpatel/Documents/IphoneDevelopment/FH/funkiorangemobile_iphonehealthadviceapp/Social' ld: warning: directory not found for option '-LMedia/Twitter/Twitter' ld: warning: directory not found for option '-LLibrary/Libraries' ld: warning: directory not found for option '-L/Users/parikshitpatel/Documents/IphoneDevelopment/FH/funkiorangemobile_iphonehealthadviceapp0/Social' ld: warning: directory not found for option '-L&' ld: warning: directory not found for option '-LHeaders' ld: warning: directory not found for […]

没有find框架-fobjc-arc

我安装了Spark Inspector,看看它是什么样的。 我不确定,但我认为这导致了椰子树的问题。 我正在尝试删除它们。 我已经修复了大部分内容,但是我没有收到构build错误… framework not found -fobjc-arc 我不知道从哪里开始,因为我找不到一个这样的框架,我以前从来没有见过这个错误。 请有人指出我正确的方向。

当构buildArchive时,叮当失败,退出代码1,在构buildDebug时工作

我的构build设置显示了我的开发人员调配configuration文件的debugging和发行和分配scheme的我的分发调配configuration文件。 我已经validation我的分发configuration文件是最新的,并且不会在2012年8月之前过期,所以这不是问题。 Ld /Users/kenny/Library/Developer/Xcode/DerivedData/MyAppName-fxknidnbrepotqdvhgjnepxdhonz/ArchiveIntermediates/BalanceSheet/IntermediateBuildFilesPath/MyAppName.build/Release-iphoneos/MyAppName.build/Objects-normal/armv6/MyAppName normal armv6 cd /Users/kenny/MyLib2/svn-MyAppName-iOS/trunk/MyAppName setenv IPHONEOS_DEPLOYMENT_TARGET 3.2 setenv PATH "/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin" /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/clang -arch armv6 -isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.0.sdk -L/Users/kenny/Library/Developer/Xcode/DerivedData/MyAppName-fxknidnbrepotqdvhgjnepxdhonz/ArchiveIntermediates/BalanceSheet/BuildProductsPath/Release-iphoneos -L/Users/kenny/MyLib2/svn-MyAppName-iOS/trunk/MyAppName -L/Users/kenny/MyLib2/svn-MyAppName-iOS/trunk/MyAppName/../../../svn-Flurry/trunk/FlurryLib -F/Users/kenny/Library/Developer/Xcode/DerivedData/MyAppName-fxknidnbrepotqdvhgjnepxdhonz/ArchiveIntermediates/BalanceSheet/BuildProductsPath/Release-iphoneos -filelist /Users/kenny/Library/Developer/Xcode/DerivedData/MyAppName-fxknidnbrepotqdvhgjnepxdhonz/ArchiveIntermediates/BalanceSheet/IntermediateBuildFilesPath/MyAppName.build/Release-iphoneos/MyAppName.build/Objects-normal/armv6/MyAppName.LinkFileList -dead_strip -ObjC -all_load -miphoneos-version-min=3.2 -weak_framework Twitter /Users/kenny/Library/Developer/Xcode/DerivedData/MyAppName-fxknidnbrepotqdvhgjnepxdhonz/ArchiveIntermediates/BalanceSheet/BuildProductsPath/Release-iphoneos/libfacebook_ios_sdk.a -lMyLib_Networking -lMyLib_AdWhirl -lMyLib_ApplicationCore -lMyLib_Audio -framework Foundation -framework UIKit -framework CoreGraphics -framework CoreData -framework AudioToolbox -framework SystemConfiguration -weak_framework iAd -framework QuartzCore -framework CoreLocation -framework […]

不兼容的指针types,用'BaseClass *'types的expression式初始化'SubClass * __ strong'

在Objective-C中,为什么我们不能用超类来分配+ init或new的基类对象,而我们可以使用超类的构造函数来初始化? 下面是一些代码: s1可以很舒适地创build。 NSMutableString *s1=[NSString string]; NSLog(@"%@",s1); 但s2和s3不能,并给出警告 Incompatible pointer types initializing 'SubClass *__strong' with an expression of type'BaseClass *' NSMutableString *s2=[[NSString alloc] init]; NSLog(@"%@",s2); NSMutableString *s3=[NSString new]; NSLog(@"%@",s3); //here no warning. id mem=[NSString alloc]; NSMutableString *s4=[mem init]; NSLog(@"%@",s4); 当我们将alloc + init分解为两个不同的语句时会发生什么?

如何为ios模拟器交叉编译llvm / clang?

export CC="clang -arch i386 -mios-version-min=5.0 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk" export CXX="clang++ -arch i386 -mios-version-min=5.0 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk" ../llvm_34_ios/configure –prefix=/Users/admin/llvm_34_ios_i386_installed –host=i386-apple-darwin11 –enable-optimized –disable-assertions unset CC CXX make 我收到错误: llvm[1]: Building Intrinsics.gen.tmp from Intrinsics.td error:ERROR: Couldn't find the `Intrinsic' class! make[1]: *** [/Users/admin/Documents/dev/src/llvm_34_build_i386/lib/IR/Release/Intrinsics.gen.tmp] Error 1

警告:格式string不是一个string文字

我得到“格式string不是string文字”警告从下面的行 NSString *formattedString = [[NSString alloc] initWithFormat:format arguments:valist]; 我在下面的函数中使用这个 – (void)logMessage:(NSString *)format level:(LoggingLevel)level withParameters:(va_list)valist { if (level >= self.loggingLevel) { NSString *formattedString = [[NSString alloc] initWithFormat:format arguments:valist]; } 任何想法如何解决这个问题? 我正在使用Xcode 4.6.3

ObjC ARC收缩(铿锵崩溃)

我总是犹豫在这里的杀手论坛上添加一个全新的问题,但是我没有看到任何接近这个bug的东西。 似乎铿锵在编译我的一个.m文件时崩溃了。 如果有人已经看到或知道下面的任何解决scheme,我会非常感激。 当我在使用XCode 4.4.1的版本configuration中构buildarmv6时会发生此错误 但是,当我在debuggingconfiguration中构buildarmv6时,或者为armv7,armv7s或i386发布时,不会发生这种情况 。 具体的错误是“ObjC ARC收缩”: 1. <eof> parser at end of file 2. Code generation 3. Running pass 'Function Pass Manager' on module '/Users/Me/Documents/ThisProject/iOS/…./ClassFoo.m'. 4. Running pass 'ObjC ARC contraction' on function '@"\01-[ClassFoo evalJS:]"' clang: error: unable to execute command: Segmentation fault: 11 clang: error: clang frontend command failed due to […]

基于iOS Swift的dynamic框架中的Objective C类

情况: 我有一个用Swift编写的iOS dyanmic框架。 我还得到了一堆用Objective C编写的类,我将在Swift类中使用这些类(有些是公共的,有些是私有的)。 不过 ,我希望Objective C类不要暴露在使用框架的项目中 。 我曾经尝试过: 伞头 据我所知,我应该在我的伞头文件(通常是FrameworkName.h使用#import header.h导入,然后确保我希望包含在Swift类中的所有Objective C头文件都标记为“公共”,在“构build阶段” – >“标题”下。 但是,这样做会自动将项目使用框架公开给框架使用的所有私有Objective C类。 模块映射(使用单独的模块) 正因为如此,我研究了使用模块映射,这是logging在这里 。 我已经看过其他用户的post,比如这个和这个 ,以及这个Github的回购 。 我成功地得到了以下工作: //SharedClasses/module.modulemap module SharedClasses { } //SharedClasses/module.private.modulemap module SharedClasses.Private { header "header.h" export * } 问题是,在我的项目(有这个框架导入),这个: import Framework import Framework.SharedClasses 被允许,随后“隐藏的”Objective C类被暴露。 也许这只是模块如何工作? 有没有办法让他们真正的私人? 模块映射(使用框架私有模块) 另外,我已经尝试在我的框架的根目录下创build一个module.private.modulemap文件,内容如下: explicit module Framework.Private { header […]

忽略与财产有关的警告

当我使用有效的架构时,我想忽略这些警告:arm64 armv7 armv7s 这些types的警告出现在许多标题中。 我想忽略这些警告,就像叮当对不推荐使用的警告。 #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wdeprecated-declarations" 我想这样或任何编译器标志忽略这些警告

找不到RestKit / RestKit.h文件错误 – 版本0.10.0

我试图让RestKitbuild立和工作,我正在失去我的头发。 我得到了可怕的“词法或预处理器问题:找不到RestKit / RestKit.h文件”消息。 我使用Xcode 4.2和我的项目是为iOS。 此前,我有debugging模式与RestKit 0.9.0完美的工作。 然后我在试图归档时遇到了问题。 在阅读这个论坛并尝试一些解决scheme后,我决定升级到0.10.0,希望能够解决这个问题。 现在,我的项目甚至没有build立在debugging模式,我得到了相同的RestKit / RestKit.h文件未find错误。 我有这个在标题searchpath下:“$(BUILT_PRODUCTS_DIR)/../../ Headers”。 你能build议(对于0.10.0版本):1)RestKit的物理位置应该在哪里? (这可能没有关系,但是哪一个为你工作 – 我希望能够反映你的设置)2)我试图把我的头部searchpath指向“/ Developer / Library / RestKit-RestKit-69adee9 /”, /开发/库/ RestKit-RestKit-69adee9 /编译” 完全困惑和沮丧.. 编辑1:几个小时后,我放弃了。 编辑我的项目。 创build了一个新的项目。 重新创build文件(从prev项目复制粘贴)。 现在“RestKit not found”错误消失了! 但现在,我得到这个其他的错误: Undefined symbols for architecture i386: "_OBJC_CLASS_$_RKObjectMapping", referenced from: objc-class-ref in myclassname1.o "_OBJC_CLASS_$_RKObjectManager", referenced from: objc-class-ref in myclassname2.o ld: […]