Thanks for the fixes and sorry for the breakage.

While others might work on more proper fixes. Does it make sense to
have the attached patch to fix riscv* build?

BTW, ${LINKER_TYPE} == "bfd" seems causing failure in the clean stage,
that's why it didn't be caught in my test and CI, they have
"-DNO_CLEAN"

Li-Wen
Index: usr.sbin/jail/Makefile
===================================================================
--- usr.sbin/jail/Makefile	(revision 354935)
+++ usr.sbin/jail/Makefile	(working copy)
@@ -15,6 +15,13 @@
 YFLAGS+=-v
 CFLAGS+=-I. -I${.CURDIR}
 
+# workaround for riscv* with GNU ld (GNU Binutils) 2.33.1:
+#   relocation truncated to fit: R_RISCV_GPREL_I against `.LANCHOR2'
+# https://bugs.freebsd.org/242109
+.if ${MACHINE_CPUARCH:Mriscv*}
+CFLAGS+=-Wl,--no-relax
+.endif
+
 .if ${MK_INET6_SUPPORT} != "no"
 CFLAGS+= -DINET6
 .endif
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "[email protected]"

Reply via email to