From: cgd@broadcom.com
To: insight@sources.redhat.com, gdb-patches@sources.redhat.com
Subject: [PATCH RFA] for NetBSD host, use RPATH to add X lib dir.
Date: Fri, 08 Feb 2002 16:16:00 -0000 [thread overview]
Message-ID: <yov57kpncxwn.fsf@broadcom.com> (raw)
On NetBSD ELF systems, the X libraries are normally found via RPATH.
The following patch adds an -rpath to the link line, specifing the X11
lib dir, so that gdb/insight can find the X11 libs.
(Yes, that's right, by default they're not listed in any configuration
file and they are not in the default shared library search path. The
X11 client programs normally shipped with the system all have RPATHs
in them, and the imake templates in the NetBSD version of X include
support for adding the RPATHs so that programs built with imake work
correctly out of the box.)
On NetBSD a.out systems this isn't needed, but -rpath is ignored by
the linker entirely, so there's no need to distinguish between a.out
and ELF.
Approval, anyone? 8-)
cgd
===================================================================
[src/tk/ChangeLog]
2002-02-08 Chris Demetriou <cgd@broadcom.com>
* configure.in: When building for NetBSD host systems, tell
linker to provide RPATH for the X11 library directory.
* configure: Regenerate.
Index: configure.in
===================================================================
*** configure.in 2000/10/30 22:57:26 1.1.1.1
--- configure.in 2001/03/21 19:48:45 1.3
***************
*** 318,323 ****
--- 318,336 ----
fi
suppress_enable_shared=yes
;;
+
+ #
+ # GDB should be linked dynamically on NetBSD, but needs the linker
+ # to set an RPATH in the binaries for the X11 library directory. It's
+ # assumed that if a shared libtk is being built, it will be RPATH'd
+ # in via a directive in the tcl library configuration information.
+ #
+ *-*-netbsd*)
+ if test "x$x_libraries" != "x"; then
+ XLIBSW="$XLIBSW -Wl,-rpath,$x_libraries"
+ fi
+ ;;
+
#
# default is to link dynamically
#
next reply other threads:[~2002-02-09 0:16 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-02-08 16:16 cgd [this message]
2002-02-08 16:20 ` cgd
2002-02-09 8:53 ` Andrew Cagney
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=yov57kpncxwn.fsf@broadcom.com \
--to=cgd@broadcom.com \
--cc=gdb-patches@sources.redhat.com \
--cc=insight@sources.redhat.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