Recent

Author Topic: [Closed] LazToApk 0.9.39 is available now.  (Read 11639 times)

DelphiFreak

  • Sr. Member
  • ****
  • Posts: 255
    • Fresh sound.
[Closed] LazToApk 0.9.39 is available now.
« on: December 13, 2017, 06:28:33 am »
Hello,

a new version is available.
For users with already installed version 0.9.38, please select "update" in the setup. ( I only changed laztoapk.exe so no need to download all the 3rd-Party stuff again).

What's new ?

17.Dez. 2017 (v0.9.0.39)
- updated laztoapk.exe. Improved user-interface.
- updated laztoapk.exe. Avoid overwrite of existing projects.
- updated installer. Pre-defined install types "full","update","custom".

13.Dez. 2017 (v0.9.0.38)
- updated to download laz4android1.8.0-FPC3.0.4.7z
- updated to download android-ndk-r14b-windows-x86.zip
- changed laztoapk to use new laz4android-path "laz4android1.8".
- preparations to use this setup also with LAMW.
- updated installation documentation.

The documentation:
https://sourceforge.net/projects/laztoapk/files/Lazarus%20and%20Android.pdf/download

The installer:
https://sourceforge.net/projects/laztoapk/files/?source=navbar

Have fun...

Sam
« Last Edit: December 31, 2018, 06:14:21 am by DelphiFreak »
Linux Mint 20.3, Lazarus 2.3, Windows 10, Delphi 10.3 Rio, Delphi 11.1 Alexandria

Handoko

  • Hero Member
  • *****
  • Posts: 5122
  • My goal: build my own game engine using Lazarus
Re: LazToApk 0.9.38 is available now.
« Reply #1 on: December 13, 2017, 07:52:05 am »
Great, and thank you.
I'm a bit busy currently, will test it later and report back my test result.

turrican

  • Full Member
  • ***
  • Posts: 133
  • Pascal is my life.
    • Homepage
Re: LazToApk 0.9.38 is available now.
« Reply #2 on: December 13, 2017, 03:32:48 pm »
Hello,

a new version is available.
What's new ?

13.Dez. 2017 (v0.9.0.38)
- updated to download laz4android1.8.0-FPC3.0.4.7z
- updated to download android-ndk-r14b-windows-x86.zip
- changed laztoapk to use new laz4android-path "laz4android1.8".
- preparations to use this setup also with LAMW.
- updated installation documentation.

The documentation:
https://sourceforge.net/projects/laztoapk/files/Lazarus%20and%20Android.pdf/download

The installer:
https://sourceforge.net/projects/laztoapk/files/?source=navbar

Have fun...

Sam

Thanks this is a great tool!

CC

  • Full Member
  • ***
  • Posts: 149
Re: LazToApk 0.9.38 is available now.
« Reply #3 on: December 14, 2017, 06:38:46 pm »
Hi,

When running a simple project created by LazToAPK the main form appears  for a split second with the form header,  but without its content and  after that the app is terminated.

Cfg:
Huawei  P8
Android 5.01
API version 4.0/5.11
Custom opitons: -CfVFPV3 -CpARMV7A 
The result was the same with the original options -CpARMV6 ...

This is the relevant part of the ADB log:

