[fpc-devel] Re: Building the Android branch
pascaldragon at googlemail.com
Thu Dec 20 17:09:38 CET 2012
Am 19.12.2012 17:18, schrieb Sven Barth:
> Am 19.12.2012 16:42, schrieb Thomas Schatzl:
>> On Wed, 2012-12-19 at 16:20 +0100, Sven Barth wrote:
>>> Am 18.12.2012 17:47, schrieb Thomas Schatzl:
>>>> Looking through compiler/systems/t_android.pas, you may want to try
>>>> commmenting line 343, the one that adds info.Dynamiclinker to the
>>>> input files. Looks wrong. (system/bin/linker is passed to ld later as
>>>> --dynamic-linker option later anyway).
>>> Ok... by removing the addition of the dynamic linker I can successfully
>>> compile and link the DLL, but when starting it I get an illegal
>>> instruction error... I have not yet tested whether this can be
>>> reproduced with an empty library as well.
>>> === logcat begin ===
>>> === logcat end ===
>>> Edit: Linking with debug information I could resolve the address to
>>> InterlockedExchange. Hmm... It seems that the SDK's QEMU does not
>>> emulate a ARMv6 device?
>> - yes. See http://developer.android.com/tools/devices/emulator.html.
>> Btw, there is not much point to compiling for armv6 for Android. The two
>> official ABIs are either armv5te + softfloat or armv7a + vfpv3_d16
>> (maybe v2).
> Then I'll need to recompile for ARMv5...
I have now managed to compile a simple library (a conversion of the
hello-jni example) and execute it. I had made a mistake though which
could also be the solution to my LCL problem: I had forgotten to pass
-CpARMv5 as the compiler defaults to some other version of ARM. I'll
need to recheck this for the LCL example.
Would something speak against making ARMv5 the default CPU type for
Android? AFAIK that is the minium that Android supports...
More information about the fpc-devel