All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/oprofile: needs zlib
@ 2021-10-30 21:47 Fabrice Fontaine
  2021-11-01  8:47 ` Thomas Petazzoni
  0 siblings, 1 reply; 7+ messages in thread
From: Fabrice Fontaine @ 2021-10-30 21:47 UTC (permalink / raw)
  To: buildroot; +Cc: Fabrice Fontaine

oprofile needs zlib to avoid the following build failure which is, for
an unknown reason, only raised since August 2021:

checking for bfd_openr in -lbfd... no
checking for compress in -lz... no
configure: error: libz library not found; required by libbfd

Fixes:
 - http://autobuild.buildroot.org/results/0e1d16dfbb455a08db80ac5d35613908c3b4163f

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 package/oprofile/Config.in   | 1 +
 package/oprofile/oprofile.mk | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/package/oprofile/Config.in b/package/oprofile/Config.in
index cce2cfdab8..1e222a88f2 100644
--- a/package/oprofile/Config.in
+++ b/package/oprofile/Config.in
@@ -23,6 +23,7 @@ config BR2_PACKAGE_OPROFILE
 	select BR2_PACKAGE_POPT
 	select BR2_PACKAGE_BINUTILS
 	select BR2_PACKAGE_LIBPFM4 if BR2_PACKAGE_OPROFILE_NEEDS_LIBPFM4
+	select BR2_PACKAGE_ZLIB
 	help
 	  OProfile is a system-wide profiler for Linux systems,
 	  capable of profiling all running code at low overhead.
diff --git a/package/oprofile/oprofile.mk b/package/oprofile/oprofile.mk
index 85bc4efa9b..fc88cfc038 100644
--- a/package/oprofile/oprofile.mk
+++ b/package/oprofile/oprofile.mk
@@ -36,7 +36,7 @@ ifeq ($(OPROFILE_ARCH),)
 OPROFILE_ARCH = $(BR2_ARCH)
 endif
 
-OPROFILE_DEPENDENCIES = popt binutils host-pkgconf
+OPROFILE_DEPENDENCIES = popt binutils host-pkgconf zlib
 
 ifeq ($(BR2_PACKAGE_LIBPFM4),y)
 OPROFILE_DEPENDENCIES += libpfm4
-- 
2.33.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/oprofile: needs zlib
  2021-10-30 21:47 [Buildroot] [PATCH 1/1] package/oprofile: needs zlib Fabrice Fontaine
@ 2021-11-01  8:47 ` Thomas Petazzoni
  2021-11-09 21:40   ` Arnout Vandecappelle
  0 siblings, 1 reply; 7+ messages in thread
From: Thomas Petazzoni @ 2021-11-01  8:47 UTC (permalink / raw)
  To: Fabrice Fontaine; +Cc: buildroot

On Sat, 30 Oct 2021 23:47:34 +0200
Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:

> oprofile needs zlib to avoid the following build failure which is, for
> an unknown reason, only raised since August 2021:

I don't really like changes that are made "for an unknown reason".
Indeed, if you look at
http://autobuild.buildroot.net/?reason=oprofile-1.4.0, this issue only
appeared 3 times, and only on static-linking configurations.

So, I would really like to see a better investigation than just "adding
this fixes the problem". We are clearly building OProfile many many
times in the autobuilder, and it doesn't need zlib, except in this
particular statically linked configuration.

So I'm afraid we need a more in-depth exploration of this issue.

Best regards,

Thomas
-- 
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

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/oprofile: needs zlib
  2021-11-01  8:47 ` Thomas Petazzoni
@ 2021-11-09 21:40   ` Arnout Vandecappelle
  2021-11-09 22:25     ` Yann E. MORIN
  0 siblings, 1 reply; 7+ messages in thread
From: Arnout Vandecappelle @ 2021-11-09 21:40 UTC (permalink / raw)
  To: Thomas Petazzoni, Fabrice Fontaine; +Cc: buildroot



On 01/11/2021 09:47, Thomas Petazzoni wrote:
> On Sat, 30 Oct 2021 23:47:34 +0200
> Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:
> 
>> oprofile needs zlib to avoid the following build failure which is, for
>> an unknown reason, only raised since August 2021:
> 
> I don't really like changes that are made "for an unknown reason".
> Indeed, if you look at
> http://autobuild.buildroot.net/?reason=oprofile-1.4.0, this issue only
> appeared 3 times, and only on static-linking configurations.
> 
> So, I would really like to see a better investigation than just "adding
> this fixes the problem". We are clearly building OProfile many many
> times in the autobuilder, and it doesn't need zlib, except in this
> particular statically linked configuration.
> 
> So I'm afraid we need a more in-depth exploration of this issue.

  I did a slightly more in-depth exploration.

  In config.log, we see this:

