Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Kamil Rytarowski <n54@gmx.com>
To: gdb-patches@sourceware.org
Subject: [PATCH] Tune default DEBUGDIR for NetBSD
Date: Wed,  8 Apr 2020 19:15:43 +0200	[thread overview]
Message-ID: <20200408171543.6061-1-n54@gmx.com> (raw)

NetBSD uses a custom debug file directory /usr/libdata/debug
for the basesystem and does not use separate debug files in
pkgsrc (3rd party package collections).

gdb/ChangeLog:

        * configure.ac: Handle NetBSD specific DEBUGDIR.
        * configure: Regenerate.
---
 gdb/ChangeLog    |  5 +++++
 gdb/configure    | 11 ++++++++++-
 gdb/configure.ac | 11 ++++++++++-
 3 files changed, 25 insertions(+), 2 deletions(-)

diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 7ea85799211..af6844b6ace 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
+2020-04-08  Kamil Rytarowski  <n54@gmx.com>
+
+	* configure.ac: Handle NetBSD specific DEBUGDIR.
+	* configure: Regenerate.
+
 2020-04-08  Simon Marchi  <simon.marchi@polymtl.ca>

 	* dwarf2/read.c (read_gdb_index_from_buffer): Remove objfile
diff --git a/gdb/configure b/gdb/configure
index afafc2c8d18..636a3f69f00 100755
--- a/gdb/configure
+++ b/gdb/configure
@@ -6416,6 +6416,15 @@ if test x"$gdb_cv_have_makeinfo_click" = xyes; then
 fi


+case "${host}" in
+  *-*-netbsd*)
+    DEFAULTDEBUGDIR=/usr/libdata/debug
+    ;;
+  *)
+    DEFAULTDEBUGDIR=${libdir}/debug
+    ;;
+esac
+


 # Check whether --with-separate-debug-dir was given.
@@ -6423,7 +6432,7 @@ if test "${with_separate_debug_dir+set}" = set; then :
   withval=$with_separate_debug_dir;
     DEBUGDIR=$withval
 else
-  DEBUGDIR=${libdir}/debug
+  DEBUGDIR=${DEFAULTDEBUGDIR}
 fi


diff --git a/gdb/configure.ac b/gdb/configure.ac
index b9dbe13232a..3cef95fbcb8 100644
--- a/gdb/configure.ac
+++ b/gdb/configure.ac
@@ -93,9 +93,18 @@ if test x"$gdb_cv_have_makeinfo_click" = xyes; then
 fi
 AC_SUBST(MAKEINFO_EXTRA_FLAGS)

+case "${host}" in
+  *-*-netbsd*)
+    DEFAULTDEBUGDIR=/usr/libdata/debug
+    ;;
+  *)
+    DEFAULTDEBUGDIR=${libdir}/debug
+    ;;
+esac
+
 GDB_AC_WITH_DIR(DEBUGDIR, separate-debug-dir,
     [look for global separate debug info in this path @<:@LIBDIR/debug@:>@],
-    [${libdir}/debug])
+    [${DEFAULTDEBUGDIR}])

 # We can't pass paths as command line arguments.
 # Mingw32 tries to be clever and will convert the paths for us.
--
2.25.0



             reply	other threads:[~2020-04-08 17:16 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-08 17:15 Kamil Rytarowski [this message]
2020-04-08 17:18 ` Christian Biesinger
2020-04-08 17:20   ` Kamil Rytarowski
2020-04-08 17:28     ` Christian Biesinger
2020-04-24 14:38       ` Simon Marchi
2020-04-24 15:30         ` Kamil Rytarowski
2020-04-17 14:54 ` Kamil Rytarowski
2020-04-20 10:32   ` Kamil Rytarowski

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=20200408171543.6061-1-n54@gmx.com \
    --to=n54@gmx.com \
    --cc=gdb-patches@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: 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