All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni via buildroot <buildroot@buildroot.org>
To: Yegor Yefremov <yegorslists@googlemail.com>
Cc: buildroot@buildroot.org, "Wojciech M . Zabolotny" <wzab01@gmail.com>
Subject: Re: [Buildroot] [PATCH v2 1/2] package/avrdude: fix readline dependency
Date: Sun, 25 Oct 2026 21:54:33 +0100	[thread overview]
Message-ID: <at5sfsDK6z8l5vD2@windsurf> (raw)
In-Reply-To: <20261023225751.2614512-1-yegorslists@googlemail.com>

On Sat, Oct 24, 2026 at 12:57:50AM +0200, Yegor Yefremov wrote:
> avrdude automatically detects and links against readline when it finds
> libreadline in the sysroot (find_library(HAVE_LIBREADLINE ...) in
> CMakeLists.txt; AC_CHECK_LIB([readline], [readline]) with the former
> autotools build system), and there is no option to disable it.
> 
> Buildroot never declared this dependency, so the result depended on
> whether readline happened to be built before avrdude. Even worse, some
> external toolchains (e.g. the Bootlin ones) ship libreadline in their
> sysroot. In that case avrdude ends up linked against it without
> BR2_PACKAGE_READLINE being enabled:
> 
>   $ readelf -d target/usr/bin/avrdude | grep readline
>    0x0000000000000001 (NEEDED)    Shared library: [libreadline.so.8]
> 
> but libreadline is not installed to the target, so avrdude fails to
> run.
> 
> Add readline to the dependencies when it is enabled, and otherwise
> pass -DHAVE_LIBREADLINE=OFF, so that find_library() skips the search
> and readline support is disabled.
> 
> This issue has been present since commit dc776f0d0546 ("avrdude: new
> package"), as avrdude has always detected readline automatically. It
> therefore affects 2014.02 and later, including all maintained
> branches.
> 
> Fixes: dc776f0d0546900b22d1552f3e522be2080016c6 ("avrdude: new package")
> Assisted-by: Claude:claude-opus-5-5
> Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>

Series applied to master, thanks!

Best regards,

Thomas Petazzoni
-- 
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

      parent reply	other threads:[~2026-10-25 20:54 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-23 11:02 [Buildroot] [PATCH] package/avrdude: fix readline dependency Yegor Yefremov via buildroot
2026-10-23 22:57 ` [Buildroot] [PATCH v2 1/2] " Yegor Yefremov
2026-10-23 22:57   ` [Buildroot] [PATCH v2 2/2] package/avrdude: fix libserialport dependency Yegor Yefremov via buildroot
2026-10-25 20:54   ` Thomas Petazzoni via buildroot [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=at5sfsDK6z8l5vD2@windsurf \
    --to=buildroot@buildroot.org \
    --cc=thomas.petazzoni@bootlin.com \
    --cc=wzab01@gmail.com \
    --cc=yegorslists@googlemail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.