Code: Pascal  [Select][+][-]
  1.  
  2. W/PGMiddleWare( 3968): in handleAction, invoke client = com.huawei.pgmng.middleware.AudioEffectLowPowerImpl@32a43195, action = com.huawei.pgmng.PGAction@968a4ef actionId =10000 pkg =com.pascal.A02 extend1 =10251 extend2 = flag =3 type =1
  3.  
  4. I/lclapp  (29879): [LCLOnConfigurationChanged] i=0 lOldDPI=72 lNewDPI=422 lOldFormWidth=100 lNewFormWidth=1080
  5.  
  6. E/art     (29879): 0xab8e6b60 SpaceTypeMallocSpace begin=0x12c00000,end=0x12e01000,limit=0x22c00000,size=2MB,capacity=256MB,non_growth_limit_capacity=256MB,name="main rosalloc space"]
  7.  
  8. E/art     (29879): 0xabc66a58 allocspace main rosalloc space live-bitmap 3[begin=0x12c00000,end=0x22c00000]
  9.  
  10. E/art     (29879): 0xabc321d0 allocspace main rosalloc space mark-bitmap 3[begin=0x12c00000,end=0x22c00000]
  11.  
  12. E/art     (29879): 0xab8e50d8 SpaceTypeImageSpace begin=0x7049a000,end=0x710e7570,size=12MB,name="/data/dalvik-cache/arm/system@framework@boot.art"]
  13.  
  14. E/art     (29879): 0xab8e4e58 imagespace /data/dalvik-cache/arm/system@framework@boot.art live-bitmap 0[begin=0x7049a000,end=0x710e7600]
  15.  
  16. E/art     (29879): 0xab8e4e58 imagespace /data/dalvik-cache/arm/system@framework@boot.art live-bitmap 0[begin=0x7049a000,end=0x710e7600]
  17.  
  18. E/art     (29879): 0xaba9ad20 SpaceTypeZygoteSpace begin=0x748fd000,end=0x76345000,size=26MB,name="Zygote space"]
  19.  
  20. E/art     (29879): 0xab8e6820 allocspace zygote / non moving space live-bitmap 0[begin=0x748fd000,end=0x76345000]
  21.  
  22. E/art     (29879): 0xab8e4d70 allocspace zygote / non moving space mark-bitmap 0[begin=0x748fd000,end=0x76345000]
  23.  
  24. E/art     (29879): 0xab8e6d50 SpaceTypeMallocSpace begin=0x76345000,end=0x76351000,limit=0x788fd000,size=48KB,capacity=37MB,non_growth_limit_capacity=37MB,name="alloc space"]
  25.  
  26. E/art     (29879): 0xabbaae68 allocspace alloc space live-bitmap 4[begin=0x76345000,end=0x788fd000]
  27.  
  28. E/art     (29879): 0xabb1eb30 allocspace alloc space mark-bitmap 4[begin=0x76345000,end=0x788fd000]
  29.  
  30. E/art     (29879): 0xab8e9bb0 large object space:GcRetentionPolicyAlwaysCollect
  31.  
  32. F/art     (29879): art/runtime/check_jni.cc:65] JNI DETECTED ERROR IN APPLICATION: native code passing in reference to invalid stack indirect reference table or invalid reference: 0xffbffa60
  33.  
  34. F/art     (29879): art/runtime/check_jni.cc:65]     in call to SetObjectField
  35.  
  36. F/art     (29879): art/runtime/check_jni.cc:65]     from int com.pascal.A02.LCLActivity.LCLOnConfigurationChanged(int, int)
  37.  
  38. F/art     (29879): art/runtime/check_jni.cc:65] "main" prio=5 tid=1 Runnable
  39.  
  40. F/art     (29879): art/runtime/check_jni.cc:65]   | group="main" sCount=0 dsCount=0 obj=0x75a45960 self=0xab8ebf58
  41.  
  42. F/art     (29879): art/runtime/check_jni.cc:65]   | sysTid=29879 nice=-1 cgrp=apps/top_visible sched=0/0 handle=0xf713fec8
  43.  
  44. F/art     (29879): art/runtime/check_jni.cc:65]   | state=R schedstat=( 93688192 1835184 88 ) utm=6 stm=3 core=6 HZ=100
  45.  
  46. F/art     (29879): art/runtime/check_jni.cc:65]   | stack=0xff402000-0xff404000 stackSize=8MB
  47.  
  48. F/art     (29879): art/runtime/check_jni.cc:65]   | held mutexes= "mutator lock"(shared held)
  49.  
  50. F/art     (29879): art/runtime/check_jni.cc:65]   native: #00 pc 00004bec  /system/lib/libbacktrace_libc++.so (_ZN13UnwindCurrent6UnwindEjP8ucontext+23)
  51.  
  52. F/art     (29879): art/runtime/check_jni.cc:65]   native: #01 pc 00003489  /system/lib/libbacktrace_libc++.so (_ZN9Backtrace6UnwindEjP8ucontext+8)
  53.  
  54. F/art     (29879): art/runtime/check_jni.cc:65]   native: #02 pc 0025428d  /system/lib/libart.so (_ZN3art15DumpNativeStackERNSt3__113basic_ostreamIcNS0_11char_traitsIcEEEEiPKcPNS_6mirror9ArtMethodE+84)
  55.  
  56. F/art     (29879): art/runtime/check_jni.cc:65]   native: #03 pc 00238329  /system/lib/libart.so (_ZNK3art6Thread4DumpERNSt3__113basic_ostreamIcNS1_11char_traitsIcEEEE+160)
  57.  
  58. F/art     (29879): art/runtime/check_jni.cc:65]   native: #04 pc 000b140d  /system/lib/libart.so (_ZN3artL8JniAbortEPKcS1_+620)
  59.  
  60. F/art     (29879): art/runtime/check_jni.cc:65]   native: #05 pc 000b1b3d  /system/lib/libart.so (_ZN3art9JniAbortFEPKcS1_z+68)
  61.  
  62. F/art     (29879): art/runtime/check_jni.cc:65]   native: #06 pc 000b4007  /system/lib/libart.so (_ZN3art11ScopedCheck5CheckEbPKcz.constprop.128+710)
  63.  
  64. F/art     (29879): art/runtime/check_jni.cc:65]   native: #07 pc 000b77cd  /system/lib/libart.so (_ZN3art8CheckJNI14SetObjectFieldEP7_JNIEnvP8_jobjectP9_jfieldIDS4_+64)
  65.  
  66. F/art     (29879): art/runtime/check_jni.cc:65]   native: #08 pc 0007f430  /data/app/com.pascal.A02-1/lib/arm/liblclapp.so (???)
  67.  
  68. F/art     (29879): art/runtime/check_jni.cc:65]   at com.pascal.A02.LCLActivity.LCLOnConfigurationChanged(Native method)
  69.  
  70. F/art     (29879): art/runtime/check_jni.cc:65]   at com.pascal.A02.LCLActivity$LCLSurface.onDraw(LCLActivity.java:130)
  71.  
  72. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.View.draw(View.java:15047)
  73.  
  74. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.View.draw(View.java:14955)
  75.  
  76. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.ViewGroup.drawChild(ViewGroup.java:3304)
  77.  
  78. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3096)
  79.  
  80. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.View.draw(View.java:14950)
  81.  
  82. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.ViewGroup.drawChild(ViewGroup.java:3304)
  83.  
  84. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3096)
  85.  
  86. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.View.draw(View.java:14950)
  87.  
  88. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.ViewGroup.drawChild(ViewGroup.java:3304)
  89.  
  90. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3096)
  91.  
  92. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.View.draw(View.java:15050)
  93.  
  94. F/art     (29879): art/runtime/check_jni.cc:65]   at android.widget.FrameLayout.draw(FrameLayout.java:594)
  95.  
  96. F/art     (29879): art/runtime/check_jni.cc:65]   at com.android.internal.policy.impl.PhoneWindow$DecorView.draw(PhoneWindow.java:2611)
  97.  
  98. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.ViewRootImpl.drawSoftware(ViewRootImpl.java:2721)
  99.  
  100. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.ViewRootImpl.draw(ViewRootImpl.java:2608)
  101.  
  102. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.ViewRootImpl.performDraw(ViewRootImpl.java:2406)
  103.  
  104. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:2030)
  105.  
  106. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1094)
  107.  
  108. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:6054)
  109.  
  110. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.Choreographer$CallbackRecord.run(Choreographer.java:793)
  111.  
  112. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.Choreographer.doCallbacks(Choreographer.java:606)
  113.  
  114. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.Choreographer.doFrame(Choreographer.java:575)
  115.  
  116. F/art     (29879): art/runtime/check_jni.cc:65]   at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:779)
  117.  
  118. F/art     (29879): art/runtime/check_jni.cc:65]   at android.os.Handler.handleCallback(Handler.java:739)
  119.  
  120. F/art     (29879): art/runtime/check_jni.cc:65]   at android.os.Handler.dispatchMessage(Handler.java:95)
  121.  
  122. F/art     (29879): art/runtime/check_jni.cc:65]   at android.os.Looper.loop(Looper.java:135)
  123.  
  124. F/art     (29879): art/runtime/check_jni.cc:65]   at android.app.ActivityThread.main(ActivityThread.java:5538)
  125.  
  126. F/art     (29879): art/runtime/check_jni.cc:65]   at java.lang.reflect.Method.invoke!(Native method)
  127.  
  128. F/art     (29879): art/runtime/check_jni.cc:65]   at java.lang.reflect.Method.invoke(Method.java:372)
  129.  
  130. F/art     (29879): art/runtime/check_jni.cc:65]   at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:958)
  131.  
  132. F/art     (29879): art/runtime/check_jni.cc:65]   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:753)
  133.  
  134. F/art     (29879): art/runtime/check_jni.cc:65]
  135.  
  136. F/art     (29879): art/runtime/runtime.cc:286] Runtime aborting...
  137.  
  138.  
