[Android-development] Basic problem import org.qtproject.qt5.android

Eskil Abrahamsen Blomfeldt eskil.abrahamsen-blomfeldt at theqtcompany.com
Fri Jan 9 12:30:58 CET 2015


On 01/09/2015 12:10 PM, Harri Pasanen wrote:
> On 09/01/2015 10:47, Eskil Abrahamsen Blomfeldt wrote:
>> On 01/09/2015 10:40 AM, Harri Pasanen wrote:
>>> On 09/01/2015 10:20, Eskil Abrahamsen Blomfeldt wrote:
>>>> The QtNative class should be inside lib/QtAndroid-bundled.jar.
>>>>
>>>> -
>>> Ok, I copied it to android/libs next to my other jars
>>> in my project source and from there the build picked it up.
>>>
>>> Somehow I thought that QtAndroid-bundled.jar would be somehow special
>>> and be it would have been picked up by QC automatically.
>> The androiddeployqt tool should copy it into the build directory for
>> you, so if that's not happening, then there's a bug somewhere...
>>
>>
> Yes, this is not happening so I suppose a bug.
> It is only apparent when one tries to compile something using QtNative
> class, it is missing at compile time.
>
> But runtime it must be there, otherwise nothing would work.

Right, it's not part of the classpath, but resolved dynamically by the 
binding layer, because at that point we don't know if it will be bundled 
with the application or distributed through Ministro.

The classes in the jar file are not really part of the public API. The 
best way to access those classes would probably be to resolve them 
dynamically using the reflection API in Java instead, I think.

-- Eskil




More information about the Android-development mailing list