Link with $(CC), not the build host ld. diff -Nrup a/Makefile b/Makefile --- a/Makefile 2005-11-09 19:55:17.000000000 +0100 +++ b/Makefile 2026-10-22 17:22:43.200099764 +0200 @@ -22,7 +22,7 @@ all: echo "compiling "$$file"..."; \ $(CC) $(CFLAGS) -o plugins/$$file.o plugins/$$file.c; \ echo "linking "$$file"..."; \ - ld -shared -o plugins/$(PLUGIN_LIB)-$$file.so plugins/$$file.o; \ + $(CC) -shared -nostartfiles -o plugins/$(PLUGIN_LIB)-$$file.so plugins/$$file.o; \ done; \ install: