Re: Porting libreoffice to riscv64 arch
Am 22.05.22 um 16:06 schrieb Bo YU:
It seems it was passed for riscv64 bridge "build check". But it stops
at pdfium here:
In file included from
error: #error Please add support for your architecture in
127 | #error Please add support for your architecture in
Which obviously can't work since you added it inside a #elif
defined(__m68k__) and so your definitions will never be done on risc64
and thus falls into the #else?
But I have added riscv64 arch here:
@@ -121,6 +121,8 @@
#define ARCH_CPU_M68K 1
#define ARCH_CPU_32_BITS 1
+#define ARCH_CPU_RISCV64 1
+#define ARCH_CPU_64_BITS 1
#error Please add support for your architecture in build/build_config.h
>ou need to add a new #elif.
https://wiki.debian.org/ArchitectureSpecificsMemo says _riscv &&
__riscv_xlen==64 is the symbols to check, so the trivial(!) patch would
actually be addding
#elif defined_riscv && __riscv_xlen==64
#define ARCH_CPU_RISCV64 1
#define ARCH_CPU_64_BITS 1
No idea whether something more is needed inside pdfium actually.
(Note that this file is gone in 7.4:
so patching this in 7.4 will be more interesting, I assume.
> It seems the build_config.h can not detect the cpu info.
It doesn't detect anything, it just defines variables, which you in fact
don't (see above).