From: Petri Latvala <petri.latvala@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: Petri Latvala <petri.latvala@intel.com>
Subject: [igt-dev] [PATCH CI] tests/tools_test: Print everything when searching for tools
Date: Tue, 15 Jan 2019 12:45:21 +0200 [thread overview]
Message-ID: <20190115104521.9793-1-petri.latvala@intel.com> (raw)
---
tests/tools_test.c | 12 +++++++++---
1 file changed, 9 insertions(+), 3 deletions(-)
diff --git a/tests/tools_test.c b/tests/tools_test.c
index 88a6ae96..c3f57449 100644
--- a/tests/tools_test.c
+++ b/tests/tools_test.c
@@ -65,12 +65,18 @@ static bool chdir_to_tools_dir(void)
char path[PATH_MAX];
/* Try TOOLS relative to cwd */
- if (chdir(TOOLS) == 0)
+ if (chdir(TOOLS) == 0) {
+ igt_info("Directory found at original cwd + TOOLS\n");
return true;
+ }
/* Try TOOLS and install dir relative to test binary */
- if (readlink("/proc/self/exe", path, sizeof(path)) > 0)
- chdir(dirname(path));
+ if (readlink("/proc/self/exe", path, sizeof(path)) > 0) {
+ igt_info("Readlink /proc/self/exe = %s\n", path);
+ if (chdir(dirname(path)) == 0)
+ igt_info("chdir to executable dir succeeded\n");
+ } else
+ igt_info("Readlink /proc/self/exe failed\n");
return chdir(TOOLS) == 0 || chdir("../../bin") == 0;
}
--
2.19.1
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
next reply other threads:[~2019-01-15 10:45 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-15 10:45 Petri Latvala [this message]
2019-01-15 11:23 ` [igt-dev] ✓ Fi.CI.BAT: success for tests/tools_test: Print everything when searching for tools Patchwork
2019-01-15 14:46 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190115104521.9793-1-petri.latvala@intel.com \
--to=petri.latvala@intel.com \
--cc=igt-dev@lists.freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox