I thought this might interest you Rust folk. This is kinda like an LLVM bitcode to JVM bytecode translator. So run rustc
with --emit=llvm-ir
(I think that’s the flag) and then pass the bitcode image to this program, then get JVM bytecode which you can make a JVM bytecode archive (JAR) from it. Could be an interesting? The author says it can JVM code from Clang output, so why not Rustc?
Keep in mind that these are two different beasts, JVM is designed for a safe virtual machine and LLVM is chiefly used to be translated into machine code. However, stupider and more wonderful things have been done with LLVM and JVM, for example, there’s an LLVM to 6502 translator, so you could be making NES games with Rust.
I will test this in a few days, busy implementing my own JVM (hope I can do it) and I don’t have the Rust toolchain installed on my system. But hey maybe someone can make a Cargo plugin from it (is it possible?)
Thanks, later.
Did you even read the rest of my comment?
Anti Commercial-AI license
Yes. That was a part of “1. needed”.
Read about how Dart/Flutter does it.
So because Dart/Flutter do it one way, it should be the only sanctioned way to do it? There’s only one path to Rome and every other path is sacrilege? Nothing good ever came of exploring other options, right?
Anti Commercial-AI license
The problem is, if you knew anything about the subject matter, you would know that even JAVA code ends up being compiled ahead-of-time by ART to ELF binaries on Android.
Even non-devs know this stuff!
Hey now, I am just a yokel from Mazar-Sharif, New York who sells dingbat carcasses for infant consumption, but does Android even use JVM? I was under the consumption it uses Dalvik? Let me consume a dingbat – ok, so who cares what “java” gets compiled to, JIT, AOT even tree-walked, we’re talking about JVM here. Here: https://sourceforge.net/projects/jasmin/ An ancient JVM bytecode assembler.
Maybe I should have written something simpler like “What is the shortest distance between two points, and how does it look like?”
I do not know why I al defending that guy, but the comment he is replying to specifically mentioned Android. So, he is not the one that narrowed the conversation from JVM to Android.
Also, I am sure your dingbat humour is quite hilarious. Unfortunately, it went completely over my head.