summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rpm-sequoia/files/0001-Use-optional-env-vars-to-force-runtime-paths-in-test.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/rpm-sequoia/files/0001-Use-optional-env-vars-to-force-runtime-paths-in-test.patch')
-rw-r--r--meta/recipes-devtools/rpm-sequoia/files/0001-Use-optional-env-vars-to-force-runtime-paths-in-test.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/meta/recipes-devtools/rpm-sequoia/files/0001-Use-optional-env-vars-to-force-runtime-paths-in-test.patch b/meta/recipes-devtools/rpm-sequoia/files/0001-Use-optional-env-vars-to-force-runtime-paths-in-test.patch
new file mode 100644
index 0000000000..d0179fc53c
--- /dev/null
+++ b/meta/recipes-devtools/rpm-sequoia/files/0001-Use-optional-env-vars-to-force-runtime-paths-in-test.patch
@@ -0,0 +1,35 @@
1From 590937523deea4ad2a2ee0e1ae4412a8f59e0170 Mon Sep 17 00:00:00 2001
2From: Ines KCHELFI <ines.kchelfi@smile.fr>
3Date: Thu, 10 Apr 2025 15:14:11 +0200
4Subject: [PATCH] Use optional env vars to force runtime paths in tests
5
6Signed-off-by: Ines KCHELFI <ines.kchelfi@smile.fr>
7Upstream-Status: Submitted [https://github.com/rpm-software-management/rpm-sequoia/pull/86]
8---
9 tests/symbols.rs | 6 ++++--
10 1 file changed, 4 insertions(+), 2 deletions(-)
11
12diff --git a/tests/symbols.rs b/tests/symbols.rs
13index c16dd9b..dc4a42c 100644
14--- a/tests/symbols.rs
15+++ b/tests/symbols.rs
16@@ -14,7 +14,8 @@ fn symbols() -> anyhow::Result<()> {
17 // OUT_DIR gives us
18 // `/tmp/rpm-sequoia/debug/build/rpm-sequoia-HASH/out`.
19
20- let out_dir = PathBuf::from(env!("OUT_DIR"));
21+ let out_dir = PathBuf::from(option_env!("FORCE_RUNTIME_PATH_LIB")
22+ .unwrap_or(env!("OUT_DIR")));
23 let mut build_dir = out_dir;
24 let lib = loop {
25 let mut lib = build_dir.clone();
26@@ -53,7 +54,8 @@ fn symbols() -> anyhow::Result<()> {
27 }
28
29 let mut expected_symbols_txt_fn
30- = PathBuf::from(env!("CARGO_MANIFEST_DIR"));
31+ = PathBuf::from(option_env!("FORCE_RUNTIME_PATH_SRC")
32+ .unwrap_or(env!("CARGO_MANIFEST_DIR")));
33 expected_symbols_txt_fn.push("src/symbols.txt");
34
35 let mut expected_symbols_txt = Vec::new();