mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
From: Michael Olbrich <m.olbrich@pengutronix.de>
To: ptxdist@pengutronix.de
Cc: Ian Abbott <abbotti@mev.co.uk>
Subject: Re: [ptxdist] [APPLIED] gdb: Add option to configure lzma support
Date: Sun, 12 May 2024 15:16:47 +0200	[thread overview]
Message-ID: <20240512131647.3703936-1-m.olbrich@pengutronix.de> (raw)
In-Reply-To: <20240508101404.272507-1-abbotti@mev.co.uk>

Thanks, applied as 68cd37983cacf188ccb6fd3fdfaeaf776937c6d0.

Michael

[sent from post-receive hook]

On Sun, 12 May 2024 15:16:47 +0200, Ian Abbott <abbotti@mev.co.uk> wrote:
> GDB's '--with-lzma=auto/yes/no' option defaults to 'auto' but it would
> be better to configure it to 'yes' or 'no' explicitly.  GDB's lzma
> support is required to read the .gnu_debuginfo sections in binaries (if
> they have been built to include those sections), so call the
> configuration option GDB_DEBUGINFO_SUPPORT.
> 
> The '--with-lzma' option was added in GDB 7.6, but that is quite old, so
> assume it is supported.
> 
> While we are at it, change the test `ifneq ($(filter
> 1%,$(GDBSERVER_VERSION)),)` to use `$(GDB_VERSION)` instead, and add the
> '--without-python' configure command line option.
> 
> Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
> Message-Id: <20240508101404.272507-1-abbotti@mev.co.uk>
> Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
> 
> diff --git a/rules/gdb.in b/rules/gdb.in
> index 3014271de9c1..9e76307e36b1 100644
> --- a/rules/gdb.in
> +++ b/rules/gdb.in
> @@ -8,6 +8,7 @@ menuconfig GDB
>  	select GCCLIBS_GCC_S
>  	select NCURSES
>  	select LIBGMP		if GDB_11_1
> +	select XZ		if GDB_DEBUGINFO_SUPPORT
>  	help
>  	  The GNU Debugger
>  
> @@ -26,6 +27,17 @@ config GDB_SHARED
>  	  If not set, the build option
>  	  LDFLAGS=-static will be activated.
>  
> +config GDB_DEBUGINFO_SUPPORT
> +	bool
> +	prompt "support reading .gnu_debuginfo sections"
> +	help
> +	  Configures whether to link with liblzma to support reading the
> +	  .gnu_debuginfo sections in binaries.
> +
> +	  Note: This is useful if TARGET_MINI_DEBUGINFO has been enabled
> +	  in the platform configuration to add .gnu_debuginfo sections
> +	  to all the binaries.
> +
>  config GDB_11_1
>  	bool
>  	prompt "gdb-11.1 or later"
> diff --git a/rules/gdb.make b/rules/gdb.make
> index 6c9f05fab7f5..c1337427b605 100644
> --- a/rules/gdb.make
> +++ b/rules/gdb.make
> @@ -40,10 +40,12 @@ endif
>  GDB_CONF_OPT_HOST	:= \
>  	--disable-tui \
>  	--disable-rpath \
> +	--with-lzma=$(call ptx/yesno, PTXCONF_GDB_DEBUGINFO_SUPPORT) \
>  	--without-expat \
> -	--without-mpfr
> +	--without-mpfr \
> +	--without-python
>  
> -ifneq ($(filter 1%,$(GDBSERVER_VERSION)),)
> +ifneq ($(filter 1%,$(GDB_VERSION)),)
>  # version >= 10
>  GDB_CONF_OPT_HOST	+= \
>  	--without-xxhash
> @@ -72,7 +74,8 @@ GDB_BUILD_OOT := YES
>  
>  # for gdb subdir configure
>  GDB_MAKE_ENV		:= \
> -	with_libgmp_prefix=no
> +	with_libgmp_prefix=no \
> +	with_liblzma_prefix=no
>  
>  # ----------------------------------------------------------------------------
>  # Install



      reply	other threads:[~2024-05-12 13:19 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-08 10:14 [ptxdist] [PATCH] " Ian Abbott
2024-05-12 13:16 ` Michael Olbrich [this message]

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=20240512131647.3703936-1-m.olbrich@pengutronix.de \
    --to=m.olbrich@pengutronix.de \
    --cc=abbotti@mev.co.uk \
    --cc=ptxdist@pengutronix.de \
    /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