[gtk/wip/lantw/build-Don't-use-ld-and-objcopy-when-cross-compiling] build: Don't use ld and objcopy when cross-compiling
- From: Ting-Wei Lan <lantw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/lantw/build-Don't-use-ld-and-objcopy-when-cross-compiling] build: Don't use ld and objcopy when cross-compiling
- Date: Sun, 13 Mar 2022 07:20:48 +0000 (UTC)
commit e1e88ce66589e1d2e235a7205d4611218310927d
Author: Ting-Wei Lan <lantw src gnome org>
Date: Sun Mar 13 15:14:12 2022 +0800
build: Don't use ld and objcopy when cross-compiling
These commands don't work when compiling Windows binaries on Linux.
demos/gtk-demo/meson.build | 2 +-
demos/widget-factory/meson.build | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/demos/gtk-demo/meson.build b/demos/gtk-demo/meson.build
index f594cd59b2..fa63dbbb9b 100644
--- a/demos/gtk-demo/meson.build
+++ b/demos/gtk-demo/meson.build
@@ -160,7 +160,7 @@ endif
ld = find_program('ld', required : false)
-if build_machine.system() == 'linux' and objcopy.found() and objcopy_supports_add_symbol and ld.found()
+if not meson.is_cross_build() and build_machine.system() == 'linux' and objcopy.found() and
objcopy_supports_add_symbol and ld.found()
glib_compile_resources = find_program('glib-compile-resources')
# Create the resource blob
diff --git a/demos/widget-factory/meson.build b/demos/widget-factory/meson.build
index 9a083eb1ac..2cfc9732dc 100644
--- a/demos/widget-factory/meson.build
+++ b/demos/widget-factory/meson.build
@@ -8,7 +8,7 @@ endif
ld = find_program('ld', required : false)
-if build_machine.system() == 'linux' and objcopy.found() and objcopy_supports_add_symbol and ld.found()
+if not meson.is_cross_build() and build_machine.system() == 'linux' and objcopy.found() and
objcopy_supports_add_symbol and ld.found()
glib_compile_resources = find_program('glib-compile-resources')
# Create the resource blob
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]