Get DUB to skip linker and output object files?

Markus Pursche pursche01 at gmail.com
Wed Mar 18 11:48:53 UTC 2020


Hi, we are experimenting with cross-compiling from Windows to 
PS4, we have figured out how to compile (using LDC with -betterC) 
individual .d files into object files (.o), which I can then link 
using the PS4 SDK into a .elf and it all runs.

I would very much like to integrate the first part of that 
toolchain with Dub since it would make testing different -betterC 
enabled libraries for ABI compatibility easier.

Here is my dub.json

https://pastebin.com/s7XexRBD

However, this is my output when running dub build -v

https://pastebin.com/TyLi5sid

My first observation is that it is still trying to link 
everything, is there any way I can disable this?

The second thing is that it assumes .obj and .exe files instead 
of .o and .elf, should I perhaps change the target platform 
according to DUB as well? Would that pass another triple to LDC?


More information about the Digitalmars-d mailing list