aports/testing/9base/riscv64.patch
2021-07-04 18:50:00 +02:00

13 lines
417 B
Diff

Taken from the posix-riscv64 subdirectory in the community/drawterm source.
diff -uNr 9base-6-orig/lib9/getcallerpc-riscv64.c 9base-6/lib9/getcallerpc-riscv64.c
--- 9base-6-orig/lib9/getcallerpc-riscv64.c 1970-01-01 01:00:00.000000000 +0100
+++ 9base-6/lib9/getcallerpc-riscv64.c 2021-07-04 16:39:04.452113924 +0200
@@ -0,0 +1,7 @@
+#include <lib9.h>
+
+ulong
+getcallerpc(void *x)
+{
+ return ((uintptr*)x)[-1];
+}