I am in the process of creating a meson build system for an open source project that currently uses autoconf. One of the target executables has additional configuration if dtrace is found in the host operating system. The snippet of relevant code from the makefile.am is:
if WITH_DTRACESo if dtrace is found libtool is used on some of the already compiled object files (DTRACE_OBJ) to create the afp_dtrace.o object using a dtrace command. This object then becomes an additional linker item for the executable :
afpd_LDADD += afp_dtrace.o @DTRACE_LIBS@Can anyone who is familiar with meson point me in the right direction for the syntax required to achieve the same result?
I have tried using the extract_objects() function within a custom_target to no avail so far:
afpd = executable(I'm not familiar with dtrace, but can you make dtrace output a .a file instead of a .o file? I've attached a working example that substitutes dtrace with cp.
I also found this unit test:
test cases/common/216 link custom/meson.build
Does that solve your issue?
--
You received this message because you are subscribed to the Google Groups "The Meson Build System" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mesonbuild+...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/mesonbuild/e79b6cbf-9b1f-407b-ad3b-367a430f199fn%40googlegroups.com.