public inbox for gdb-cvs@sourceware.org help / color / mirror / Atom feed
From: Vladimir Mezentsev <vmezents@sourceware.org> To: bfd-cvs@sourceware.org, gdb-cvs@sourceware.org Subject: [binutils-gdb] gprofng: run tests without installation Date: Tue, 11 Oct 2022 07:18:08 +0000 (GMT) [thread overview] Message-ID: <20221011071808.511433858C2D@sourceware.org> (raw) https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=a665c4d5c6e1d23d31ac434949b9243025496aef commit a665c4d5c6e1d23d31ac434949b9243025496aef Author: Vladimir Mezentsev <vladimir.mezentsev@oracle.com> Date: Mon Oct 10 12:57:19 2022 -0700 gprofng: run tests without installation gprofng/ChangeLog 2022-10-10 Vladimir Mezentsev <vladimir.mezentsev@oracle.com> PR gprofng/29107 * testsuite/config/default.exp: Set up environment to run gprofng tests without installation. * testsuite/lib/Makefile.skel: Likewise. * testsuite/lib/display-lib.exp: Likewise. Diff: --- gprofng/testsuite/config/default.exp | 6 ++++-- gprofng/testsuite/lib/Makefile.skel | 3 +-- gprofng/testsuite/lib/display-lib.exp | 2 +- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/gprofng/testsuite/config/default.exp b/gprofng/testsuite/config/default.exp index 6fde0a1223f..b9513aefc0f 100644 --- a/gprofng/testsuite/config/default.exp +++ b/gprofng/testsuite/config/default.exp @@ -32,7 +32,9 @@ if {![info exists CFLAGS]} { set CFLAGS "-g -O2" } -# Make a temporary install dir to run gprofng from, and point at it -remote_exec host "sh -c \"rm -rf tmpdir; mkdir -p tmpdir; $MAKE -C .. install-gprofng program_transform_name= DESTDIR=`pwd`/tmpdir/root\"" +# Create directories where gprofng can find libraries and binaries: +remote_exec host "sh -c \"rm -rf tmpdir; mkdir -p tmpdir\"" +remote_exec host "sh -c \"mkdir -p lib; rm -f lib/gprofng; ln -s ../libcollector/.libs lib/gprofng\"" +remote_exec host "sh -c \"rm -f bin; ln -s src bin\"" load_lib display-lib.exp diff --git a/gprofng/testsuite/lib/Makefile.skel b/gprofng/testsuite/lib/Makefile.skel index 157f6f60c84..035d320f35f 100644 --- a/gprofng/testsuite/lib/Makefile.skel +++ b/gprofng/testsuite/lib/Makefile.skel @@ -39,8 +39,7 @@ DISPLAY = $(GPROFNG) display text EXPERIMENT = test.er DISPLAY_LOG = display.log -gprofng_dir := $(shell dirname $$(find ../root -name libgprofng.so.0 | head -1)) -export LD_LIBRARY_PATH := $(gprofng_dir):$(gprofng_dir)/.. +export LD_LIBRARY_PATH := $(BUILDDIR)/src # Set GPROFNG_SYSCONFDIR to find out gprofng.rc: export GPROFNG_SYSCONFDIR := $(srcdir)/../../../src diff --git a/gprofng/testsuite/lib/display-lib.exp b/gprofng/testsuite/lib/display-lib.exp index 38ecb8d258e..d103f0fe247 100644 --- a/gprofng/testsuite/lib/display-lib.exp +++ b/gprofng/testsuite/lib/display-lib.exp @@ -58,7 +58,7 @@ proc run_display_test { dir cflags gprofflags } { set tdir "tmpdir/$testdir" send_log "create dir: $tdir\n" set output [run_native_host_cmd "mkdir -p $tdir"] - set gprofng [exec find $BUILDDIR/tmpdir -type f -name gprofng -perm -u+x | head -1] + set gprofng $BUILDDIR/src/gprofng set fd [open "$tdir/rules.txt" "w"] switch -regexp -- $testdir {
reply other threads:[~2022-10-11 7:18 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20221011071808.511433858C2D@sourceware.org \ --to=vmezents@sourceware.org \ --cc=bfd-cvs@sourceware.org \ --cc=gdb-cvs@sourceware.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: linkBe 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; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).