mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-04 00:13:40 +02:00
Make ld executable configurable
Tools like this should be configurable in a cross or native file. In particular, if we are cross-compiling (with an executable wrapper like qemu-arm), the build system ld is not necessarily able to manipulate host system objects. Signed-off-by: Simon McVittie <smcv@collabora.com>
This commit is contained in:
@@ -586,8 +586,9 @@ if not meson.is_cross_build() or meson.has_exe_wrapper()
|
||||
# (https://reviews.llvm.org/D58234). FIXME: This test could be enabled for
|
||||
# LLVM once that support is in a stable release.
|
||||
objcopy = find_program('objcopy', required : false)
|
||||
ld = find_program('ld', required : false)
|
||||
|
||||
if build_machine.system() == 'linux' and cc.get_id() == 'gcc' and objcopy.found()
|
||||
if build_machine.system() == 'linux' and cc.get_id() == 'gcc' and objcopy.found() and ld.found()
|
||||
test_gresource_binary = custom_target('test5.gresource',
|
||||
input : 'test5.gresource.xml',
|
||||
output : 'test5.gresource',
|
||||
@@ -616,7 +617,7 @@ if not meson.is_cross_build() or meson.has_exe_wrapper()
|
||||
test_resources_binary = custom_target('test_resources.o',
|
||||
input : test_gresource_binary,
|
||||
output : 'test_resources.o',
|
||||
command : ['ld',
|
||||
command : [ld,
|
||||
'-r',
|
||||
'-b','binary',
|
||||
'@INPUT@',
|
||||
|
Reference in New Issue
Block a user