Android "App not installed."

Previous topic - Next topic

bigtunacan

I have compiled my game for Android and the build is successful.  I tried to install the apk on my phone and just get the message "App not installed".

My phone is enabled to allow install of apps from anywhere; I'm not doing any code signing right now as I'm just trying to test on my own phone.  Not sure what is happening.

bigtunacan

After reading through some other threads on here I tried reinstalling v12 and built my project again with a fresh build.  With the fresh build, the build fails and no apk files get created.  The following is the output I get from GLBasic.

Code (glbasic) Select


_______________________________________
*** Configuration: ANDROID ***
precompiling:
GPC - GLBasic Precompiler V.10.060 SN:20da3ee5 - 3D, NET
Wordcount:75 commands
compile+link:
running glb_build.bat
Using ANDROID_TARGET="android-8"
You can use "C:\Users\sfamily\Documents\_joe_backups\Dev\GLBasic\GLBasic\FlashCards\distribute\Android\glb_android_build.bat" to change the API level and SDK path.
%ANDROIDSDK% not set. Using GLBasic's default target-8, Android 2.2



BUILD STAGE 1: Compile and pack RELEASE
Updated and renamed default.properties to project.properties
Updated local.properties
Added file C:\Users\sfamily\Documents\_joe_backups\Dev\GLBasic\GLBasic\FlashCards\distribute\Android\build.xml
Updated file C:\Users\sfamily\Documents\_joe_backups\Dev\GLBasic\GLBasic\FlashCards\distribute\Android\proguard.cfg

BUILD FAILED
Q:\Compiler\platform\android\android-sdk-windows\tools\ant\build.xml:539: The following error occurred while executing this line:
Q:\Compiler\platform\android\android-sdk-windows\tools\ant\build.xml:568: null returned: 1

Total time: 4 seconds
Picked up _JAVA_OPTIONS: -Xms256m -Xmx512m
.
BUILD STAGE 2: Build DEBUG and install on device
     [echo] Gathering info for glbasic...
     [echo] Creating output directories if needed...
     [echo] ----------
     [echo] Handling aidl files...
     [echo] ----------
     [echo] Handling RenderScript files...
     [echo] ----------
     [echo] Handling Resources...

BUILD FAILED
Q:\Compiler\platform\android\android-sdk-windows\tools\ant\build.xml:539: The following error occurred while executing this line:
Q:\Compiler\platform\android\android-sdk-windows\tools\ant\build.xml:568: null returned: 1

Total time: 3 seconds
Picked up _JAVA_OPTIONS: -Xms256m -Xmx512m
finished Android build-script.
Android=C:\Users\sfamily\Documents\_joe_backups\Dev\GLBasic\GLBasic\FlashCards\distribute\Android
success
_______________________________________
*** Finished ***
Elapsed: 17.8 sec. Time: 20:24
Build: 1 succeeded.

kanonet

I think this was an error related to icons. Did you try to delete all icons in project folder, besides icon.ico and icon.png?
Lenovo Thinkpad T430u: Intel i5-3317U, 8GB DDR3, NVidia GeForce 620M, Micron RealSSD C400 @Win7 x64

bigtunacan

I installed the SDK 14-16 and Android Extras updates again, moved my assets down into my Media folder, compiled and was able to successfully install onto my Android phone.

Now when I try to open the app it immediately crashes.  Here is the Logcat output related to the app crashing.

Code (glbasic) Select

