Android install issues.

Previous topic - Next topic

ProN3rd

i have been trying for a few days now, and read a lot in this forum but i still cant figure out how to compile for android.
this is the code:
Code (glbasic) Select

WHILE TRUE
DRAWRECT 20,20,100,100,RGB(255,0,0)
SHOWSCREEN
WEND


i tested with GLBasic IDE, Version: 12.308 and now I use GLBasic IDE, Version: 12.096, the problems are the same:

Code (glbasic) Select

_______________________________________
*** Configuration: ANDROID ***
precompiling:
GPC - GLBasic Precompiler V.10.060 SN:bdf43d6f - 3D, NET
Wordcount:4 commands
compile+link:
running glb_build.bat
Using ANDROID_TARGET="android-8"
You can use "C:\Users\Gans\Documents\GLBasic\8feb\distribute\Android\glb_android_build.bat" to change the API level and SDK path.



BUILD STAGE 1: Compile and pack RELEASE
Error: Target id 'android-8' is not valid. Use 'android.bat list targets' to get the target ids.
Build failed
Picked up _JAVA_OPTIONS: -Xms256m -Xmx512m
.
BUILD STAGE 2: Build DEBUG and install on device
Buildfile: build.xml does not exist!
Build failed
Picked up _JAVA_OPTIONS: -Xms256m -Xmx512m
finished Android build-script.
Android=C:\Users\Gans\Documents\GLBasic\8feb\distribute\Android
erfolgreich
_______________________________________
*** Fertig ***
Dauer: 5.2 sek. Zeit: 04:39
Erstellen: 1 erfolgreich.


apk file is not created.

i have a freh installation of Java SDK (32 Bit) 8.0 Update 31, i use the variables:


  • JAVA_HOME: C:\Program Files (x86)\Java\jdk1.8.0_31
    ANDROIDSDK: C:\Android\android-sdk
    Path: %JAVA_HOME%\bin

I have emulated various APIS from API 19 (4.4.2) onwards and various devices. I can install other (non gl basic coded) apk files on Android sdk.

Reply39 (in this thread) dropbox link  wont work any more, I tried it a few days ago but lost it during reinstalling.

I have also GLBasic IDE, Version: 10.202 installed, and it works there in so far as the app gets installed. But when I want to open it on the virtual device, it sais "Unfortunately <App Name> has stopped. I also tried the "ANDROTEST.apk" which I found in some thread here and which is known to work. However i get the same error message after installing via cmd.

For all test i delted icons and the distribute folder, or made entirely new projects. Please help me either make GLBasic IDE, Version: 10.202 work, or the new version. Is there a known configuration which works? What GLBasic IDE, JDK,Android API version run without errors?

EDIT: Now downloading and testing this from reply33 in this thread: http://www.glbasic.com/forum/index.php?topic=9166.msg90174#msg90174

the result is:
Code (glbasic) Select


_______________________________________
*** Configuration: ANDROID ***
precompiling:
GPC - GLBasic Precompiler V.10.060 SN:bdf43d6f - 3D, NET
Wordcount:4 commands
compile+link:

running glb_build.bat
Using ANDROID_TARGET="android-19"
You can use "C:\Users\Gans\Documents\GLBasic\8feb\distribute\Android\glb_android_build.bat" to change the API level and SDK path.

Checking Icons (uses 'AndroidExtras_icons_X.png' For changes)....
C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android
C:/Users/Gans/Documents/GLBasic/8feb/icon_36_AndroidExtras.png is missing (36x36 size)
C:/Users/Gans/Documents/GLBasic/8feb/icon_36_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_36_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-ldpi/icon.png
C:/Users/Gans/Documents/GLBasic/8feb/icon_48_AndroidExtras.png is missing (48x48 size)
C:/Users/Gans/Documents/GLBasic/8feb/icon_48_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_48_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-mdpi/icon.png
C:/Users/Gans/Documents/GLBasic/8feb/icon_72_AndroidExtras.png is missing (72x72 size)
C:/Users/Gans/Documents/GLBasic/8feb/icon_72_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_72_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-hdpi/icon.png
C:/Users/Gans/Documents/GLBasic/8feb/icon_96_AndroidExtras.png is missing (96x96 size)
C:/Users/Gans/Documents/GLBasic/8feb/icon_96_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_96_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-xhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/8feb/icon_180_AndroidExtras.png is missing (180x180 size)
C:/Users/Gans/Documents/GLBasic/8feb/icon_180_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_180_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-xxhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/8feb/icon_192_AndroidExtras.png is missing (192x192 size)
C:/Users/Gans/Documents/GLBasic/8feb/icon_192_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_192_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-xxxhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/8feb/icon_ouya_AndroidExtras.png is missing (732x412 size)
the Ouya icon is not important, if you dont want to support the console
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_ouya_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-xhdpi/ouya_icon.png
Checking Icons Finished...

