gpt4 book ai didi

android - 找不到 *apk,第一次运行但在第二次运行时工作

转载 作者:太空狗 更新时间:2023-10-29 14:29:13 26 4
gpt4 key购买 nike

我在网站上搜索过,但找不到这个非常烦人的问题的确切解决方案。每次,我创建一个新的 Android 项目,它在第一次尝试运行它时都会失败,并显示红色消息“Could not fin *apk!”但在第二次尝试时效果很好,依此类推。这里的任何人都可以帮助解决这个问题,因为我以前没有遇到过这个问题。我可以在第一次尝试时运行我的程序。

这是我在控制台得到的结果,但您将能够在第二次尝试时看到它正常工作...

希望能尽快收到你们的来信,在此先感谢您。

我有 eclipse Eclipse Indingo 服务版本 1 ADT r15 在 windows 7 旗舰机上运行

控制台输出信息:

[2011-12-09 15:25:11 - Layout] ------------------------------
[2011-12-09 15:25:11 - Layout] Android Launch!
[2011-12-09 15:25:11 - Layout] adb is running normally.
[2011-12-09 15:25:11 - Layout] Could not find Layout.apk!
[2011-12-09 15:25:43 - Layout] ------------------------------
[2011-12-09 15:25:43 - Layout] Android Launch!
[2011-12-09 15:25:43 - Layout] adb is running normally.
[2011-12-09 15:25:43 - Layout] Performing com.delanation.lay.main activity launch
[2011-12-09 15:25:43 - Layout] Automatic Target Mode: using existing emulator 'emulator-5554' running compatible AVD 'GingerBread'
[2011-12-09 15:25:43 - Layout] Uploading Layout.apk onto device 'emulator-5554'
[2011-12-09 15:25:44 - Layout] Installing Layout.apk...
[2011-12-09 15:25:47 - Layout] Success!
[2011-12-09 15:25:48 - Layout] Starting activity com.delanation.lay.main on device emulator-5554
[2011-12-09 15:25:49 - Layout] ActivityManager: Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] cmp=com.delanation.lay/.main }

登录目录:

=============================================

 *12-09 00:31:24.611: D/AndroidRuntime(6161): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