I/ActivityManager(  467): START {act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10200000 cmp=com.justjoe.flashcards/org.libsdl.app.SDLActivity u=0} from pid 808
W/ResourceType(  808): No package identifier when getting value for resource number 0x00000000
I/ActivityManager(  467): Start proc com.justjoe.flashcards for activity com.justjoe.flashcards/org.libsdl.app.SDLActivity: pid=3983 uid=10021 gids={3003, 1015, 1028}
E/Trace   ( 3983): error opening trace file: No such file or directory (2)
D/dalvikvm( 3983): Trying to load lib /mnt/asec/com.justjoe.flashcards-1/lib/libSDL2.so 0x41640830
D/dalvikvm( 3983): Added shared lib /mnt/asec/com.justjoe.flashcards-1/lib/libSDL2.so 0x41640830
D/dalvikvm( 3983): Trying to load lib /mnt/asec/com.justjoe.flashcards-1/lib/libmikmod.so 0x41640830
D/dalvikvm( 3983): Added shared lib /mnt/asec/com.justjoe.flashcards-1/lib/libmikmod.so 0x41640830
D/dalvikvm( 3983): No JNI_OnLoad found in /mnt/asec/com.justjoe.flashcards-1/lib/libmikmod.so 0x41640830, skipping init
D/dalvikvm( 3983): Trying to load lib /mnt/asec/com.justjoe.flashcards-1/lib/libSDL2_mixer.so 0x41640830
D/dalvikvm( 3983): Added shared lib /mnt/asec/com.justjoe.flashcards-1/lib/libSDL2_mixer.so 0x41640830
D/dalvikvm( 3983): No JNI_OnLoad found in /mnt/asec/com.justjoe.flashcards-1/lib/libSDL2_mixer.so 0x41640830, skipping init
D/dalvikvm( 3983): Trying to load lib /mnt/asec/com.justjoe.flashcards-1/lib/libmain.so 0x41640830
D/dalvikvm( 3983): Added shared lib /mnt/asec/com.justjoe.flashcards-1/lib/libmain.so 0x41640830
I/SDL     ( 3983): ---------------------------------------------
I/SDL     ( 3983): ---               restart                 ---
I/SDL     ( 3983): ---------------------------------------------
I/SDL     ( 3983): onCreate
I/glbasic ( 3983): external files dir is /data/data/com.justjoe.flashcards/files
I/glbasic ( 3983): external storage /storage/sdcard0/Download
I/glbasic ( 3983): DPI 366
I/glbasic ( 3983): Exception starting GPS: Provider gps requires ACCESS_FINE_LOCATION permission
I/glbasic ( 3983): Creating SoundPool instances...
I/glbasic ( 3983): SoundPool instances created
D/AndroidRuntime( 3983): Shutting down VM
W/dalvikvm( 3983): threadid=1: thread exiting with uncaught exception (group=0x40e422a0)
E/AndroidRuntime( 3983): FATAL EXCEPTION: main
E/AndroidRuntime( 3983): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.justjoe.flashcards/org.libsdl.app.SDLActivity}: java.lang.SecurityException: Need BLUETOOTH permission: Neither user 10021 nor current process has android.permission.BLUETOOTH.
E/AndroidRuntime( 3983): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2136)
E/AndroidRuntime( 3983): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2174)
E/AndroidRuntime( 3983): at android.app.ActivityThread.access$700(ActivityThread.java:141)
E/AndroidRuntime( 3983): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1267)
E/AndroidRuntime( 3983): at android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime( 3983): at android.os.Looper.loop(Looper.java:137)
E/AndroidRuntime( 3983): at android.app.ActivityThread.main(ActivityThread.java:5059)
E/AndroidRuntime( 3983): at java.lang.reflect.Method.invokeNative(Native Method)
E/AndroidRuntime( 3983): at java.lang.reflect.Method.invoke(Method.java:511)
E/AndroidRuntime( 3983): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:792)
E/AndroidRuntime( 3983): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:555)
E/AndroidRuntime( 3983): at dalvik.system.NativeStart.main(Native Method)
E/AndroidRuntime( 3983): Caused by: java.lang.SecurityException: Need BLUETOOTH permission: Neither user 10021 nor current process has android.permission.BLUETOOTH.
E/AndroidRuntime( 3983): at android.os.Parcel.readException(Parcel.java:1425)
E/AndroidRuntime( 3983): at android.os.Parcel.readException(Parcel.java:1379)
E/AndroidRuntime( 3983): at android.bluetooth.IBluetooth$Stub$Proxy.getBluetoothState(IBluetooth.java:1836)
E/AndroidRuntime( 3983): at android.bluetooth.BluetoothAdapter.getState(BluetoothAdapter.java:498)
E/AndroidRuntime( 3983): at android.bluetooth.BluetoothAdapter.getBondedDevices(BluetoothAdapter.java:875)
E/AndroidRuntime( 3983): at org.libsdl.app.SDLActivity.detectiCade(SDLActivity.java:389)
E/AndroidRuntime( 3983): at org.libsdl.app.SDLActivity.onCreate(SDLActivity.java:357)
E/AndroidRuntime( 3983): at android.app.Activity.performCreate(Activity.java:5058)
E/AndroidRuntime( 3983): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1079)
E/AndroidRuntime( 3983): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2100)
E/AndroidRuntime( 3983): ... 11 more
W/ActivityManager(  467):   Force finishing activity com.justjoe.flashcards/org.libsdl.app.SDLActivity
W/ApplicationContext(  467): Unable to create files directory files
D/wifi    (  467): doString: SIGNAL_POLL
D/DataOffloadReceiver( 3586): Received broadcast intentcom.motorola.blur.apps.ACTION_APP_LAUNCHED
D/DataOffloadReceiver( 3586): OptionClickedTime =0currentTime=1387269092031
D/DataOffloadReceiver( 3586): Offload disabled
D/DataOffloadReceiver( 3586): Offload not required, ignore the intent
W/ActivityManager(  467): Activity pause timeout for ActivityRecord{41d5aba0 com.justjoe.flashcards/org.libsdl.app.SDLActivity}
W/ResourceType(  808): No package identifier when getting value for resource number 0x00000000
I/ActivityManager(  467): No longer want com.hotmail.Z7:client (pid 32010): hidden #21
I/Process ( 3983): Sending signal. PID: 3983 SIG: 9
I/ActivityManager(  467): Process com.justjoe.flashcards (pid 3983) has died.

spacefractal

nice bug  :good:. Im fix that one in the next version (its used for detect game controller names, but is not required if not using that).

Howover its a easy to fix that bug, just add <uses-permission android:name="android.permission.BLUETOOTH" /> to the AndroidManifest.xml in your distrubtion folder. Then its should Work.
Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/

bigtunacan

You are the man!  Running like a champ on my Android phone now.  Thanks!