BUILD STAGE 2: Start compiler (android.bat)
Q:\Compiler\platform\android\bin\..\android-sdk-windows
Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
.
BUILD STAGE 3: Build a debug build
Buildfile: build.xml does not exist!
Build failed
.
BUILD STAGE 4: Build a release build
Buildfile: build.xml does not exist!
Build failed
Picked up _JAVA_OPTIONS: -Xms256m -Xmx512m
.
HOW TO INSTALL? Install by invoke this command:
"Q:\Compiler\platform\android\bin\..\android-sdk-windows\platform-tools\adb.exe" install -r "C:\Users\Gans\Documents\GLBasic\8feb\distribute\Android/bin/glbasic-debug.apk"
.
HOW TO SIGN? Sign it by invoke this command:
"Q:\Compiler\platform\android\bin\glb_code_sign.bat" "C:\Users\Gans\Documents\GLBasic\8feb\distribute\Android"
.
Android=C:\Users\Gans\Documents\GLBasic\8feb\distribute\Android
erfolgreich
_______________________________________
*** Fertig ***
Dauer: 7.6 sek. Zeit: 05:33
Erstellen: 1 erfolgreich.


still no apk file, a bunch of icons were created

EDIT 2: Now testing the Android icons from post 41 in this thread

Result: didnt change anything:

Code (glbasic) Select

_______________________________________
*** Configuration: ANDROID ***
precompiling:
GPC - GLBasic Precompiler V.10.060 SN:bdf43d6f - 3D, NET
Wordcount:4 commands
compile+link:

running glb_build.bat
Using ANDROID_TARGET="android-19"
You can use "C:\Users\Gans\Documents\GLBasic\8feb\distribute\Android\glb_android_build.bat" to change the API level and SDK path.

Checking Icons (uses 'AndroidExtras_icons_X.png' For changes)....
C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android
C:/Users/Gans/Documents/GLBasic/8feb/icon_36_AndroidExtras.png is missing (36x36 size)
C:/Users/Gans/Documents/GLBasic/8feb/icon_36_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_36_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-ldpi/icon.png
C:/Users/Gans/Documents/GLBasic/8feb/icon_48_AndroidExtras.png is missing (48x48 size)
C:/Users/Gans/Documents/GLBasic/8feb/icon_48_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_48_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-mdpi/icon.png
C:/Users/Gans/Documents/GLBasic/8feb/icon_72_AndroidExtras.png is missing (72x72 size)
C:/Users/Gans/Documents/GLBasic/8feb/icon_72_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_72_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-hdpi/icon.png
C:/Users/Gans/Documents/GLBasic/8feb/icon_96_AndroidExtras.png is missing (96x96 size)
C:/Users/Gans/Documents/GLBasic/8feb/icon_96_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_96_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-xhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/8feb/icon_180_AndroidExtras.png is missing (180x180 size)
C:/Users/Gans/Documents/GLBasic/8feb/icon_180_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_180_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-xxhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/8feb/icon_192_AndroidExtras.png is missing (192x192 size)
C:/Users/Gans/Documents/GLBasic/8feb/icon_192_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_192_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-xxxhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/8feb/icon_ouya_AndroidExtras.png is missing (732x412 size)
the Ouya icon is not important, if you dont want to support the console
copy C:/Users/Gans/Documents/GLBasic/8feb/icon_ouya_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/8feb/distribute/Android/res/drawable-xhdpi/ouya_icon.png
Checking Icons Finished...

BUILD STAGE 2: Start compiler (android.bat)
Q:\Compiler\platform\android\bin\..\android-sdk-windows
Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
.
BUILD STAGE 3: Build a debug build
Buildfile: build.xml does not exist!
Build failed
.
BUILD STAGE 4: Build a release build
Buildfile: build.xml does not exist!
Build failed
Picked up _JAVA_OPTIONS: -Xms256m -Xmx512m
.
HOW TO INSTALL? Install by invoke this command:
"Q:\Compiler\platform\android\bin\..\android-sdk-windows\platform-tools\adb.exe" install -r "C:\Users\Gans\Documents\GLBasic\8feb\distribute\Android/bin/glbasic-debug.apk"
.
HOW TO SIGN? Sign it by invoke this command:
"Q:\Compiler\platform\android\bin\glb_code_sign.bat" "C:\Users\Gans\Documents\GLBasic\8feb\distribute\Android"
.
Android=C:\Users\Gans\Documents\GLBasic\8feb\distribute\Android
erfolgreich
_______________________________________
*** Fertig ***
Dauer: 5.7 sek. Zeit: 05:44
Erstellen: 1 erfolgreich.


Spacefractal:
Property ant might been missing as Various required Builds tools?

Im Thinks you should remove ANDROIDSDK from the Path, so glBasic uses that one that is include.

Also im also uses Java JDK 1.7, not Java JDK 1.8.

Also make sure to restart after removing ANDROIDSDK var.

Ps. I'm checkout the none wifi crash in the few days.

ProN3rd

#1
Thank you guys for the comments, i still cant get this working, this is what i did in detail:

1) Fresh install of Java SDK (32 Bit) 7.0 Update 75,
2) JAVA_HOME = C:\Program Files (x86)\Java\jdk1.7.0_75
3) Fresh install of ANT
4) ANT_HOME = C:\Program Files (x86)\Java\apache-ant-1.9.4
5) Path = %ANT_HOME%\bin;  %JAVA_HOME%\bin
6) Android SDK manager is installed to C:\Android\android-sdk no ANDROIDSDK variable is set yet
7) All Build Tools and Extras within Android SDK are downloaded and installed
8 ) Device emulated: Android 4.4.2. Api Level 19 (willbe running in background from now on)

