tests: allow running make check without make install
desktop shell and weston keyboard both refer to themselves prefixed by LIBEXECDIR, however this is only valid once installed. make check will currently either fail or run pre-existing versions. This patch adds a way to override that location by setting the env var WESTON_BUILD_DIR - which is then set by the test env script so make check will test the versions in the build directory regardless of whether they're installed or not. Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
This commit is contained in:
committed by
Pekka Paalanen
parent
3d3f48548a
commit
c7210434d4
@@ -567,7 +567,7 @@ shell_configuration(struct desktop_shell *shell)
|
||||
{
|
||||
struct weston_config_section *section;
|
||||
int duration;
|
||||
char *s;
|
||||
char *s, *client;
|
||||
|
||||
section = weston_config_get_section(shell->compositor->config,
|
||||
"screensaver", NULL, NULL);
|
||||
@@ -578,8 +578,11 @@ shell_configuration(struct desktop_shell *shell)
|
||||
|
||||
section = weston_config_get_section(shell->compositor->config,
|
||||
"shell", NULL, NULL);
|
||||
asprintf(&client, "%s/%s", weston_config_get_libexec_dir(),
|
||||
WESTON_SHELL_CLIENT);
|
||||
weston_config_section_get_string(section,
|
||||
"client", &s, LIBEXECDIR "/" WESTON_SHELL_CLIENT);
|
||||
"client", &s, client);
|
||||
free(client);
|
||||
shell->client = s;
|
||||
weston_config_section_get_string(section,
|
||||
"binding-modifier", &s, "super");
|
||||
|
||||
Reference in New Issue
Block a user