Re: Compiling to RiscV32

2023-07-12 Thread Kagamin via Digitalmars-d-learn
Maybe the problem is with va_list, try to compile with -mtriple=riscv64-unknown-linux -mcpu=generic-rv64

Re: Compiling to RiscV32

2023-07-11 Thread Kagamin via Digitalmars-d-learn
Probably bug in druntime, v-functions shouldn't have `pragma(printf)`, because they don't have arguments to check.

Re: Compiling to RiscV32

2023-07-11 Thread HuskyNator via Digitalmars-d-learn
On Monday, 10 July 2023 at 14:09:47 UTC, Kagamin wrote: You try to use C declarations, but they are specific to each C library, and different C libraries have different declarations, so headers can't decide which C library declarations to use. Try -mtriple=riscv32-unknown-linux It seems to be

Re: Compiling to RiscV32

2023-07-10 Thread Kagamin via Digitalmars-d-learn
Worked for me on ldc 1.20 https://forum.dlang.org/post/vuxuftogvszztdrrt...@forum.dlang.org

Re: Compiling to RiscV32

2023-07-10 Thread Kagamin via Digitalmars-d-learn
You try to use C declarations, but they are specific to each C library, and different C libraries have different declarations, so headers can't decide which C library declarations to use. Try -mtriple=riscv32-unknown-linux

Re: Compiling to RiscV32

2023-07-06 Thread Dukc via Digitalmars-d-learn
On Wednesday, 5 July 2023 at 17:00:53 UTC, HuskyNator wrote: Using a simple single '.d' file with no imports: `Error: cannot find program 'cc'` I haven't tried to compile to RiscV32, nor do know how it works. But this reads like LDC is not finding the C compiler it's trying to use. LDC uses

Compiling to RiscV32

2023-07-05 Thread HuskyNator via Digitalmars-d-learn
Recently found out LDC supports cross-compiling to riscv, but while trying it out I can't seem to make it work. I am very likely missing something simple, as I haven't done something like this before. I've already been told it's likely something with linking, though I'm not sure how to set this