From: Fergus Henderson <fjh@cs.mu.oz.au>
To: egcs@cygnus.com
Subject: Re: 2 (small?) problems
Date: Mon, 18 Aug 1997 18:22:22 -0000 [thread overview]
Message-ID: <199708181749.DAA24281@murlibobo.cs.mu.OZ.AU> (raw)
In-Reply-To: 199708180820.KAA19291@radagast.iuk.tu-harburg.de
Thomas Hiller, you wrote:
> 2) Shared libg++ problem.
> I have a problem (also with the normal gcc), when I install the compiler
> in a non-standard place (e.g. /work/egcs). The shared libg++ is not
> found. I had to set the LD_LIBRARY_PATH to include $prefix/lib. Is there
> a portable way to set the shared library path from the compiler ? The
> compiler already issues -L$prefix/lib.
As far as I'm aware there's no portable way. Depending on the system,
you use either `-rpath' or `-R', and depending on the system, multiple
directories must either be specified as separate options, or a
colon-separated path must be specified as a single option.
On sparc-sun-solaris, use multiple -R options (e.g. `-Rdir1 -Rdir2').
On i586-linux-pc-gnu, use multiple -rpath options (`-rpath dir1 -rpath dir2').
On alpha-dec-osf and mips-sgi-irix, use a single -rpath option
(e.g. `-rpath dir1:dir2').
Really this nonportability is something that gcc should encapsulate,
just as `gcc -shared' encapsulates (some of) the non-portable aspects
of creating shared libraries on different systems. gcc ought to
recognize `-rpath' on all these systems, and it should handle the
accumulation of multiple `-rpath' options into a single colon-separated
path for the linker on alpha-dec-osf and mips-sgi-irix.
Cheers,
Fergus.
--
Fergus Henderson <fjh@cs.mu.oz.au> | "I have always known that the pursuit
WWW: < http://www.cs.mu.oz.au/~fjh > | of excellence is a lethal habit"
PGP: finger fjh@128.250.37.3 | -- the last words of T. S. Garp.
next reply other threads:[~1997-08-18 18:22 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
1997-08-18 18:22 Fergus Henderson [this message]
-- strict thread matches above, loose matches on Subject: below --
1997-08-25 23:43 Jim Wilson
1997-08-19 2:36 Ian Lance Taylor
1997-08-18 18:22 prototyping Per Bothner
1997-08-18 18:22 ` 2 (small?) problems Jim Meyering
1997-08-18 8:22 Thomas Hiller
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=199708181749.DAA24281@murlibobo.cs.mu.OZ.AU \
--to=fjh@cs.mu.oz.au \
--cc=egcs@cygnus.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).