« Last Edit: December 15, 2017, 12:10:35 am by CC »

ahiggins

  • Jr. Member
  • **
  • Posts: 92
Re: LazToApk 0.9.38 is available now.
« Reply #4 on: December 14, 2017, 06:42:45 pm »
great work, will test shortly  :D

CC

  • Full Member
  • ***
  • Posts: 149
Re: LazToApk 0.9.38 is available now.
« Reply #5 on: December 15, 2017, 12:08:52 am »
There is already a topic about the same problem:

http://forum.lazarus.freepascal.org/index.php/topic,31977.0.html

kupferstecher

  • Hero Member
  • *****
  • Posts: 583
Re: LazToApk 0.9.38 is available now.
« Reply #6 on: December 15, 2017, 12:47:50 pm »
I learned from Handoko that in the last versions of LazToApk with CustomDrawn the android versions 5 and higher are not support (app crashes). At least a test with a app compiled with LazToApk 0.9.0.37 failed on android 5.

Perhaps it's (still) the same thing?

DelphiFreak

  • Sr. Member
  • ****
  • Posts: 255
    • Fresh sound.
Re: LazToApk 0.9.38 is available now.
« Reply #7 on: December 15, 2017, 12:57:11 pm »
Hi,

nothing has changed in CustomDrawn components. It looks like the development of this has "stalled".
Therefore I would like to move to LAMW. That's why I updated the installation PDF.
It describes how to install LAMW.
I also added the automatic download of ANT to laztoapk because LAMW needs that stuff somehow.

