Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Simon Marchi <simark@simark.ca>
To: "Torbjörn SVENSSON" <torbjorn.svensson@foss.st.com>,
	binutils@sourceware.org, gdb-patches@sourceware.org
Subject: Re: [PATCH v2] configure: Support --with-zstd=PATH
Date: Mon, 28 Sep 2026 22:00:32 -0400	[thread overview]
Message-ID: <7e7d11d7-8b43-4150-81cb-29864763f4cf@simark.ca> (raw)
In-Reply-To: <20260928053309.1949979-1-torbjorn.svensson@foss.st.com>



On 2026-09-28 01:30, Torbjörn SVENSSON wrote:
> Hi,
> 
> V1 can be found here:
> https://sourceware.org/pipermail/binutils/2026-September/151687.html
> 
> Changes since v1:
> - Added missed changes in binutils/Makefile.am and binutils/Makefile.in
> - Added support for dynamic version of zstd in path
> 
> 
> Ok for trunk?
> 
> Kind regards,
> Torbjörn
> 
> --
> 
> Allow --with-zstd to specify an installation prefix.  Use the headers
> and static library under that prefix, and reject it if it does not
> provide zstd 1.4.0 or newer.
> 
> Regenerate the affected configure scripts.
> 
> Signed-off-by: Torbjörn SVENSSON <torbjorn.svensson@foss.st.com>

Can you explain why using pkg-config wouldn't work for your use case?

In your other message, you mentioned that gcc also accepted a
--with-zstd=path, but it actually accepts more:

  --with-zstd=PATH        specify prefix directory for installed zstd library.
                          Equivalent to --with-zstd-include=PATH/include plus
                          --with-zstd-lib=PATH/lib
  --with-zstd-include=PATH
                          specify directory for installed zstd include files
  --with-zstd-lib=PATH    specify directory for the installed zstd library

This is open-coded in gcc/configure.ac:

  # Look for the ZSTD package.
  ZSTD_INCLUDE=
  ZSTD_LIB=
  AC_SUBST(ZSTD_INCLUDE)
  AC_SUBST(ZSTD_LIB)
  ZSTD_CPPFLAGS=
  ZSTD_LDFLAGS=
  AC_SUBST(ZSTD_CPPFLAGS)
  AC_SUBST(ZSTD_LDFLAGS)
  AC_ARG_WITH(zstd,
          [AS_HELP_STRING([--with-zstd=PATH],
                  [specify prefix directory for installed zstd library.
                   Equivalent to --with-zstd-include=PATH/include
                   plus --with-zstd-lib=PATH/lib])])
  AC_ARG_WITH(zstd-include,
          [AS_HELP_STRING([--with-zstd-include=PATH],
                  [specify directory for installed zstd include files])])
  AC_ARG_WITH(zstd-lib,
          [AS_HELP_STRING([--with-zstd-lib=PATH],
                  [specify directory for the installed zstd library])])

For consistency across the toolchain, would you consider moving this gcc
code to gcc/config/zstd.m4, and then sync gcc's zstd.m4 over to
binutils-gdb?

Simon

      reply	other threads:[~2026-09-29  2:02 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-28  5:30 Torbjörn SVENSSON
2026-09-29  2:00 ` Simon Marchi [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=7e7d11d7-8b43-4150-81cb-29864763f4cf@simark.ca \
    --to=simark@simark.ca \
    --cc=binutils@sourceware.org \
    --cc=gdb-patches@sourceware.org \
    --cc=torbjorn.svensson@foss.st.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