could not changeimport executablee permissions怎么办

女孩初中毕业学什么好
图片主题推荐:
,,,,,,,,,,,,,,,,,,,,,,,,,原因:在手机里已经有一个使用同样bundle identifier的应用;
解决方法:删掉那个应用后在build。
阅读(...) 评论()Jake Bonham*dispatch_once优化代码性能
有些变量只需要初始化一次(如从文件中读取配置参数,读取设备型号等等),可以使用dispatch_once来进行读取优化,保证只调用API一次,以后就只要直接访问变量即可
范例如下:
static BOOL isTestM
+ (BOOL)isTestMode
&&& static dispatch_once_t onceT
&&& dispatch_once(&onceToken, ^{
&&&&&&& NSNumber* obj = [[[NSBundle mainBundle] infoDictionary] objectForKey:@&CFResourceTest&];
&&&&&&& isTestMode = [obj boolValue];
&&& return isTestM
*.NSAssert()的妙用:
开发ios程序时调试的好帮手---NSAssert()函数。而且和NSLog()函数一样简单易用,代码如下:&&&&NSAssert(x!=0,@&x must not be zero&);
在表达式“x!=0”不成立时,程序就会抛出异常,并显示自定义的消息&x must not be zero&,并同时显示出错的文件、代码和调用函数等信息,是一个程序追踪的很好手段。
假设x!=0,不满足要求就提示reason-x must not be zero
*.mac下按F3,F4等失灵的原因,可能是在键盘中选中了fn键,如下:
系统预置==》键盘与鼠标==》键盘
其中有一个选项:将所有f1、f2等键用作标准功能健
点选以后,特殊功能需要组合fn才会激活
*.在 XCode 4.2 (with LLVM):里&
-(void)release&
&会弹出警告
&warning: Semantic Issue: Conflicting distributed object modifiers on return type in implementation of 'release'
为了去掉警告 修改如下 :
-(oneway void) release&
oneway is used with the distributed objects API, which allows use of objective-c objects between different threads or applications. It tells the system that it should not block the calling thread until the method returns. Without it, the caller will block,
even though the method's return type is void. Obviously, it is never used with anything other than void, as doing so would mean the method returns something, but the caller doesn't get it.&
*.出现下面的错误的解决办法.
Just updated to iOS 6 sdk and latest Xcode and get this when trying to build to my 3gs. I 've added armv6 under valid architectures?
&Could not change executable permissions on the application&
或者类似的,可能是证书问题,其实是ipad/iphone上已经存在和要安装的app相同&Bundle Identifier&的了,可以把ipad/iphone上的删除掉再安装.
/questions//could-not-change-executable-permissions-on-the-application 详细解决办法.
*.如果一台设备在自己的电脑上初次插上时,xcode无法找到该设备,原因可能是该xcode版本太低,和该设备的版本不匹配.xcode如果要安装app到设备上,首先考虑在
上通过开发者账号添加该设备id,然后在xcode的organizer里面安装该设备的profile,这个时候是需要提示输入app账号的,随便输入一个可用的都行.
&Error launching remote program: failed to get the task for process&
这个问题的解释是:
The ad-hoc profile doesn't support debugging. You need to debug with a Development profile, and use the Ad-Hoc profile only for distributing non-debuggable
就是ad-hoc证书是不支持debug的,此时更换debug证书就OK.
*.证书问题常常是新手最困扰的地方,教程没弄会很麻烦.也可以直接点击下面的链接查看官方英文文档.
/ios/manage/bundles/howto.action
appid 和证书要怎么匹配的?
Code Sign error: Provisioning profile 'xxxt' specifies the Application Identifier 'com.XXXPRO.test' which doesn't match the current setting '.XXXPRO.test'
////////////
Provisioning Profiles - 安装/校验
  要把从iPhone Developer Program Provisioning Portal下载回来的Provisioning Profile安装到开发机器,首先需要启动 Xcode然后点击&Window & Organizer&来打开Organizer。把provisioning profile拖到标记为&Provisioning Profiles&的区域内即可。
  如果是为了开发而安装 Provisioning Profile,还需要把它装在开发设备上。在 iPhone OS 设备已经插到电脑上的时候,在 Devices 三角下选择设备,然后在Organizer里把开发provisioning profile拖进去。这就把 Provisioning profile装到 iPhone OS设备里了。
  注意:确保安装在开发设备和Mac里的 Development Provisioning完全相同对成功生成并安装测试程序是非常重要的。
  注意:跟 Development Provisioning Profiles不同,App Store Distribution Provisioning Profiles不能安装在iPhone OS设备里。用App Store Distribution Provisioning生成的程序是用来通过 iTunes Connect上传到App Store的。
  要告诉 Xcode 使用哪个 Provisioning profile,打开 Xcode 项目,打开 Target build settings,滚动到 Code Signing。在 Code Signing 区域有个带小三角的 Code Signing Identity。确定设置是为任何 iPhone OS 设备,之后在Value列点击弹出菜单并且选择要使用的 Provisioning Profile。为了开发,建议选择
&iPhone Developer&,要发布,建议选择&iPhone Distribution&。这些都在弹出菜单的&Auto matic Profile Selector&区域里,这样就可以使 Xcode来为你找到正确的Provisioning Profile。
  注意:要是丢失了 iPhone devloper/Distribution证书的私钥,就无法选择证书关联到的 Provisioning Profile。从备份中导入 iPhone developer/Distribution 证书的私钥可以解决这个问题。如果丢了或者删了私钥,就得生成一个新的CSR并且下载新的 iPhone Developer/Distribution 证书和Provisioning Profile。
  程序的 Bundle Identifier 必须跟Provisioning profiles的Bundle Identifier APP ID匹配。要编辑程序的 Bundle Identifier,打开 target's properties settings,在 Identifier 栏输入 Bundle Identifier。如果在 App id的bundle identifier里使用星号通配符,就可以替换为反向DNS格式的字符。
  下面有一些可以输入到 Identifier 框的例子。
  如果AppID是 .domainname.applicationname。输入com.domainname.applicationname 作为 Bundle Identifier
  AppID是 A1B2C3D4E5.*,输入反向DNS格式的字符串作为 Bundle Identifier。
关于 Profiles 和 App IDs
  创建 Provisioning Profiles 时可以关联两种类型的 App ID。第一个类型叫做通用App ID(Wildcard App ID)。推荐大多数iPhone OS开发用通用App ID的Provisioning Profiles,因为这样单个通用App ID可以用来生成和安装大多数程序,包括 iPhone Reference Libary 里的示例代码。通用App ID通过在&&Identifier
里输入星号创建。星号必须是App ID字符串的最后一个字符。如果使用通用App ID,记着在Xcode项目里输入Bundle Identifier时把星号替换为反向DNS格式。
假设有 App ID ABCDE12345.*:
ABCDE12345是Bundle种子ID(由Apple生成)
*是App ID的Bundle Identifier。在xcode里输入bundle identifier时需要把星号替换为反向DNS格式。
假设有 App ID: .yourcompany.*
ABCDE12345是Bundle种子ID(由Apple生成)
com.yourcompany.* 是App ID的Bundle Identifier。并且xcode项目里的bundle identifier必须以'com.yourcompany.'开头,星号可以替换成任意字串。
  第二类 App ID 称作固定AppID(Explicit App ID)。这类 APP ID限定了一个provisioning profile只允许一个程序安装。启用iPhone OS 3.0特性需要固定 App ID,例如 In App Purchase或者 App Push Notification 服务。固定ID通过输入指定字串创建。推荐做法是用反向DNS格式。
  重要:一个避免将来可能产生问题的提示:修改 yourcompany 为真正的名字。
/////////////
app id生成之后在上目前是无法被删除的.
6.iPhone真机调试报如下错误时,关掉Xcode,重新启动就可以了,注意是关掉Xcode,彻底关掉。
Error launching remote program: No such file or directory
一般是因为修改了 Bundle identifier 造成的。
* 以上用户言论只代表其个人观点,不代表CSDN网站的观点或立场
访问:16944次
排名:千里之外
转载:43篇
(1)(3)(1)(3)(1)(1)(1)(2)(2)(5)(8)(19)IOS开发中遇到的奇怪问题(也许会不断更新)
问题描述:
制作layer动画的时候,希望让动画结束后layer保持在动画结束的状态,但设置了fillMode为kCAFillModeForwards以后layer仍然在动画结束后变回了初始的样子。
解决方案:
CAAnimation动画,需要设置 fillMode 属性时,那么需要将 removedOnCompletion
设置为NO,否则fillMode无效。
问题描述:
上网下载了一个第三方的控件使用了一个self.topLayoutGuide的对象,该对象的目的是为了在layout的时候便于定位当前view的最上方。但这个对象仅对IOS7有效,对于IOS6需要做些修改。
解决方案:
//id topGuide = self.topLayoutG//ForIOS7
UIView* top = [[UIView alloc]initWithFrame:CGRectMake(0, 0, 0,
[self.view addSubview:top];//forIOS6
用top可以代替topGuide。。。
问题描述:
在两个类的@implementation声明了同一种类型且同名的变量,结果编译报错……
原因不明。
解决方案:
将变量声明放到@interface中(严格来说这样也更规范)
问题描述:
真机调试一个新工程的时候报错:Could not change executable permissions on the
application.
经检查证书等均没问题。
解决方案:
因为以前有一个工程使用了同样的bundle
id,同一台手机安装两个使用同一个ID的程序,所以无法正常运行,因为旧工程已经被放弃,所以删了手机中安装的旧的app,问题解决。
问题描述:
因为设计需要,希望让ios7下的状态栏图标强制显示为白色的效果。
解决方案:
在info.plist里边增加主键View controller-based status bar
appearance,设置value为YES。
在viewcontroller的实现中增加函数:
- (UIStatusBarStyle)preferredStatusBarStyle
//该函数会在这个view被加载的时候调用,
//可选UIStatusBarStyleDefault,默认黑色的状态栏图标
&&& return
UIStatusBarStyleLightCon//白色的状态栏图标
//说明上看仅对IOS7有效,IOS6待测。
问题描述:
利用VedioCapture调用摄像头的时候,有时候在修改了一些与调用有关的代码以后出现【预览框不预览】【VideoBufferDelegate不回调】的情况,经检查代码无误。
解决方案:
猜测是xcode预编译和缓存的问题,执行shift+command+k指令clean以后,重新build,问题解决。
以上网友发言只代表其个人观点,不代表新浪网的观点或立场。

我要回帖

更多关于 no permissions 的文章

 

随机推荐