9) Downloaded GL Basic from the main site (SF`s link) and installed (Its version 12.308 and not v12.312), Restarting after installation. (All previous version were deinstalled, and registry was cleaned with CCleaner)

10) I have downloaded Android Extras 2.7.2 released  2015-Feb-05 , the first link where API 19 is included (http://www.glbasic.com/forum/index.php?topic=9644.msg83746#msg83746)

11) Also downloaded http://www.glbasic.com/forum/index.php?topic=9166.165 , but i think i dont need it its from  2015-Feb-03

12) Also downloaded sdl_main.zip from http://www.glbasic.com/forum/index.php?topic=10106.msg88735#msg88735 , but i think i dont need it

13) First testing without any addons, project settings = Android, newproject = test1
Code (glbasic) Select

WHILE TRUE
DRAWRECT 10,10,100,100,RGB(255,255,0)
SHOWSCREEN
WEND


14) error log would exceed 20.000 charachters so i just post some excerpts:

Code (glbasic) Select

_______________________________________
*** Configuration: ANDROID ***
precompiling:
GPC - GLBasic Precompiler V.10.053 SN:bdf43d6f - 3D, NET
Wordcount:4 commands
compile+link:
running glb_build.bat
Using ANDROID_TARGET="android-8"
You can use "C:\Users\Gans\Documents\GLBasic\test1\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 project.properties
Updated local.properties
Updated file C:\Users\Gans\Documents\GLBasic\test1\distribute\Android\build.xml
Updated file C:\Users\Gans\Documents\GLBasic\test1\distribute\Android\proguard.cfg

BUILD FAILED
Q:\Compiler\platform\android\android-sdk-windows\tools\ant\build.xml:580: The following error occurred while executing this line:
Q:\Compiler\platform\android\android-sdk-windows\tools\ant\build.xml:602: Compile failed; see the compiler error output for details.

Total time: 1 second
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...
    [javac] C:\Users\Gans\Documents\GLBasic\test1\distribute\Android\src\com\glbasic\test\Downloads.java:6: error: cannot find symbol

...
    [javac] 79 errors
    [javac] 19 warnings

BUILD FAILED
Q:\Compiler\platform\android\android-sdk-windows\tools\ant\build.xml:580: The following error occurred while executing this line:
Q:\Compiler\platform\android\android-sdk-windows\tools\ant\build.xml:602: Compile failed; see the compiler error output for details.

Total time: 3 seconds
Picked up _JAVA_OPTIONS: -Xms256m -Xmx512m
finished Android build-script.
Android=C:\Users\Gans\Documents\GLBasic\test1\distribute\Android
erfolgreich
_______________________________________
*** Fertig ***
Dauer: 9.0 sek. Zeit: 20:01
Erstellen: 1 erfolgreich.



15) Installing AE, new project test 2

16)

Code (glbasic) Select

_______________________________________
*** Configuration: ANDROID ***
precompiling:
GPC - GLBasic Precompiler V.10.053 SN:bdf43d6f - 3D, NET
Wordcount:4 commands
compile+link:

running glb_build.bat
Using ANDROID_TARGET="android-19"
You can use "C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\glb_android_build.bat" to change the API level and SDK path.
%ANDROIDSDK% not set. Using GLBasic's default target-19, Android 4.4 (KitKat

Checking Icons (uses 'AndroidExtras_icons_X.png' For changes)....
C:/Users/Gans/Documents/GLBasic/test2/distribute/Android
C:/Users/Gans/Documents/GLBasic/test2/icon_36_AndroidExtras.png is missing (36x36 size)
C:/Users/Gans/Documents/GLBasic/test2/icon_36_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/test2/icon_36_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test2/distribute/Android/res/drawable-ldpi/icon.png
C:/Users/Gans/Documents/GLBasic/test2/icon_48_AndroidExtras.png is missing (48x48 size)
C:/Users/Gans/Documents/GLBasic/test2/icon_48_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/test2/icon_48_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test2/distribute/Android/res/drawable-mdpi/icon.png
C:/Users/Gans/Documents/GLBasic/test2/icon_72_AndroidExtras.png is missing (72x72 size)
C:/Users/Gans/Documents/GLBasic/test2/icon_72_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/test2/icon_72_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test2/distribute/Android/res/drawable-hdpi/icon.png
C:/Users/Gans/Documents/GLBasic/test2/icon_96_AndroidExtras.png is missing (96x96 size)
C:/Users/Gans/Documents/GLBasic/test2/icon_96_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/test2/icon_96_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test2/distribute/Android/res/drawable-xhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/test2/icon_180_AndroidExtras.png is missing (180x180 size)
C:/Users/Gans/Documents/GLBasic/test2/icon_180_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/test2/icon_180_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test2/distribute/Android/res/drawable-xxhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/test2/icon_192_AndroidExtras.png is missing (192x192 size)
C:/Users/Gans/Documents/GLBasic/test2/icon_192_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/test2/icon_192_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test2/distribute/Android/res/drawable-xxxhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/test2/icon_ouya_AndroidExtras.png is missing (732x412 size)
the Ouya icon is not important, if you dont want to support the console
copy C:/Users/Gans/Documents/GLBasic/test2/icon_ouya_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test2/distribute/Android/res/drawable-xhdpi/ouya_icon.png
Checking Icons Finished...

BUILD STAGE 2: Start compiler (android.bat)
Q:\Compiler\platform\android\bin\..\android-sdk-windows
Updated and renamed default.properties to project.properties
Updated local.properties
Added file C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\build.xml
Added file C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\proguard-project.txt
.
BUILD STAGE 3: Build a debug build
Buildfile: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\build.xml

-set-mode-check:

-set-debug-files:

-check-env:
[checkenv] Android SDK Tools Revision 24.0.2
[checkenv] Installed at Q:\Compiler\platform\android\android-sdk-windows

-setup:
     [echo] Project Name: glbasic
  [gettype] Project Type: Application

-set-debug-mode:

-debug-obfuscation-check:

-pre-build:

-build-setup:
[getbuildtools] Using latest Build Tools: 21.1.2
     [echo] Resolving Build Target for glbasic...
[gettarget] Project Target:   Android 4.4.2
[gettarget] API level:        19
     [echo] ----------
     [echo] Creating output directories if needed...
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\rsObj
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\rsLibs
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\gen
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\classes
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\dexedLibs
     [echo] ----------
     [echo] Resolving Dependencies for glbasic...
[dependency] Library dependencies:
[dependency] No Libraries
[dependency]
[dependency] ------------------
     [echo] ----------
     [echo] Building Libraries with 'debug'...
   [subant] No sub-builds to iterate on

-code-gen:
[mergemanifest] Merging AndroidManifest files into one.
[mergemanifest] Manifest merger disabled. Using project manifest only.
     [echo] Handling aidl files...
     [aidl] No AIDL files to compile.
     [echo] ----------
     [echo] Handling RenderScript files...
     [echo] ----------
     [echo] Handling Resources...
     [aapt] Generating resource IDs...
     [echo] ----------
     [echo] Handling BuildConfig class...
[buildconfig] Generating BuildConfig class.

-pre-compile:

-compile:
    [javac] Compiling 29 source files to C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\classes
    [javac] Note: Some input files use or override a deprecated API.
    [javac] Note: Recompile with -Xlint:deprecation for details.

-post-compile:

-obfuscate:

-dex:
      [dex] input: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\classes
      [dex] input: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\libs\ouya-sdk.jar
      [dex] input: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\libs\gson-2.2.2.jar
      [dex] input: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\libs\google-play-services.jar
      [dex] input: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\libs\android-support-v4.jar
      [dex] input: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\libs\openiab-0.9.7.2.jar
      [dex] Pre-Dexing C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\libs\ouya-sdk.jar -> ouya-sdk-d42275bbda60fcbbc73b30793b1e1fc5.jar
      [dex] Pre-Dexing C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\libs\gson-2.2.2.jar -> gson-2.2.2-c829a3bc9ea9df9195c79b76329ee971.jar
      [dex] Pre-Dexing C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\libs\google-play-services.jar -> google-play-services-95daa1613ceb81a207d749753c53282c.jar
      [dex] Pre-Dexing C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\libs\android-support-v4.jar -> android-support-v4-80c1a71df3db4eec01a3f5fcf8b6e815.jar
      [dex] Pre-Dexing C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\libs\openiab-0.9.7.2.jar -> openiab-0.9.7.2-4d76fade949e2bb020af1ec0812ede98.jar
      [dex] Converting compiled files and external libraries into C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\classes.dex...
       [dx] Merged dex A (72 defs/129.7KiB) with dex B (204 defs/179.5KiB). Result is 276 defs/371.6KiB. Took 0.1s
       [dx] Merged dex A (276 defs/371.6KiB) with dex B (155 defs/153.0KiB). Result is 431 defs/656.1KiB. Took 0.0s
       [dx] Merged dex A (431 defs/656.1KiB) with dex B (1869 defs/1854.6KiB). Result is 2300 defs/3087.3KiB. Took 0.1s
       [dx] Result compacted from 4504.9KiB to 2699.1KiB to save 1805.8KiB
       [dx] Merged dex A (2300 defs/3087.3KiB) with dex B (371 defs/436.8KiB). Result is 2671 defs/2699.1KiB. Took 0.3s
       [dx] Merged dex A (2671 defs/2699.1KiB) with dex B (169 defs/183.0KiB). Result is 2840 defs/3479.9KiB. Took 0.1s

-crunch:
   [crunch] Crunching PNG Files in source dir: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\res
   [crunch] To destination dir: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\res\drawable-hdpi\icon.png => C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-hdpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-hdpi\icon.png: 0% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\res\drawable-ldpi\icon.png => C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-ldpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-ldpi\icon.png: 0% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\res\drawable-mdpi\icon.png => C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-mdpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-mdpi\icon.png: 0% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\res\drawable-xhdpi\icon.png => C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-xhdpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-xhdpi\icon.png: 68% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\res\drawable-xhdpi\ouya_icon.png => C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-xhdpi\ouya_icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-xhdpi\ouya_icon.png: 73% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\res\drawable-xxhdpi\icon.png => C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-xxhdpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-xxhdpi\icon.png: 78% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\res\drawable-xxxhdpi\icon.png => C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-xxxhdpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable-xxxhdpi\icon.png: 94% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\res\drawable\icon.png => C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\res\drawable\icon.png: 63% size of source)
   [crunch] Crunched 8 PNG files to update cache

-package-resources:
     [aapt] Creating full resource package...
     [aapt] Warning: AndroidManifest.xml already defines debuggable (in http://schemas.android.com/apk/res/android); using existing value in manifest.

-package:
[apkbuilder] Current build type is different than previous build: forced apkbuilder run.
[apkbuilder] Creating glbasic-debug-unaligned.apk and signing it with a debug key...

-post-package:

-do-debug:
[zipalign] Running zip align on final apk...
     [echo] Debug Package: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\glbasic-debug.apk
[propertyfile] Creating new property file: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\build.prop
[propertyfile] Updating property file: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\build.prop
[propertyfile] Updating property file: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\build.prop
[propertyfile] Updating property file: C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\build.prop

-post-build:

debug:

BUILD SUCCESSFUL
Total time: 25 seconds
.
BUILD STAGE 4: Build a release build
   [subant] No sub-builds to iterate on
    [javac] Note: Some input files use or override a deprecated API.
    [javac] Note: Recompile with -Xlint:deprecation for details.

BUILD SUCCESSFUL
Total time: 4 seconds
Picked up _JAVA_OPTIONS: -Xms256m -Xmx512m
.
HOW TO INSTALL? Install by invoke this command:
"Q:\Compiler\platform\android\bin\..\android-sdk-windows\platform-tools\adb.exe" install -r "C:\Users\Gans\Documents\GLBasic\test2\distribute\Android/bin/glbasic-debug.apk"
.
HOW TO SIGN? Sign it by invoke this command:
"Q:\Compiler\platform\android\bin\glb_code_sign.bat" "C:\Users\Gans\Documents\GLBasic\test2\distribute\Android"
.
Android=C:\Users\Gans\Documents\GLBasic\test2\distribute\Android
erfolgreich
_______________________________________
*** Fertig ***
Dauer: 35.2 sek. Zeit: 20:09
Erstellen: 1 erfolgreich.


17) this time apk file is created but not installed. I ran CMD and write: adb install C:\Users\Gans\Documents\GLBasic\test2\distribute\Android\bin\glbasic-debug-unaligned.apk and app installes, however if i open it it sais "Unfortunately <APP Name> has stopped

to be continued see next post:

ProN3rd

#2
18) changing the bat file to Android-18, new project test3.

19)
Code (glbasic) Select

_______________________________________
*** Configuration: ANDROID ***
precompiling:
GPC - GLBasic Precompiler V.10.053 SN:bdf43d6f - 3D, NET
Wordcount:4 commands
compile+link:

running glb_build.bat
Using ANDROID_TARGET="android-18"
You can use "C:\Users\Gans\Documents\GLBasic\test3\distribute\Android\glb_android_build.bat" to change the API level and SDK path.
%ANDROIDSDK% not set. Using GLBasic's default target-19, Android 4.4 (KitKat

Checking Icons (uses 'AndroidExtras_icons_X.png' For changes)....
C:/Users/Gans/Documents/GLBasic/test3/distribute/Android
copy C:/Users/Gans/Documents/GLBasic/test3/icon_36_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test3/distribute/Android/res/drawable-ldpi/icon.png
copy C:/Users/Gans/Documents/GLBasic/test3/icon_48_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test3/distribute/Android/res/drawable-mdpi/icon.png
copy C:/Users/Gans/Documents/GLBasic/test3/icon_72_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test3/distribute/Android/res/drawable-hdpi/icon.png
copy C:/Users/Gans/Documents/GLBasic/test3/icon_96_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test3/distribute/Android/res/drawable-xhdpi/icon.png
copy C:/Users/Gans/Documents/GLBasic/test3/icon_180_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test3/distribute/Android/res/drawable-xxhdpi/icon.png
copy C:/Users/Gans/Documents/GLBasic/test3/icon_192_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test3/distribute/Android/res/drawable-xxxhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/test3/icon_ouya_AndroidExtras.png is missing (732x412 size)
the Ouya icon is not important, if you dont want to support the console
copy C:/Users/Gans/Documents/GLBasic/test3/icon_ouya_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test3/distribute/Android/res/drawable-xhdpi/ouya_icon.png
Checking Icons Finished...

BUILD STAGE 2: Start compiler (android.bat)
Q:\Compiler\platform\android\bin\..\android-sdk-windows
Error: Target id 'android-18' is not valid. Use 'android.bat list targets' to get the target ids.
.
BUILD STAGE 3: Build a debug build
Buildfile: build.xml does not exist!
Build failed
.
BUILD STAGE 4: Build a release build
Buildfile: build.xml does not exist!
Build failed
Picked up _JAVA_OPTIONS: -Xms256m -Xmx512m
.
HOW TO INSTALL? Install by invoke this command:
"Q:\Compiler\platform\android\bin\..\android-sdk-windows\platform-tools\adb.exe" install -r "C:\Users\Gans\Documents\GLBasic\test3\distribute\Android/bin/glbasic-debug.apk"
.
HOW TO SIGN? Sign it by invoke this command:
"Q:\Compiler\platform\android\bin\glb_code_sign.bat" "C:\Users\Gans\Documents\GLBasic\test3\distribute\Android"
.
Android=C:\Users\Gans\Documents\GLBasic\test3\distribute\Android
erfolgreich
_______________________________________
*** Fertig ***
Dauer: 5.2 sek. Zeit: 20:20
Erstellen: 1 erfolgreich.


20) no apk file created

Summary: I had the biggest success with just installing the AE including API 19, however the APP doesnt install automatically, and when done by CMD, it wont open ("Unfortunatly <App name> has stopped")

Update: Meanwhile i tested everything with an emulated API 18 device, but this doenst change anything at all. I also tried to install an the  glbasic-debug-unaligned.apk file from the GLBasic_v12\Compiler\platform\android\Android Extras\AndroidSample.app\distribute\Android\bin folder but again: ("Unfortunatly <App name> has stopped")

Questions:
1) Is the code fine? i mean do i need to adjust any resolution things for the device? Its just a small test
2) What about the variable ANDROIDSDK does it need to be set?
3) maybe something is wrong with something else because the apk file from the extras folders wont open on the virtual device after installation?
3) What did I do wrong, why does this not work properly?

spacefractal

#3
I'm try to split your Android install issue to own tread by did only moved one post. Until then use this thread. Sorry.

Property it a ant issue, so not can find the build.xml and then fails. When I'm is home I'm will zip anything I'm have from the Android folder which include api 19 sdk and also include ant installed correctly (full install should do that as well, but zip it down just to make sure).

ant_home should property not been included in its path. It's might also point to a wrong folder.

Also only uses api-19, it'd required now and is included with full installer. So defensivt a ant issue.

Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/

ProN3rd

#4
thank you SF,

i have removed the ANT_HOME variables and also cleared the Path variable, i am testing on API 19 now again with a brand new project:

Code (glbasic) Select

_______________________________________
*** Configuration: ANDROID ***
precompiling:
GPC - GLBasic Precompiler V.10.053 SN:bdf43d6f - 3D, NET
Wordcount:4 commands
compile+link:

running glb_build.bat
Using ANDROID_TARGET="android-19"
You can use "C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\glb_android_build.bat" to change the API level and SDK path.
%ANDROIDSDK% not set. Using GLBasic's default target-19, Android 4.4 (KitKat

Checking Icons (uses 'AndroidExtras_icons_X.png' For changes)....
C:/Users/Gans/Documents/GLBasic/test5/distribute/Android
C:/Users/Gans/Documents/GLBasic/test5/icon_36_AndroidExtras.png is missing (36x36 size)
C:/Users/Gans/Documents/GLBasic/test5/icon_36_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/test5/icon_36_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test5/distribute/Android/res/drawable-ldpi/icon.png
C:/Users/Gans/Documents/GLBasic/test5/icon_48_AndroidExtras.png is missing (48x48 size)
C:/Users/Gans/Documents/GLBasic/test5/icon_48_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/test5/icon_48_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test5/distribute/Android/res/drawable-mdpi/icon.png
C:/Users/Gans/Documents/GLBasic/test5/icon_72_AndroidExtras.png is missing (72x72 size)
C:/Users/Gans/Documents/GLBasic/test5/icon_72_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/test5/icon_72_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test5/distribute/Android/res/drawable-hdpi/icon.png
C:/Users/Gans/Documents/GLBasic/test5/icon_96_AndroidExtras.png is missing (96x96 size)
C:/Users/Gans/Documents/GLBasic/test5/icon_96_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/test5/icon_96_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test5/distribute/Android/res/drawable-xhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/test5/icon_180_AndroidExtras.png is missing (180x180 size)
C:/Users/Gans/Documents/GLBasic/test5/icon_180_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/test5/icon_180_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test5/distribute/Android/res/drawable-xxhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/test5/icon_192_AndroidExtras.png is missing (192x192 size)
C:/Users/Gans/Documents/GLBasic/test5/icon_192_AndroidExtras.png is created
copy C:/Users/Gans/Documents/GLBasic/test5/icon_192_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test5/distribute/Android/res/drawable-xxxhdpi/icon.png
C:/Users/Gans/Documents/GLBasic/test5/icon_ouya_AndroidExtras.png is missing (732x412 size)
the Ouya icon is not important, if you dont want to support the console
copy C:/Users/Gans/Documents/GLBasic/test5/icon_ouya_AndroidExtras.png to C:/Users/Gans/Documents/GLBasic/test5/distribute/Android/res/drawable-xhdpi/ouya_icon.png
Checking Icons Finished...

BUILD STAGE 2: Start compiler (android.bat)
Q:\Compiler\platform\android\bin\..\android-sdk-windows
Updated and renamed default.properties to project.properties
Updated local.properties
Added file C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\build.xml
Added file C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\proguard-project.txt
.
BUILD STAGE 3: Build a debug build
Buildfile: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\build.xml

-set-mode-check:

-set-debug-files:

-check-env:
[checkenv] Android SDK Tools Revision 24.0.2
[checkenv] Installed at Q:\Compiler\platform\android\android-sdk-windows

-setup:
     [echo] Project Name: glbasic
  [gettype] Project Type: Application

-set-debug-mode:

-debug-obfuscation-check:

-pre-build:

-build-setup:
[getbuildtools] Using latest Build Tools: 21.1.2
     [echo] Resolving Build Target for glbasic...
[gettarget] Project Target:   Android 4.4.2
[gettarget] API level:        19
     [echo] ----------
     [echo] Creating output directories if needed...
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\rsObj
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\rsLibs
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\gen
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\classes
    [mkdir] Created dir: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\dexedLibs
     [echo] ----------
     [echo] Resolving Dependencies for glbasic...
[dependency] Library dependencies:
[dependency] No Libraries
[dependency]
[dependency] ------------------
     [echo] ----------
     [echo] Building Libraries with 'debug'...
   [subant] No sub-builds to iterate on

-code-gen:
[mergemanifest] Merging AndroidManifest files into one.
[mergemanifest] Manifest merger disabled. Using project manifest only.
     [echo] Handling aidl files...
     [aidl] No AIDL files to compile.
     [echo] ----------
     [echo] Handling RenderScript files...
     [echo] ----------
     [echo] Handling Resources...
     [aapt] Generating resource IDs...
     [echo] ----------
     [echo] Handling BuildConfig class...
[buildconfig] Generating BuildConfig class.

-pre-compile:

-compile:
    [javac] Compiling 29 source files to C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\classes
    [javac] Note: Some input files use or override a deprecated API.
    [javac] Note: Recompile with -Xlint:deprecation for details.

-post-compile:

-obfuscate:

-dex:
      [dex] input: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\classes
      [dex] input: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\libs\ouya-sdk.jar
      [dex] input: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\libs\gson-2.2.2.jar
      [dex] input: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\libs\google-play-services.jar
      [dex] input: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\libs\android-support-v4.jar
      [dex] input: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\libs\openiab-0.9.7.2.jar
      [dex] Pre-Dexing C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\libs\ouya-sdk.jar -> ouya-sdk-d5509fac6ece22a5397c03855fbea858.jar
      [dex] Pre-Dexing C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\libs\gson-2.2.2.jar -> gson-2.2.2-7a42e307e18c3e4af900d9f9f2104010.jar
      [dex] Pre-Dexing C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\libs\google-play-services.jar -> google-play-services-9fddcea9b62cec7784285ef84ae95c84.jar
      [dex] Pre-Dexing C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\libs\android-support-v4.jar -> android-support-v4-8342a3c0af265d3004364599502a6efa.jar
      [dex] Pre-Dexing C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\libs\openiab-0.9.7.2.jar -> openiab-0.9.7.2-f9cc4c465241b827bfb5e0e779e7224d.jar
      [dex] Converting compiled files and external libraries into C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\classes.dex...
       [dx] Merged dex A (72 defs/129.7KiB) with dex B (204 defs/179.5KiB). Result is 276 defs/371.6KiB. Took 0.1s
       [dx] Merged dex A (276 defs/371.6KiB) with dex B (155 defs/153.0KiB). Result is 431 defs/656.1KiB. Took 0.0s
       [dx] Merged dex A (431 defs/656.1KiB) with dex B (1869 defs/1854.6KiB). Result is 2300 defs/3087.3KiB. Took 0.1s
       [dx] Result compacted from 4504.9KiB to 2699.1KiB to save 1805.8KiB
       [dx] Merged dex A (2300 defs/3087.3KiB) with dex B (371 defs/436.8KiB). Result is 2671 defs/2699.1KiB. Took 0.3s
       [dx] Merged dex A (2671 defs/2699.1KiB) with dex B (169 defs/183.0KiB). Result is 2840 defs/3479.9KiB. Took 0.1s

-crunch:
   [crunch] Crunching PNG Files in source dir: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\res
   [crunch] To destination dir: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\res\drawable-hdpi\icon.png => C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-hdpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-hdpi\icon.png: 0% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\res\drawable-ldpi\icon.png => C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-ldpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-ldpi\icon.png: 0% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\res\drawable-mdpi\icon.png => C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-mdpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-mdpi\icon.png: 0% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\res\drawable-xhdpi\icon.png => C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-xhdpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-xhdpi\icon.png: 68% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\res\drawable-xhdpi\ouya_icon.png => C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-xhdpi\ouya_icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-xhdpi\ouya_icon.png: 73% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\res\drawable-xxhdpi\icon.png => C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-xxhdpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-xxhdpi\icon.png: 78% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\res\drawable-xxxhdpi\icon.png => C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-xxxhdpi\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable-xxxhdpi\icon.png: 94% size of source)
   [crunch] Processing image to cache: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\res\drawable\icon.png => C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable\icon.png
   [crunch]   (processed image to cache entry C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\res\drawable\icon.png: 63% size of source)
   [crunch] Crunched 8 PNG files to update cache

-package-resources:
     [aapt] Creating full resource package...
     [aapt] Warning: AndroidManifest.xml already defines debuggable (in http://schemas.android.com/apk/res/android); using existing value in manifest.

-package:
[apkbuilder] Current build type is different than previous build: forced apkbuilder run.
[apkbuilder] Creating glbasic-debug-unaligned.apk and signing it with a debug key...

-post-package:

-do-debug:
[zipalign] Running zip align on final apk...
     [echo] Debug Package: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\glbasic-debug.apk
[propertyfile] Creating new property file: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\build.prop
[propertyfile] Updating property file: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\build.prop
[propertyfile] Updating property file: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\build.prop
[propertyfile] Updating property file: C:\Users\Gans\Documents\GLBasic\test5\distribute\Android\bin\build.prop

-post-build:

debug:

BUILD SUCCESSFUL
Total time: 23 seconds
.
BUILD STAGE 4: Build a release build
   [subant] No sub-builds to iterate on
    [javac] Note: Some input files use or override a deprecated API.
    [javac] Note: Recompile with -Xlint:deprecation for details.

BUILD SUCCESSFUL
Total time: 4 seconds
Picked up _JAVA_OPTIONS: -Xms256m -Xmx512m
.
HOW TO INSTALL? Install by invoke this command:
"Q:\Compiler\platform\android\bin\..\android-sdk-windows\platform-tools\adb.exe" install -r "C:\Users\Gans\Documents\GLBasic\test5\distribute\Android/bin/glbasic-debug.apk"
.
HOW TO SIGN? Sign it by invoke this command:
"Q:\Compiler\platform\android\bin\glb_code_sign.bat" "C:\Users\Gans\Documents\GLBasic\test5\distribute\Android"
.
Android=C:\Users\Gans\Documents\GLBasic\test5\distribute\Android
erfolgreich
_______________________________________
*** Fertig ***
Dauer: 33.7 sek. Zeit: 22:03
Erstellen: 1 erfolgreich.


I get the apk file but, it doesnt install automatically. when doing manually i get "Unforunately <-App name > has stopped" on the virtual device. I get this message everytime I install a glbasic coded apk file. Even those which should be working. I installed other apk and they work.


spacefractal

#5
You need to install it's manually. This due the automatic install was too unstable and ofte hanging

You should uses the debug build for testing, which is only that that working.

But the compiling goes fine.
Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/

ProN3rd

#6
ok i used the debug version glbasic-debug.apk, but on the virtual device i always get the message:

unfortunatly <app name> has stopped.

maybe me code is wrong because its very simple test, but I get this all the time when i install glbasic apk, even those ones that should be working. What can i do to prevent that?

spacefractal

im dosent uses virtual device at all. There might been various issues with emulators or might have conflicted with example glbasic-release-unsigned.apk, so uninstall that first.

You should use a real device, because im really do not support default emulators. The best emulator im do tested with quite succes is "BlueStacks".

Also For eventuelly crashes like that one shown, im need the logcat, which will tell why and where its crash. Its could also been a permission issue in androidmanifest.xml.

But start _logview.bat (Compiler\platform\android\bin) and then its will output the crash log.
Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/

ProN3rd

#8
i ran the logview.bat and this is the result:

unfortunately i dont have a real device yet, i was hoping wo emulate it at first :)

downloading bluestacks now

spacefractal

#9
"Couldn't load SDL2 from loader". Its failed in System.loadLibrary("SDL2") line, the graphics system (libSDL2.so in distribute\Android\libs\armeabi). Property the emulator is not supported.

PS. YOu can eventuelly post the apk, if you want to test me on a real device. Im do guess all compiling is now fine.
Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/

ProN3rd

#10
thank you SF the compiling works. I am using BlueStacks now and it works like a charm.
I have installed also your sample from AE extras, nice job.

remains a mystery though why it didnt work on Android SDK, i have tried so many things, but I can change the resolution of BlueStacks, to emulate various devices for my testings :)

Now, i was wondering how to change my code from my tile based game to fit all possible screen resolutions. I did calculate the max possible tilesize depending on the devices GETSCREENSIZE, and rendering with STRETCHSPRITE. So far it works but it is just a test project, i have several hundreds of sprites in my game. Also the walking speed and everything will be relative to Tilesize. I cant image all the changes :D . How would you guys approach this?

Maybe I should create another thread for this.  =D

Ian Price

QuoteNow, i was wondering how to change my code from my tile based game to fit all possible screen resolutions. I did calculate the max possible tilesize depending on the devices GETSCREENSIZE, and rendering with STRETCHSPRITE. So far it works but it is just a test project, i have several hundreds of sprites in my game. Also the walking speed and everything will be relative to Tilesize. I cant image all the changes :D . How would you guys approach this?

What you can do is create a virtual screen, draw everything onto that and then scale that to fullscreen. You don't have to worry about different sizes then. Or you can start using delta timing and work with floats for movement...

Touch input would have to be configured to the screen size, but evyrthing else will be the same.
I came. I saw. I played.

spacefractal

#12
But virtual screen slowdown about 50% and avoid various issues on some platforms. I'm did not use that for any of my games (not even catchout which could have do that without issue).

So it's seen he does something like I'm did. But of course it's more complicated than way and require using different texture size.

But again it's depend on game and style of graphics and so on.
Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/

Ian Price

Depends how it's used, but yes it can slow down.

With him using 100s of sprites it's going to slow down A LOT with stretchsprite too. Perhaps the best method would be to use POLYNEWSTRIP?

If he's using the 100s of sprite to create a level (eg background tiles), he could predraw this onto a very large map at the start of the game and just use POLYVECTOR to display it and scale up accordingly.

There are a hundred ways to skin a cat, but a thousand ways to program an effect ;) :P
I came. I saw. I played.

spacefractal

Hehe yes. I'm did uses polyvector for most thing (tiled and most background). Catchout used it's insertivt from one color image....

greedy mouse die not use precalculated tiles. There can been about 800+ of them due layers. But small thing like hero and such thing used normal sprites.
Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/