www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.ldc - I give up! Android and ldc

reply Indigo <Indigo Go.go> writes:
Seems too much of a mess. Why can't I just download the arm libs 
or have a batch file to compile them from git and then simply 
invoke ldc easily? Maybe Visual D needs to add support for 
android?
Nov 19
next sibling parent "David Nadlinger" <code klickverbot.at> writes:
On 19 Nov 2017, at 23:10, Indigo via digitalmars-d-ldc wrote:
 Seems too much of a mess. Why can't I just download the arm libs or 
 have a batch file to compile them from git and then simply invoke ldc 
 easily?
How do you set up your C/C++ ARM cross-toolchain? Did you check out the ldc-build-runtime tool? — David
Nov 19
prev sibling parent reply Joakim <dlang joakim.fea.st> writes:
On Sunday, 19 November 2017 at 23:10:23 UTC, Indigo wrote:
 Seems too much of a mess. Why can't I just download the arm 
 libs or have a batch file to compile them from git and then 
 simply invoke ldc easily? Maybe Visual D needs to add support 
 for android?
How far did you get? Rather than have a batch file, we have a small D binary tool, ldc-build-runtime, which invokes ldc for you: https://wiki.dlang.org/Building_LDC_runtime_libraries https://wiki.dlang.org/Build_D_for_Android As for downloading prebuilt ARM libs, we chose to try to make it easy for you to generate them yourself, rather than putting up a bunch of libraries for every platform we support, from Android/ARM to linux/PowerPC. Unfortunately, that means reusing our existing CMake/Make/Ninja build process, which I'm not too happy with. I'd like to move to dub, so that no external build tools are required, but that means making dub work for cross-compilation and writing dub files for druntime and phobos. Maybe not too much work, but I haven't looked into it. It would be nice if Visual D supported Android cross-compilation, but I don't know if its developer has any plans to do so.
Nov 19
parent reply Gheorghe Gabriel <knoppy273 live.com> writes:
On Monday, 20 November 2017 at 03:13:29 UTC, Joakim wrote:
 On Sunday, 19 November 2017 at 23:10:23 UTC, Indigo wrote:
 [...]
How far did you get? Rather than have a batch file, we have a small D binary tool, ldc-build-runtime, which invokes ldc for you: [...]
If I had had the necessary knowledge, I would have surely contributed to LLVM D Compiler.
Nov 22
parent Joakim <dlang joakim.fea.st> writes:
On Wednesday, 22 November 2017 at 08:44:24 UTC, Gheorghe Gabriel 
wrote:
 On Monday, 20 November 2017 at 03:13:29 UTC, Joakim wrote:
 On Sunday, 19 November 2017 at 23:10:23 UTC, Indigo wrote:
 [...]
How far did you get? Rather than have a batch file, we have a small D binary tool, ldc-build-runtime, which invokes ldc for you: [...]
If I had had the necessary knowledge, I would have surely contributed to LLVM D Compiler.
I'm not sure what you mean, you also find it too hard to follow the wiki instructions and build for Android? Or simply that you'd like to contribute to ldc development but don't know how? If the latter, how would you like to help make ldc better, mobile support, GPU compute, ie which ldc feature are you interested in furthering? Depending on the complexity of the topic that interests you and your level of knowledge, it may not be that difficult to contribute. There are low-level jobs listed on github, that would be a good starter for someone coming in: https://github.com/ldc-developers/ldc/issues?q=is%3Aissue+is%3Aopen+label%3A"good+first+issue" Also, let me note that before I started working on the Android port of ldc, I had never written a line of code for Android and had never looked at the ARM instruction set. However, I had knowledge of related fundamentals, like taking an in-depth x86 assembly programming class back in college or porting an OSS C++ project like Chromium, so I was able to pick up most of what I needed. Maybe you can do the same.
Nov 22