--- a/test/module.defs
+++ a/test/module.defs
@@ -30,6 +30,10 @@ 
 endif
 endif
 
+ifeq (1,$(FEATURE.x265))
+    TEST.GCC.l += x265
+endif
+
 ifeq (1,$(FEATURE.flatpak))
     TEST.GCC.l += glib-2.0
 endif
