-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Expand file tree
/
Copy pathfix-cross-gir.patch
More file actions
41 lines (39 loc) · 1.4 KB
/
fix-cross-gir.patch
File metadata and controls
41 lines (39 loc) · 1.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
Reason: Fix crossbuilding GIR
Upstream: No, not upstreamable since this is very specific to the Void setup
Index: b/src/libnm-client-impl/meson.build
===================================================================
--- a/src/libnm-client-impl/meson.build
+++ b/src/libnm-client-impl/meson.build
@@ -179,6 +179,16 @@ if enable_introspection
endif
ld_library_path = meson.current_build_dir() + ld_library_path
+ if meson.is_cross_build()
+ qemu_python3_cmd = [
+ '/usr/bin/qemu-@XBPS_TARGET_QEMU_MACHINE@-static',
+ '-L', '@XBPS_CROSS_BASE@',
+ '@XBPS_CROSS_BASE@/usr/bin/python3'
+ ]
+ else
+ qemu_python3_cmd = python_path
+ endif
+
gen_infos_cmd = files(source_root / 'tools' / 'generate-docs-nm-property-infos.py')
gen_gir_cmd = files(source_root / 'tools' / 'generate-docs-nm-settings-docs-gir.py')
@@ -192,7 +202,7 @@ if enable_introspection
input: [gen_infos_cmd, libnm_gir[0]] + libnm_core_settings_sources,
output: 'nm-property-infos-' + name + '.xml',
command: [
- python_path,
+ qemu_python3_cmd,
gen_infos_cmd,
name,
'@OUTPUT@',
@@ -208,7 +218,7 @@ if enable_introspection
'env',
'GI_TYPELIB_PATH=' + gi_typelib_path,
'LD_LIBRARY_PATH=' + ld_library_path,
- python_path,
+ qemu_python3_cmd,
gen_gir_cmd,
'--gir', libnm_gir[0],
'--output', '@OUTPUT@',