[Lazarus] CustomDrawn, Android: Crash on Device

Felipe Monteiro de Carvalho felipemonteiro.carvalho at gmail.com
Fri Dec 2 19:05:25 CET 2011


I just tested in my 2.3 emulator and it worked fine. It also works in
my HTC Wildfire 2.2

Try:

cd lazarus
svn diff

To check for local changes, it should show only the -dAndroid in lclbase.lpk

Now we can see from the log that it processes the initialization
sections correctly here:

> I/lclproject(  264): Trying to load liblclapp.so
> D/dalvikvm(  264): Trying to load lib
> /data/data/com.pascal.lcltest/lib/liblclapp.so 0x44ede248
> D/dalvikvm(  264): Added shared lib
> /data/data/com.pascal.lcltest/lib/liblclapp.so 0x44ede248

Then it calls JNI_OnLoad correctly:

> I/lclapp  (  264): JNI_OnLoad called
> I/lclapp  (  264): Reading our Activity Class

But I can't tell if it crashes inside JNI_OnLoad or after it.

You can open the file
lcl/interfaces/customdrawn/customdrawnobject_android.inc and add more
debug calls to JNI_OnLoad to see if it finishes.

If it finishes correctly, then try adding some -dVerbose* to lcl.lpk
like previously said to get more info.
-- 
Felipe Monteiro de Carvalho




More information about the Lazarus mailing list