I played around a little with LAMW, but had also the expirence that some demo apps worked and some crashed.
Sorry I have no time/interest to dive deeper into this android stuff.

Next step would be to change laztoapk-GUI to compile LAMW projects.

Have fun.


Linux Mint 20.3, Lazarus 2.3, Windows 10, Delphi 10.3 Rio, Delphi 11.1 Alexandria

kupferstecher

  • Hero Member
  • *****
  • Posts: 583
Re: LazToApk 0.9.38 is available now.
« Reply #8 on: December 15, 2017, 11:32:55 pm »
Hello DelphiFreak,

thanks for the reply. I understand, its a CustomsDrawn issue, not a LazToApk issue.

It seems LAMW is becoming the standard. But I think the LCL-CustomDrawn approach is very presious and shouldn't be abandoned. Perhaps you could introduce LAMW without dropping CustomDrawn out of LazToApk.

Regards

Handoko

  • Hero Member
  • *****
  • Posts: 5122
  • My goal: build my own game engine using Lazarus
Re: LazToApk 0.9.38 is available now.
« Reply #9 on: December 16, 2017, 07:25:48 am »
@DelphiFreak

Is there any requirement for installing LazToApk 0.9.38? I can't install it on my WinXP sp2 system. The error already happened since version 0.9.36:

http://forum.lazarus.freepascal.org/index.php/topic,34897.msg229764.html#msg229764

DelphiFreak

  • Sr. Member
  • ****
  • Posts: 255
    • Fresh sound.
Re: LazToApk 0.9.38 is available now.
« Reply #10 on: December 16, 2017, 09:12:42 am »
Hello Handoko,

no there is no special requirement.
The previous versions (up to 0.9.37) I also tested on winxp SP3 and I saw never a message like this.
The version 0.9.38 I only tested on windows7.

Sorry.
Linux Mint 20.3, Lazarus 2.3, Windows 10, Delphi 10.3 Rio, Delphi 11.1 Alexandria

CC

  • Full Member
  • ***
  • Posts: 149
Re: LazToApk 0.9.39 is available now.
« Reply #11 on: December 17, 2017, 02:45:57 pm »
DelphiFreak

Customdrawn widgets can /supposed to be work for other platfroms, like IOs as well. I think it is worth considering to keep it alive. I am trying to fix the current issuses with Android 5+.

There is one basic  thing I do not understand: LaztoAPK creates normal TLabel ... controls for the demo app. I thought the  Customdrawn controls are meant to be used.
After replacing the main form for the app generated by LazToAPK  with a new empty one the app is working. After adding CD controls:

Code: Pascal  [Select][+][-]
  1.  
  2. I/lclapp  (14712): [FORMS.PP] ExceptionOccurred
  3.  
  4. I/lclapp  (14712):   Sender=EClassNotFound
  5.  
  6. I/lclapp  (14712):   Exception=Class "TCDButton" not found

What would be the basic concept for a CD  app?

CC

  • Full Member
  • ***
  • Posts: 149
Re: LazToApk 0.9.39 is available now.
« Reply #12 on: December 17, 2017, 06:32:24 pm »
The cause of  the exception is an IDE issue, the  declaration of the control  is not added to  the  unit when the control is placed on the form.  Te LFM file is updated properly.

CC

  • Full Member
  • ***
  • Posts: 149
Re: LazToApk 0.9.39 is available now.
« Reply #13 on: December 17, 2017, 08:46:35 pm »
Good news! I think I have found the problem and fixed it. Still needs testing, but  my simple test app is able to start and working properly on a device with Android 5.01.

CC

  • Full Member
  • ***
  • Posts: 149
Re: LazToApk 0.9.39 is available now.
« Reply #14 on: December 17, 2017, 11:17:33 pm »
Well, after some testing the original problem which made it  impossible to start the apps is solved. But the general state of  CustomDrawn controls for Android  does not look good at all. Slow screen refresh ... very unstable ... simple things like touch event on an image is not working...   

This requires quite some time to work on which I do not have right now. 

 

TinyPortal © 2005-2018