public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "dave at hiauly1 dot hia dot nrc dot ca" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/26472] Default path for libgcc_s.sl is build directory
Date: Wed, 01 Mar 2006 14:46:00 -0000	[thread overview]
Message-ID: <20060301144644.30894.qmail@sourceware.org> (raw)
In-Reply-To: <bug-26472-276@http.gcc.gnu.org/bugzilla/>



------- Comment #12 from dave at hiauly1 dot hia dot nrc dot ca  2006-03-01 14:46 -------
Subject: Re:  Default path for libgcc_s.sl is build directory

> (In reply to comment #10)
> > 
> > I see it in the manpages for both HP-UX 11.00 and 11.11.  I have
> > the following "ld(1) and linker tools" patches installed: PHSS_30965
> > and PHSS_30968.  I see in the text for PHSS_30049:
> 
> >           Provided a linker option +nodefaultrpath for
> >           not recording build-time paths in the resultant
> >           executables and shared libraries
> 
> So how can we find out cheaply whether it's supported?  Even if it is ignored
> when not supported: we could also set hardcode_minus_L=no if supported to get
> the chance to save some relinking.

The option seems to be ignored by ld when not supported (tested on
HP-UX 10.20 and HP-UX 11.11).

507 (hiauly1)dave> cat main.c
int main() {}
508 (hiauly1)dave> gcc -o main -Wl,+nodefaultrpath main.c

This is the not supported case (HP-UX 10.20):
509 (hiauly1)dave> chatr main|grep libc
             dynamic   /usr/lib/libc.1

This is the supported case (HP-UX 11.11):
-bash-2.05b$ chatr main|grep libc
             dynamic   libc.2

So, a small shell script should be able to detect the difference.
For example, 

514 (hiauly1)dave> chatr main|grep 'dynamic[ \t]*libc'
515 (hiauly1)dave> echo $?
1

-bash-2.05b$ chatr main|grep 'dynamic[ \t]*libc'
             dynamic   libc.2
-bash-2.05b$ echo $?
0

The above compilation also works using 'cc' instead of 'gcc'.

Dave


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26472


  parent reply	other threads:[~2006-03-01 14:46 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-02-26  1:39 [Bug target/26472] New: " danglin at gcc dot gnu dot org
2006-02-26  2:50 ` [Bug target/26472] " pinskia at gcc dot gnu dot org
2006-02-26  2:58 ` pinskia at gcc dot gnu dot org
2006-02-26  2:58 ` dave at hiauly1 dot hia dot nrc dot ca
2006-02-26  9:27 ` Ralf dot Wildenhues at gmx dot de
2006-02-26 16:17 ` dave at hiauly1 dot hia dot nrc dot ca
2006-02-26 17:22 ` Ralf dot Wildenhues at gmx dot de
2006-02-26 21:19 ` dave at hiauly1 dot hia dot nrc dot ca
2006-02-28  9:23 ` Ralf dot Wildenhues at gmx dot de
2006-02-28 14:38 ` dave at hiauly1 dot hia dot nrc dot ca
2006-03-01  7:24 ` Ralf dot Wildenhues at gmx dot de
2006-03-01 14:46 ` dave at hiauly1 dot hia dot nrc dot ca [this message]
2006-03-01 15:48 ` dave at hiauly1 dot hia dot nrc dot ca
2006-03-01 16:06 ` dave at hiauly1 dot hia dot nrc dot ca
2006-03-10  1:25 ` dave at hiauly1 dot hia dot nrc dot ca
     [not found] <bug-26472-4@http.gcc.gnu.org/bugzilla/>
2012-10-03 22:19 ` anilkris at hotmail dot com
2012-10-03 22:40 ` dave.anglin at bell dot net
2014-08-11 23:26 ` wzis at hotmail dot com
2014-08-12  1:13 ` dave.anglin at bell dot net

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=20060301144644.30894.qmail@sourceware.org \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).