Even if you were able to dex Jython.jar, Jython would still generate Java
bytecode at runtime. AFAIK there is no way to dex this at runtime on
Android. Even if it was possible or if Jython could generate dexed bytecode
directly, AFAIK Android prohibits apps to load such new code at runtime. I
used to think that it should be possible at least to create all bytecode
required for a certain Python porgram or library ahead of time and dex it,
but was told that Jython in its current form inherently needs to generate,
load and run bytecode at runtime. I.e. some bits for gluing code cannot be
created ahead of time. Best feasible workaround would be to use CPython
bytecode on Android. Jython can actually read and interpret CPython
bytecode (.pyc files). However, it cannot create it: That part was never
ported from CPython and it is significant work (about 10k lines of C-code
need to be ported to Java for this). We used to have this particular task
open as a GSoC project proposal:
https://github.com/jythontools/gsoc2015#python-bytecode-compiler However,
nobody ever applied for this project.
-Stefan
Am Fr., 30. Aug. 2019 um 16:06 Uhr schrieb Jeff Mitchell <
jef...@za...>:
> This begs the question.. if you know the command line, do it yourself?
> Also, jython 2.5 is pretty old; why not 2.7.x?
>
> (I don't know what dex is, haven't done Android dev)
>
> On Thu, Aug 29, 2019 at 9:49 PM HemanthJabalpuri <
> hem...@gm...> wrote:
>
>> Can someone please dex the jython-standalone-2.5.3.jar using dx tool.from
>> android sdk.
>> dx --dex --min-sdk-version=1 --output="jython-standalone-2.5.3-dexed.jar"
>> jython-standalone-2.5.3.jar
>>
>> Thanks
>> _______________________________________________
>> Jython-users mailing list
>> Jyt...@li...
>> https://lists.sourceforge.net/lists/listinfo/jython-users
>>
> _______________________________________________
> Jython-users mailing list
> Jyt...@li...
> https://lists.sourceforge.net/lists/listinfo/jython-users
>
|