在哪里可以找到 .apk 文件?
我想导出一个 APK 文件,以便朋友可以在他的手机上尝试我使用 Eclipse/ADT 开发的应用程序。我该怎么做?我在 Eclipse 的导出选项下找不到合适的选项,并且在我的驱动器上搜索 .apk 没有显示任何内容?
谢谢
I want to export an APK file so a friend can try my app that I've developed using Eclipse/ADT on his phone. How do I do this? I can't find a suitable option under Eclipse's export options, and searching for .apk on my drive didn't show anything?
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(6)
右键单击您的 Android 项目 --> Android工具-->导出未签名的应用程序包
Right click your android project --> Android tools --> Export unsigned application package
您是否右键单击该项目并选择“导出”->“Android”->“导出 Android 应用程序”?仅在 Eclipse 中构建应用程序并不会创建 apk。
Have you right clicked the project and choosen Export->Android->Export Android Application? Just building the app in Eclipse does not create the apk.
转到项目文件夹位置。
进入
bin
文件夹。您将在那里找到
apk
**。通过邮件或 USB 将您的 apk 发送给您的朋友。
使用 adb.exe 将文件安装到您的设备。
** - 如果您已成功构建项目。
Go to the project folder location.
Go inside the
bin
folder.You will find the
apk
there**.Send your apk to your friend via mail or USB.
Using the adb.exe install the file to your device.
** - If you have successfully build the project.
查看您的工作区/文件夹,
右键单击您的项目并选择选项。资源->位置
look in you workspace/ folder
rightclick your project and choose options. resource->location
正如对类似问题的回答所指出的如何在不启动模拟器的情况下在 Eclipse 中将 Android 项目编译为 .apk 文件?,由于 Eclipse Indigo,构建项目不会将您的 APK 直接放在 bin 文件夹中。您必须运行模拟器才能生成 APK
如果您希望在构建时生成 APK,则需要转到 Windows ->首选项->安卓->构建并取消选中“跳过打包和解压缩直到导出或启动”,然后重新启动 Eclipse。 (感谢@Andy Weinstein 在另一个问题上的回答)
As pointed in an answer to a similar question How do you compile an Android project into an .apk file in Eclipse without launching the emulator? , since Eclipse Indigo, building the project will not put your APK directly on the bin folder. You will have to run the emulator for it to generate the APK
If you want the APK to be generated on build time, you need to Go to Windows -> Preferences -> Android -> Build and uncheck "Skip packaging and dexing until export or launch" then restart Eclipse. (credits for @Andy Weinstein who answered it on the other question)
啊,我刚刚意识到它就在那里!还是不习惯windows 7!!毕竟它位于项目 bin 目录的根目录中。
Ah I just realised it was there! Still not used to windows 7!! It was in the root of the project's bin directory after all.