-# -Wl,--no-as-needed is needed for recent gold linker who seems to think
-# it knows better and considers libraries with constructors having
-# side-effects as dead code.
-COMMON_TEST_LDADD = $(LIBTAP) $(builddir)/libtestcommon.la \
- $(top_builddir)/lib/libbabeltrace2.la
+test_trace_ir_ref_LDADD = $(COMMON_TEST_LDADD) \
+ $(top_builddir)/src/lib/libbabeltrace2.la \
+ $(top_builddir)/src/ctf-writer/libbabeltrace2-ctf-writer.la