[Buildroot] [PATCH 1/1] package/ibrcommon: fix basename call under musl

Thomas Petazzoni thomas.petazzoni at free-electrons.com
Sun Sep 20 12:51:33 UTC 2015


Dear Brendan Heading,

On Mon, 14 Sep 2015 23:26:51 +0100, Brendan Heading wrote:
> Fixes:
> http://autobuild.buildroot.net/results/9c3/9c3889fe80e58b7a35c242332f993992044d2f6b/
> 
> ibrcommon was relying on a glibc extension to basename(3) which allowed it
> to accept a const char* parameter (instead of char*). Fixed by testing
> for __GLIBC__; if not defined (such as when musl is in use) a fallback
> block is used which creates a temporary copy of the path.
> 
> Signed-off-by: Brendan Heading <brendanheading at gmail.com>
> ---
>  ...data-File.cpp-support-POSIX-basename-call.patch | 55 ++++++++++++++++++++++
>  1 file changed, 55 insertions(+)
>  create mode 100644 package/ibrcommon/0001-ibrcommon-data-File.cpp-support-POSIX-basename-call.patch

Applied, thanks. However, I believe a better fix would be to use an
autoconf test rather than really on this crazy set of #ifdef for the
different platforms.

Thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com


More information about the buildroot mailing list