configure:13535: checking for bfd_openr in -lbfd
configure:13560: 
/tmp/instance-0/output-1/per-package/oprofile/host/bin/arm-linux-gcc -o conftest 
-D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64  -Os -g0 
-static -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 
-static conftest.c -lbfd  -liberty -lpopt  -lintl >&5
/tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: 
/tmp/instance-0/output-1/per-package/oprofile/host/arm-buildroot-linux-uclibcgnueabi/sysroot/usr/lib/libbfd.a(compress.o): 
in function `decompress_contents':
compress.c:(.text+0x3c): undefined reference to `inflateInit_'
/tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: 
compress.c:(.text+0x70): undefined reference to `inflateEnd'
/tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: 
compress.c:(.text+0xa4): undefined reference to `inflate'
/tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: 
compress.c:(.text+0xb8): undefined reference to `inflateReset'
/tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: 
/tmp/instance-0/output-1/per-package/oprofile/host/arm-buildroot-linux-uclibcgnueabi/sysroot/usr/lib/libbfd.a(compress.o): 
in function `bfd_compress_section_contents':
compress.c:(.text+0x640): undefined reference to `compressBound'
/tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: 
compress.c:(.text+0x6d8): undefined reference to `compress'
collect2: error: ld returned 1 exit status


  Note that in this configuration, zlib is not selected (*), but apparently 
libbfd is still built with zlib support...

  It's pretty weird that the autobuild failure only started happening in August, 
on the 2021.02.x branch... But since it also happened on master only once, I 
guess it's just very very rare.


  Regards,
  Arnout

(*) which explains why this fails so infrequently. Static is already pretty 
rare, but in addition zlib is almost always selected by some other package. I 
checked in the autobuilder advanced search [1] but unfortunately I don't think 
there's a way to specify negative symbols, so I just checked about 20 of them 
manually and only the failing one doesn't have zlib selected.

[1] 
http://autobuild.buildroot.net/index.php?date[from]=2020-11-01&static=1&symbols[BR2_PACKAGE_OPROFILE]=y

(note: takes a very very long time to load).
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/oprofile: needs zlib
  2021-11-09 21:40   ` Arnout Vandecappelle
@ 2021-11-09 22:25     ` Yann E. MORIN
  2021-11-09 22:37       ` Fabrice Fontaine
  0 siblings, 1 reply; 7+ messages in thread
From: Yann E. MORIN @ 2021-11-09 22:25 UTC (permalink / raw)
  To: Arnout Vandecappelle; +Cc: Fabrice Fontaine, Thomas Petazzoni, buildroot

Arnout, Thomas, Fabrice, All,

On 2021-11-09 22:40 +0100, Arnout Vandecappelle spake thusly:
> On 01/11/2021 09:47, Thomas Petazzoni wrote:
> >On Sat, 30 Oct 2021 23:47:34 +0200
> >Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:
> >
> >>oprofile needs zlib to avoid the following build failure which is, for
> >>an unknown reason, only raised since August 2021:
> >
> >I don't really like changes that are made "for an unknown reason".
> >Indeed, if you look at
> >http://autobuild.buildroot.net/?reason=oprofile-1.4.0, this issue only
> >appeared 3 times, and only on static-linking configurations.
> >
> >So, I would really like to see a better investigation than just "adding
> >this fixes the problem". We are clearly building OProfile many many
> >times in the autobuilder, and it doesn't need zlib, except in this
> >particular statically linked configuration.
> >
> >So I'm afraid we need a more in-depth exploration of this issue.
> 
>  I did a slightly more in-depth exploration.
> 
>  In config.log, we see this:
> 
> configure:13535: checking for bfd_openr in -lbfd
> configure:13560:
> /tmp/instance-0/output-1/per-package/oprofile/host/bin/arm-linux-gcc -o
> conftest -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64
> -Os -g0 -static -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE
> -D_FILE_OFFSET_BITS=64 -static conftest.c -lbfd  -liberty -lpopt  -lintl >&5
> /tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: /tmp/instance-0/output-1/per-package/oprofile/host/arm-buildroot-linux-uclibcgnueabi/sysroot/usr/lib/libbfd.a(compress.o):
> in function `decompress_contents':
> compress.c:(.text+0x3c): undefined reference to `inflateInit_'
> /tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld:
> compress.c:(.text+0x70): undefined reference to `inflateEnd'
> /tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld:
> compress.c:(.text+0xa4): undefined reference to `inflate'
> /tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld:
> compress.c:(.text+0xb8): undefined reference to `inflateReset'
> /tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: /tmp/instance-0/output-1/per-package/oprofile/host/arm-buildroot-linux-uclibcgnueabi/sysroot/usr/lib/libbfd.a(compress.o):
> in function `bfd_compress_section_contents':
> compress.c:(.text+0x640): undefined reference to `compressBound'
> /tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld:
> compress.c:(.text+0x6d8): undefined reference to `compress'
> collect2: error: ld returned 1 exit status
> 
>  Note that in this configuration, zlib is not selected (*), but apparently
> libbfd is still built with zlib support...

That's because binutils (at least 2.36.1) ships with a bundled copy
that it builds:

    >>> binutils 2.36.1 Building
    [...] /usr/bin/make -j9 LIBS= MAKEINFO=true -C /home/ymorin/dev/buildroot/O/build/binutils-2.36.1/
    make[3]: Nothing to be done for 'all-target'.
    Configuring in ./etc
    configure: creating cache ./config.cache
    checking for a BSD-compatible install... /usr/bin/install -c
    configure: updating cache ./config.cache
    configure: creating ./config.status
    config.status: creating Makefile
    make[4]: Nothing to be done for 'all'.
    Configuring in ./zlib
    [...]

And hence libbfd is built against the bundled libz, which being what
autotools call a convenience library, is not isntalled.

And this bundled copy is always built, even if one is already present in
the system (i.e. with zlib enabled in the configuration).

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/oprofile: needs zlib
  2021-11-09 22:25     ` Yann E. MORIN
