How do we add a linker command line option into meson build system e.g:
If a wanted CL:
-Wl,-rpath=/usr/local/lib
so it must be found correctly every time the release program is executed, how to set the meson configuration ?
.
How do we add a linker command line option into meson build system e.g:
If a wanted CL:
-Wl,-rpath=/usr/local/lib
so it must be found correctly every time the release program is executed, how to set the meson configuration ?
.
Either from meson setup or configure (assuming the C linker):
meson setup -Dc_link_args='-Wl,-rpath=...'
OR
meson configure -Dc_link_args='-Wl,-rpath=...'
Or you could set them in the meson build definitions themselves, if that makes more sense (though generally for things like rpath it makes more sense to set them externally).
build_target(
...
link_args : ['-Wl,-rpath=...']
)