12-09 00:31:24.611: D/AndroidRuntime(6161): CheckJNI is ON
12-09 00:31:25.371: D/AndroidRuntime(6161): Calling main entry com.android.commands.pm.Pm
12-09 00:31:25.581: D/dalvikvm(380): GC_EXPLICIT freed 5K, 54% free 2539K/5511K, external 1625K/2137K, paused 74ms
12-09 00:31:25.581: W/ActivityManager(81): No content provider found for:
12-09 00:31:25.643: W/ActivityManager(81): No content provider found for:
12-09 00:31:25.661: D/PackageParser(81): Scanning package: /data/app/vmdl-1754418723.tmp
12-09 00:31:25.771: D/PackageManager(81): Scanning package com.delanation.lay
12-09 00:31:25.782: I/PackageManager(81): Unpacking native libraries for /data/app/com.delanation.lay-1.apk
12-09 00:31:25.870: D/installd(35): DexInv: --- BEGIN '/data/app/com.delanation.lay-1.apk' ---
12-09 00:31:26.021: D/dalvikvm(6170): DexOpt: load 32ms, verify+opt 15ms
12-09 00:31:26.051: D/installd(35): DexInv: --- END '/data/app/com.delanation.lay-1.apk' (success) ---
12-09 00:31:26.061: D/PackageManager(81): Activities: com.delanation.lay.main
12-09 00:31:26.081: I/ActivityManager(81): Force stopping package com.delanation.lay uid=10042
12-09 00:31:26.391: I/installd(35): move /data/dalvik-cache/data@app@com.delanation.lay-1.apk@classes.dex -> /data/dalvik-cache/data@app@com.delanation.lay-1.apk@classes.dex
12-09 00:31:26.391: D/PackageManager(81): New package installed in /data/app/com.delanation.lay-1.apk
12-09 00:31:27.311: W/RecognitionManagerService(81): no available voice recognition services found
12-09 00:31:27.781: D/dalvikvm(81): GC_EXPLICIT freed 820K, 55% free 4739K/10375K, external 3933K/4430K, paused 124ms
12-09 00:31:27.801: D/AndroidRuntime(6161): Shutting down VM
12-09 00:31:27.811: D/dalvikvm(6161): GC_CONCURRENT freed 101K, 72% free 295K/1024K, external 0K/0K, paused 1ms+1ms
12-09 00:31:27.831: D/jdwp(6161): Got wake-up signal, bailing out of select
12-09 00:31:27.831: D/dalvikvm(6161): Debugger has detached; object registry had 1 entries
12-09 00:31:27.861: I/dalvikvm(6161): JNI: AttachCurrentThread (from ???.???)
12-09 00:31:27.861: I/AndroidRuntime(6161): NOTE: attach of thread 'Binder Thread #3' failed
12-09 00:31:28.501: D/AndroidRuntime(6175): >>>>>> AndroidRuntime START com.android.internal.os.RuntimeInit <<<<<<
12-09 00:31:28.501: D/AndroidRuntime(6175): CheckJNI is ON
12-09 00:31:29.251: D/AndroidRuntime(6175): Calling main entry com.android.commands.am.Am
12-09 00:31:29.281: I/ActivityManager(81): Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10000000 cmp=com.delanation.lay/.main } from pid 6175
12-09 00:31:29.531: D/AndroidRuntime(6175): Shutting down VM
12-09 00:31:29.531: I/ActivityManager(81): Start proc com.delanation.lay for activity com.delanation.lay/.main: pid=6184 uid=10042 gids={}
12-09 00:31:29.551: D/dalvikvm(6175): GC_CONCURRENT freed 102K, 69% free 320K/1024K, external 0K/0K, paused 1ms+1ms
12-09 00:31:29.591: D/jdwp(6175): Got wake-up signal, bailing out of select
12-09 00:31:29.591: D/dalvikvm(6175): Debugger has detached; object registry had 1 entries
12-09 00:31:29.622: I/AndroidRuntime(6175): NOTE: attach of thread 'Binder Thread #3' failed
12-09 00:31:30.821: I/ActivityManager(81): Displayed com.delanation.lay/.main: +1s304ms
12-09 00:31:35.971: D/dalvikvm(380): GC_EXPLICIT freed 6K, 54% free 2537K/5511K, external 1625K/2137K, paused 59ms
12-09 00:31:36.911: I/ActivityManager(81): Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.HOME] flg=0x10200000 cmp=com.android.launcher/com.android.launcher2.Launcher } from pid 81
12-09 00:31:37.161: I/ActivityManager(81): No longer want com.android.inputmethod.latin (pid 2695): hidden #16
12-09 00:31:42.611: D/dalvikvm(393): GC_EXPLICIT freed 3K, 55% free 2532K/5511K, external 1625K/2137K, paused 70ms
12-09 00:31:47.641: D/dalvikvm(290): GC_EXPLICIT freed 8K, 55% free 2591K/5703K, external 1625K/2137K, paused 76ms
12-09 00:33:38.631: D/SntpClient(81): request time failed: java.net.SocketException: Address family not supported by protocol
12-09 00:37:29.201: V/BackupManagerService(81): Backup requested but nothing pending
12-09 00:38:38.681: D/SntpClient(81): request time failed: java.net.SocketException: Address family not supported by protocol
12-09 00:43:38.681: D/SntpClient(81): request time failed: java.net.SocketException: Address family not supported by protocol*

最佳答案

在 eclipse 中选择“Window”->“Preferences”,然后展开“Android”子树并选择“Build”。

在“build设置”下,如果您启用了“跳过打包和索引直到导出或启动...”,请尝试禁用它以查看是否可以解决问题。

关于android - 找不到 *apk,第一次运行但在第二次运行时工作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8447317/

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