From: Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
To: gcc-patches@gcc.gnu.org
Cc: Ian Lance Taylor <iant@google.com>
Subject: [libgo] Use /usr/bin/pwd in os_test.TestStartProcess on Solaris (PR go/48502)
Date: Mon, 23 May 2011 11:55:00 -0000 [thread overview]
Message-ID: <yddpqn9wwu4.fsf@manam.CeBiTec.Uni-Bielefeld.DE> (raw)
As described in the PR, the go libgo test fails on Solaris since /bin is
a symlink to /usr/bin. Since there is other OS-specific code in
os_test.go, I'm using the follwing patch to fix this.
With that patch, libgo test results on i386-pc-solaris2.11 are clean.
Rainer
2011-05-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
PR go/48502
* go/os/os_test.go (TestStartProcess): Use /usr/bin/pwd on Solaris.
diff --git a/libgo/go/os/os_test.go b/libgo/go/os/os_test.go
--- a/libgo/go/os/os_test.go
+++ b/libgo/go/os/os_test.go
@@ -440,7 +440,12 @@ func TestStartProcess(t *testing.T) {
args = []string{"/c", "cd"}
} else {
le = "\n"
- cmd = "/bin/pwd"
+ // /bin is a symlink to /usr/bin on Solaris.
+ if syscall.OS == "solaris" {
+ cmd = "/usr/bin/pwd"
+ } else {
+ cmd = "/bin/pwd"
+ }
dir = "/"
args = []string{}
}
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University
next reply other threads:[~2011-05-23 10:11 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-23 11:55 Rainer Orth [this message]
2011-05-25 8:48 ` Ian Lance Taylor
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=yddpqn9wwu4.fsf@manam.CeBiTec.Uni-Bielefeld.DE \
--to=ro@cebitec.uni-bielefeld.de \
--cc=gcc-patches@gcc.gnu.org \
--cc=iant@google.com \
/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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).