@ 2021-11-09 22:37       ` Fabrice Fontaine
  2021-11-10  9:12         ` Yann E. MORIN
  0 siblings, 1 reply; 7+ messages in thread
From: Fabrice Fontaine @ 2021-11-09 22:37 UTC (permalink / raw)
  To: Yann E. MORIN; +Cc: Thomas Petazzoni, Buildroot Mailing List

Le mar. 9 nov. 2021 à 23:26, Yann E. MORIN <yann.morin.1998@free.fr> a écrit :
>
> Arnout, Thomas, Fabrice, All,
>
> On 2021-11-09 22:40 +0100, Arnout Vandecappelle spake thusly:
> > On 01/11/2021 09:47, Thomas Petazzoni wrote:
> > >On Sat, 30 Oct 2021 23:47:34 +0200
> > >Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:
> > >
> > >>oprofile needs zlib to avoid the following build failure which is, for
> > >>an unknown reason, only raised since August 2021:
> > >
> > >I don't really like changes that are made "for an unknown reason".
> > >Indeed, if you look at
> > >http://autobuild.buildroot.net/?reason=oprofile-1.4.0, this issue only
> > >appeared 3 times, and only on static-linking configurations.
> > >
> > >So, I would really like to see a better investigation than just "adding
> > >this fixes the problem". We are clearly building OProfile many many
> > >times in the autobuilder, and it doesn't need zlib, except in this
> > >particular statically linked configuration.
> > >
> > >So I'm afraid we need a more in-depth exploration of this issue.
> >
> >  I did a slightly more in-depth exploration.
> >
> >  In config.log, we see this:
> >
> > configure:13535: checking for bfd_openr in -lbfd
> > configure:13560:
> > /tmp/instance-0/output-1/per-package/oprofile/host/bin/arm-linux-gcc -o
> > conftest -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64
> > -Os -g0 -static -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE
> > -D_FILE_OFFSET_BITS=64 -static conftest.c -lbfd  -liberty -lpopt  -lintl >&5
> > /tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: /tmp/instance-0/output-1/per-package/oprofile/host/arm-buildroot-linux-uclibcgnueabi/sysroot/usr/lib/libbfd.a(compress.o):
> > in function `decompress_contents':
> > compress.c:(.text+0x3c): undefined reference to `inflateInit_'
> > /tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld:
> > compress.c:(.text+0x70): undefined reference to `inflateEnd'
> > /tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld:
> > compress.c:(.text+0xa4): undefined reference to `inflate'
> > /tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld:
> > compress.c:(.text+0xb8): undefined reference to `inflateReset'
> > /tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld: /tmp/instance-0/output-1/per-package/oprofile/host/arm-buildroot-linux-uclibcgnueabi/sysroot/usr/lib/libbfd.a(compress.o):
> > in function `bfd_compress_section_contents':
> > compress.c:(.text+0x640): undefined reference to `compressBound'
> > /tmp/instance-0/output-1/per-package/oprofile/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-uclibcgnueabi/9.3.0/../../../../arm-buildroot-linux-uclibcgnueabi/bin/ld:
> > compress.c:(.text+0x6d8): undefined reference to `compress'
> > collect2: error: ld returned 1 exit status
> >
> >  Note that in this configuration, zlib is not selected (*), but apparently
> > libbfd is still built with zlib support...
>
> That's because binutils (at least 2.36.1) ships with a bundled copy
> that it builds:
>
>     >>> binutils 2.36.1 Building
>     [...] /usr/bin/make -j9 LIBS= MAKEINFO=true -C /home/ymorin/dev/buildroot/O/build/binutils-2.36.1/
>     make[3]: Nothing to be done for 'all-target'.
>     Configuring in ./etc
>     configure: creating cache ./config.cache
>     checking for a BSD-compatible install... /usr/bin/install -c
>     configure: updating cache ./config.cache
>     configure: creating ./config.status
>     config.status: creating Makefile
>     make[4]: Nothing to be done for 'all'.
>     Configuring in ./zlib
>     [...]
>
> And hence libbfd is built against the bundled libz, which being what
> autotools call a convenience library, is not isntalled.
>
> And this bundled copy is always built, even if one is already present in
> the system (i.e. with zlib enabled in the configuration).
From my understanding of binutils's configure.ac, we should be able to
disable the bundled copy through --with-system-lib which is available
since version 2.26 and
https://github.com/bminor/binutils-gdb/commit/cf39cfc52ebd683d55fc396a77355f34b5094c04:

