summaryrefslogtreecommitdiff
path: root/meta-openembedded/meta-oe/recipes-bsp/fwupd/fwupd/0001-meson-Avoid-absolute-buildtime-paths-in-generated-he.patch
blob: 2273bdf1051769210e4fc0659e603c2e3baf0007 (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 b1df1ed3a21b8ef0244102043a8fb88b0ccc3f91 Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Mon, 17 Apr 2023 11:30:21 -0700
Subject: [PATCH] meson: Avoid absolute buildtime paths in generated headers

using meson.project_source_root() means the path emitted to include .h
files is absolute and it makes its way into PN-src as well, which infact
is not going to work if the -src package was used to re-build this in a
different build path. Therefore use relative path which is '.' and
relative to ${S}

Changes
include "<abspath>/plugins/acpi-dmar/fu-acpi-dmar-plugin.h"
to
include "./plugins/acpi-dmar/fu-acpi-dmar-plugin.h"

in generated build/src/fu-plugin-builtin.h

Upstream-Status: Pending

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 src/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/meson.build b/src/meson.build
index b9f6736..bb856ea 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -188,7 +188,7 @@ plugins_hdr = custom_target('fwupd-generate-plugins-header',
   command : [
     join_paths(meson.project_source_root(), 'contrib', 'generate-plugins-header.py'),
     '@OUTPUT@',
-    meson.project_source_root(),
+    '.',
     ','.join(plugin_names),
   ],
 )
-- 
2.40.0