gpt4 book ai didi

iphone - 如何将我的 .app 文件从 xcode 的 builds 文件夹复制/运行到我的 iphone 上的/Applications 文件夹? (越狱)

转载 作者:行者123 更新时间:2023-12-03 20:34:06 25 4
gpt4 key购买 nike

所以我开发了一个应用程序。现在我手动将 .app 文件放入我的 iPhone(根目录)的 /Applications 文件夹中。比我做的:

It sounds like the application isn't signed. Download ldid from Cydia and then use it like so: ldid -S /Applications/AccelerometerGraph.app/AccelerometerGraph

Also be sure that the binary is marked as executable: chmod +x /Applications/AccelerometerGraph.app/AccelerometerGraph

( via )

我使用 UICache 使应用程序可见。如果我运行它,它会显示黑屏 1/4 秒,然后关闭...(我不是 iphone 开发计划的成员)。

我做错了什么吗?

有更好的方法吗?

非常感谢! :)

最佳答案

我刚刚度过了一个完美的周六下午,寻找完全相同问题的解决方案。这是一个代码签名问题。

这是我使用的 Xcode4iOS 4.3 SDK 。我正在为测试设备构建一个运行 iOS 3.1.2(已越狱)的 iphone 3G

注意:ldid方法对我不起作用,并不断抛出以下错误(Some Details on why its not working我尝试通过xcode4使用armv6架构,但ldid仍然给出相同的错误):

codesign_allocate:对象:MyAppName.app/MyAppName 格式错误的对象(未知加载命令 4)
util/ldid.cpp(582): _assert(0:WEXITSTATUS(状态) == 0)

这是对我有用的:

第 1 步:创建自签名证书

1- Launch Keychain Access.app. With no items selected, from the Keychain menu select Certificate Assistant, then Create a Certificate.

Name: iPhone Developer Certificate Type: Code Signing Let me override defaults: Yes

2- Click Continue

Validity: 3650 days

3- Click Continue

4- Blank out the Email address field.

5- Click Continue until complete.

You should see "This root certificate is not trusted". This is expected.

via (注意:您不需要成为 iphone 开发计划的成员即可完成这项工作,即使链接中接受的答案的标题可能表明这一点)

步骤 2.设置 xCode 以允许使用自签名证书

You have to edit the Info.plist file under /Developer/Platforms/iPhoneOS.platform/Info.plist

(I have installed xcode at a different location so that path for me was xcode4/Platforms/iPhoneOS.platform/Info.plist)

1- You will not be able to edit the file in its current location so just copy it to the desktop and open it in a text editor.

2- You need to Replace all instance of XCiPhoneOSCodeSignContext with XCCodeSignContext and save the file.

3- Then drag and drop the edited file back to iPhoneOS.platform folder and replace the old file. (Make sure xcode is not running if it is then restart it)

第 3 步:更改项目中的代码签名身份设置

Change the code signing identity for your project and your target to iPhone Developer

1- In xcode4 you have to select your project (from the left navigator panel) -> Select you Project from the center under (PROJECTS) -> Build Settings -> Code Signing (expand the menu) and change all options to iPhone Developer

2- In xcode4 with your project selected from the left panel in the center of the screen you will see PROJECT and TARGETS. Now select the targets and do that same: Targets -> Build Settings -> Code Signing (expand the menu) and change all options to iPhone Developer

第 4 步:构建应用程序并部署

1- Make Sure at the top of xcode next to the run and stop buttons under Scheme you have iOS Device (your device name) selected and NOT Simulator (this is how its done in xcode4)

2- Open the Scheme menu and with the iOS Device Scheme selected click edit scheme. Select Run from the left menu and under the Info tab set Build Configuration to Release

3- Now make sure you have your iOS device connected and its scheme is selected and hit Run (note: you will get some warnings but as along as the build succeeds you are okay)

if all goes well you should be able to see YourApp.app under the Products folder on the left side now select YourApp.app open it in Finder. Your app should be in a folder called Release-iphoneos Copy it to /Applications dir on your iOS device and respring or UICache to make it appear. (note: you dont need to use ldid now)

希望您的应用程序能够正常启动。我只在 xcode4 上尝试过这个,所以不确定它是否适用于旧版本。

关于iphone - 如何将我的 .app 文件从 xcode 的 builds 文件夹复制/运行到我的 iphone 上的/Applications 文件夹? (越狱),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5443912/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com