use_included_zlib=
AC_ARG_WITH(system-zlib,
[AS_HELP_STRING([--with-system-zlib], [use installed libz])])
# Make sure we don't let ZLIB be added if we didn't want it.
if test x$with_system_zlib = xyes ; then
  use_included_zlib=no
  noconfigdirs="$noconfigdirs zlib"
fi
>
> Regards,
> Yann E. MORIN.
>
> --
> .-----------------.--------------------.------------------.--------------------.
> |  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
> | +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
> | +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
> | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
> '------------------------------^-------^------------------^--------------------'
Best Regards,

Fabrice
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/oprofile: needs zlib
  2021-11-09 22:37       ` Fabrice Fontaine
@ 2021-11-10  9:12         ` Yann E. MORIN
  2021-11-10  9:40           ` Fabrice Fontaine
  0 siblings, 1 reply; 7+ messages in thread
From: Yann E. MORIN @ 2021-11-10  9:12 UTC (permalink / raw)
  To: Fabrice Fontaine; +Cc: Thomas Petazzoni, Buildroot Mailing List

Fabrice, All,

On 2021-11-09 23:37 +0100, Fabrice Fontaine spake thusly:
> Le mar. 9 nov. 2021 à 23:26, Yann E. MORIN <yann.morin.1998@free.fr> a écrit :
> > On 2021-11-09 22:40 +0100, Arnout Vandecappelle spake thusly:
> > > On 01/11/2021 09:47, Thomas Petazzoni wrote:
> > > >On Sat, 30 Oct 2021 23:47:34 +0200
> > > >Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:
> > > >>oprofile needs zlib to avoid the following build failure which is, for
> > > >>an unknown reason, only raised since August 2021:
> > > >I don't really like changes that are made "for an unknown reason".
> > >  Note that in this configuration, zlib is not selected (*), but apparently
> > > libbfd is still built with zlib support...
> > That's because binutils (at least 2.36.1) ships with a bundled copy
> > that it builds:
> >
> >     >>> binutils 2.36.1 Building
> >     [...] /usr/bin/make -j9 LIBS= MAKEINFO=true -C /home/ymorin/dev/buildroot/O/build/binutils-2.36.1/
> >     make[3]: Nothing to be done for 'all-target'.
> >     Configuring in ./etc
> >     configure: creating cache ./config.cache
> >     checking for a BSD-compatible install... /usr/bin/install -c
> >     configure: updating cache ./config.cache
> >     configure: creating ./config.status
> >     config.status: creating Makefile
> >     make[4]: Nothing to be done for 'all'.
> >     Configuring in ./zlib
> >     [...]
> >
> > And hence libbfd is built against the bundled libz, which being what
> > autotools call a convenience library, is not isntalled.

... and it is also not installed because we anyway only do a partial
install of select libraries.

> > And this bundled copy is always built, even if one is already present in
> > the system (i.e. with zlib enabled in the configuration).
> From my understanding of binutils's configure.ac, we should be able to
> disable the bundled copy through --with-system-lib which is available
> since version 2.26 and
> https://github.com/bminor/binutils-gdb/commit/cf39cfc52ebd683d55fc396a77355f34b5094c04:

Oh yes, I forgot to mention that yesterday. Yes, this is I believe the
best solution: binutils should always depend on zlib (it currently only
conditionally depends on it).

Care to send the patch, please?

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/oprofile: needs zlib
  2021-11-10  9:12         ` Yann E. MORIN
