at 23.05-pre 59 lines 3.1 kB view raw
1diff --git a/data/installed-tests/meson.build b/data/installed-tests/meson.build 2index b8ec916f..38209b36 100644 3--- a/data/installed-tests/meson.build 4+++ b/data/installed-tests/meson.build 5@@ -83,5 +83,5 @@ configure_file( 6 output : 'fwupd-tests.conf', 7 configuration : con2, 8 install: true, 9- install_dir: join_paths(sysconfdir, 'fwupd', 'remotes.d'), 10+ install_dir: join_paths(get_option('installed_test_prefix'), 'etc', 'fwupd', 'remotes.d'), 11 ) 12diff --git a/meson.build b/meson.build 13index b91dd037..d7e20b18 100644 14--- a/meson.build 15+++ b/meson.build 16@@ -188,8 +188,8 @@ else 17 datadir = join_paths(prefix, get_option('datadir')) 18 sysconfdir = join_paths(prefix, get_option('sysconfdir')) 19 localstatedir = join_paths(prefix, get_option('localstatedir')) 20- installed_test_bindir = join_paths(libexecdir, 'installed-tests', meson.project_name()) 21- installed_test_datadir = join_paths(datadir, 'installed-tests', meson.project_name()) 22+ installed_test_bindir = join_paths(get_option('installed_test_prefix'), 'libexec', 'installed-tests', meson.project_name()) 23+ installed_test_datadir = join_paths(get_option('installed_test_prefix'), 'share', 'installed-tests', meson.project_name()) 24 daemon_dir = join_paths(libexecdir, 'fwupd') 25 endif 26 mandir = join_paths(prefix, get_option('mandir')) 27@@ -492,6 +492,7 @@ gnome = import('gnome') 28 i18n = import('i18n') 29 30 conf.set_quoted('FWUPD_PREFIX', prefix) 31+conf.set_quoted('FWUPD_INSTALLED_TEST_PREFIX', get_option('installed_test_prefix')) 32 conf.set_quoted('FWUPD_BINDIR', bindir) 33 conf.set_quoted('FWUPD_LIBDIR', libdir) 34 conf.set_quoted('FWUPD_LIBEXECDIR', libexecdir) 35diff --git a/meson_options.txt b/meson_options.txt 36index d00038db..be1c45b4 100644 37--- a/meson_options.txt 38+++ b/meson_options.txt 39@@ -56,6 +56,7 @@ option('systemd', type : 'feature', description : 'systemd support', deprecated: 40 option('systemd_unit_user', type : 'string', description : 'User account to use for fwupd-refresh.service (empty for DynamicUser)') 41 option('systemd_root_prefix', type: 'string', value: '', description: 'Directory to base systemd’s installation directories on') 42 option('elogind', type : 'feature', description : 'elogind support', deprecated: {'true': 'enabled', 'false': 'disabled'}) 43+option('installed_test_prefix', type: 'string', description: 'Prefix for installed tests') 44 option('tests', type : 'boolean', value : true, description : 'enable tests') 45 option('soup_session_compat', type : 'boolean', value : true, description : 'enable SoupSession runtime compatibility support') 46 option('curl', type : 'feature', description : 'libcurl support', deprecated: {'true': 'enabled', 'false': 'disabled'}) 47diff --git a/plugins/redfish/fu-self-test.c b/plugins/redfish/fu-self-test.c 48index 4d19e560..91cfaa61 100644 49--- a/plugins/redfish/fu-self-test.c 50+++ b/plugins/redfish/fu-self-test.c 51@@ -27,7 +27,7 @@ fu_test_is_installed_test(void) 52 const gchar *builddir = g_getenv("G_TEST_BUILDDIR"); 53 if (builddir == NULL) 54 return FALSE; 55- return g_str_has_prefix(builddir, FWUPD_PREFIX); 56+ return g_str_has_prefix(builddir, FWUPD_INSTALLED_TEST_PREFIX); 57 } 58 59 static void