summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/qemu/qemu/0008-tests-meson.build-use-relative-path-to-refer-to-file.patch
blob: a84364ccc1860cd0560955f12e411ce3f9bd27c3 (plain)
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
From 2bf9388b801d4389e2d57e95a7897bfc1c42786e Mon Sep 17 00:00:00 2001
From: Changqing Li <changqing.li@windriver.com>
Date: Thu, 14 Jan 2021 06:33:04 +0000
Subject: [PATCH 08/12] tests/meson.build: use relative path to refer to files

Fix error like:
Fatal error: can't create tests/ptimer-test.p/..._qemu-5.2.0_hw_core_ptimer.c.o: File name too long

when build path is too long, use meson.source_root() will make this
filename too long. Fixed by using relative path to refer to files

Upstream-Status: Submitted [send to qemu-devel]

Signed-off-by: Changqing Li <changqing.li@windriver.com>

---
 tests/unit/meson.build | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Index: qemu-8.0.0/tests/unit/meson.build
===================================================================
--- qemu-8.0.0.orig/tests/unit/meson.build
+++ qemu-8.0.0/tests/unit/meson.build
@@ -46,7 +46,7 @@ tests = {
   'test-keyval': [testqapi],
   'test-logging': [],
   'test-uuid': [],
-  'ptimer-test': ['ptimer-test-stubs.c', meson.project_source_root() / 'hw/core/ptimer.c'],
+  'ptimer-test': ['ptimer-test-stubs.c', '../../hw/core/ptimer.c'],
   'test-qapi-util': [],
   'test-interval-tree': [],
   'test-xs-node': [qom],
@@ -136,7 +136,7 @@ if have_system
     'test-util-sockets': ['socket-helpers.c'],
     'test-base64': [],
     'test-bufferiszero': [],
-    'test-smp-parse': [qom, meson.project_source_root() / 'hw/core/machine-smp.c'],
+    'test-smp-parse': [qom, '../../hw/core/machine-smp.c'],
     'test-vmstate': [migration, io],
     'test-yank': ['socket-helpers.c', qom, io, chardev]
   }