@ 2021-11-10  9:40           ` Fabrice Fontaine
  0 siblings, 0 replies; 7+ messages in thread
From: Fabrice Fontaine @ 2021-11-10  9:40 UTC (permalink / raw)
  To: Yann E. MORIN; +Cc: Thomas Petazzoni, Buildroot Mailing List

Yann,

Le mer. 10 nov. 2021 à 10:12, Yann E. MORIN <yann.morin.1998@free.fr> a écrit :
>
> Fabrice, All,
>
> On 2021-11-09 23:37 +0100, Fabrice Fontaine spake thusly:
> > Le mar. 9 nov. 2021 à 23:26, Yann E. MORIN <yann.morin.1998@free.fr> a écrit :
> > > On 2021-11-09 22:40 +0100, Arnout Vandecappelle spake thusly:
> > > > On 01/11/2021 09:47, Thomas Petazzoni wrote:
> > > > >On Sat, 30 Oct 2021 23:47:34 +0200
> > > > >Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:
> > > > >>oprofile needs zlib to avoid the following build failure which is, for
> > > > >>an unknown reason, only raised since August 2021:
> > > > >I don't really like changes that are made "for an unknown reason".
> > > >  Note that in this configuration, zlib is not selected (*), but apparently
> > > > libbfd is still built with zlib support...
> > > That's because binutils (at least 2.36.1) ships with a bundled copy
> > > that it builds:
> > >
> > >     >>> binutils 2.36.1 Building
> > >     [...] /usr/bin/make -j9 LIBS= MAKEINFO=true -C /home/ymorin/dev/buildroot/O/build/binutils-2.36.1/
> > >     make[3]: Nothing to be done for 'all-target'.
> > >     Configuring in ./etc
> > >     configure: creating cache ./config.cache
> > >     checking for a BSD-compatible install... /usr/bin/install -c
> > >     configure: updating cache ./config.cache
> > >     configure: creating ./config.status
> > >     config.status: creating Makefile
> > >     make[4]: Nothing to be done for 'all'.
> > >     Configuring in ./zlib
> > >     [...]
> > >
> > > And hence libbfd is built against the bundled libz, which being what
> > > autotools call a convenience library, is not isntalled.
>
> ... and it is also not installed because we anyway only do a partial
> install of select libraries.
>
> > > And this bundled copy is always built, even if one is already present in
> > > the system (i.e. with zlib enabled in the configuration).
> > From my understanding of binutils's configure.ac, we should be able to
> > disable the bundled copy through --with-system-lib which is available
> > since version 2.26 and
> > https://github.com/bminor/binutils-gdb/commit/cf39cfc52ebd683d55fc396a77355f34b5094c04:
>
> Oh yes, I forgot to mention that yesterday. Yes, this is I believe the
> best solution: binutils should always depend on zlib (it currently only
> conditionally depends on it).
>
> Care to send the patch, please?
I'll send it this evening.
>
> Regards,
> Yann E. MORIN.
>
> --
> .-----------------.--------------------.------------------.--------------------.
> |  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
> | +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
> | +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
> | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
> '------------------------------^-------^------------------^--------------------'
Best Regards,

Fabrice
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-11-10  9:40 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-30 21:47 [Buildroot] [PATCH 1/1] package/oprofile: needs zlib Fabrice Fontaine
2021-11-01  8:47 ` Thomas Petazzoni
2021-11-09 21:40   ` Arnout Vandecappelle
2021-11-09 22:25     ` Yann E. MORIN
2021-11-09 22:37       ` Fabrice Fontaine
2021-11-10  9:12         ` Yann E. MORIN
2021-11-10  9:40           ` Fabrice Fontaine

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.