diff options
Diffstat (limited to 'meta')
-rw-r--r-- | meta/recipes-graphics/igt-gpu-tools/igt-gpu-tools/reproducibility.patch | 38 | ||||
-rw-r--r-- | meta/recipes-graphics/igt-gpu-tools/igt-gpu-tools_git.bb | 5 |
2 files changed, 41 insertions, 2 deletions
diff --git a/meta/recipes-graphics/igt-gpu-tools/igt-gpu-tools/reproducibility.patch b/meta/recipes-graphics/igt-gpu-tools/igt-gpu-tools/reproducibility.patch new file mode 100644 index 0000000000..39e36d8737 --- /dev/null +++ b/meta/recipes-graphics/igt-gpu-tools/igt-gpu-tools/reproducibility.patch | |||
@@ -0,0 +1,38 @@ | |||
1 | meson: Allow source location to be configurable | ||
2 | |||
3 | Hardcoding a build source path into a binary when cross compiling isn't | ||
4 | appropriate and breaks build reproducibility. Allow the srcdir to be | ||
5 | specified by an optional configuration option to meson. | ||
6 | |||
7 | Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org> | ||
8 | Upstream-Status: Submitted [https://lists.freedesktop.org/archives/igt-dev/2021-February/029443.html] | ||
9 | |||
10 | Index: git/lib/meson.build | ||
11 | =================================================================== | ||
12 | --- git.orig/lib/meson.build | ||
13 | +++ git/lib/meson.build | ||
14 | @@ -122,7 +122,11 @@ if chamelium.found() | ||
15 | lib_sources += 'igt_chamelium_stream.c' | ||
16 | endif | ||
17 | |||
18 | -srcdir = join_paths(meson.source_root(), 'tests') | ||
19 | +if get_option('srcdir') != '' | ||
20 | + srcdir = join_paths(get_option('srcdir'), 'tests') | ||
21 | +else | ||
22 | + srcdir = join_paths(meson.source_root(), 'tests') | ||
23 | +endif | ||
24 | |||
25 | lib_version = vcs_tag(input : 'version.h.in', output : 'version.h', | ||
26 | fallback : 'NO-GIT', | ||
27 | Index: git/meson_options.txt | ||
28 | =================================================================== | ||
29 | --- git.orig/meson_options.txt | ||
30 | +++ git/meson_options.txt | ||
31 | @@ -50,3 +50,7 @@ option('use_rpath', | ||
32 | type : 'boolean', | ||
33 | value : false, | ||
34 | description : 'Set runpath on installed executables for libigt.so') | ||
35 | + | ||
36 | +option('srcdir', | ||
37 | + type : 'string', | ||
38 | + description : 'Path to source code to be compiled into binaries (optional)') | ||
diff --git a/meta/recipes-graphics/igt-gpu-tools/igt-gpu-tools_git.bb b/meta/recipes-graphics/igt-gpu-tools/igt-gpu-tools_git.bb index 89480d79d2..f25cbc0603 100644 --- a/meta/recipes-graphics/igt-gpu-tools/igt-gpu-tools_git.bb +++ b/meta/recipes-graphics/igt-gpu-tools/igt-gpu-tools_git.bb | |||
@@ -10,7 +10,8 @@ inherit meson | |||
10 | SRCREV = "d16ad07e7f2a028e14d61f570931c87fa5ce404c" | 10 | SRCREV = "d16ad07e7f2a028e14d61f570931c87fa5ce404c" |
11 | PV = "1.25+git${SRCPV}" | 11 | PV = "1.25+git${SRCPV}" |
12 | 12 | ||
13 | SRC_URI = "git://gitlab.freedesktop.org/drm/igt-gpu-tools.git;protocol=https" | 13 | SRC_URI = "git://gitlab.freedesktop.org/drm/igt-gpu-tools.git;protocol=https \ |
14 | file://reproducibility.patch" | ||
14 | 15 | ||
15 | S = "${WORKDIR}/git" | 16 | S = "${WORKDIR}/git" |
16 | 17 | ||
@@ -22,7 +23,7 @@ PACKAGE_BEFORE_PN = "${PN}-benchmarks ${PN}-tests" | |||
22 | 23 | ||
23 | PACKAGECONFIG[chamelium] = "-Dchamelium=enabled,-Dchamelium=disabled,gsl xmlrpc-c" | 24 | PACKAGECONFIG[chamelium] = "-Dchamelium=enabled,-Dchamelium=disabled,gsl xmlrpc-c" |
24 | 25 | ||
25 | EXTRA_OEMESON = "-Ddocs=disabled -Drunner=enabled" | 26 | EXTRA_OEMESON = "-Ddocs=disabled -Drunner=enabled -Dsrcdir=/usr/src/debug/${PN}/${PV}-${PR}/git/" |
26 | COMPATIBLE_HOST = "(x86_64.*|i.86.*|arm.*|aarch64).*-linux" | 27 | COMPATIBLE_HOST = "(x86_64.*|i.86.*|arm.*|aarch64).*-linux" |
27 | COMPATIBLE_HOST_libc-musl_class-target = "null" | 28 | COMPATIBLE_HOST_libc-musl_class-target = "null" |
28 | SECURITY_LDFLAGS = "${SECURITY_X_LDFLAGS}" | 29 | SECURITY_LDFLAGS = "${SECURITY_X_LDFLAGS}" |