mirror of
https://github.com/git/git.git
synced 2026-01-11 02:32:58 +00:00
meson: only detect ICONV_OMITS_BOM if possible
In our Meson setup it automatically detects whether ICONV_OMITS_BOM should be defined. To check this, a piece of code is compiled and ran. When cross-compiling, it's not possible to run this piece of code. Guard this test with a can_run_host_binaries() check to ensure it can run. Signed-off-by: Toon Claes <toon@iotcl.com> Acked-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
9ce3478410
commit
574ac61076
@@ -1064,7 +1064,7 @@ if iconv.found()
|
||||
}
|
||||
'''
|
||||
|
||||
if compiler.run(iconv_omits_bom_source,
|
||||
if meson.can_run_host_binaries() and compiler.run(iconv_omits_bom_source,
|
||||
dependencies: iconv,
|
||||
name: 'iconv omits BOM',
|
||||
).returncode() != 0
|
||||
|
||||
Reference in New Issue
Block a user