ping #3: [RFA] Add --with-libz-prefix option in config/zlib.m4
Mike Frysinger
vapier@gentoo.org
Wed Feb 18 23:10:00 GMT 2015
On 18 Feb 2015 14:24, H.J. Lu wrote:
> On Wed, Feb 18, 2015 at 2:21 PM, Mike Frysinger wrote:
> > i think we already have the reports: multiple people don't think it should be
> > (1) x86-specific or (2) required. don't get me wrong -- i think having support
> > like this is great. that doesn't mean we should be forcing it.
>
> Please file a bug report with a testcase.
this is getting kafka-esque. you yourself stated:
On Linux/x86, zlib is required for assembler. At least, you should issue an
error when --without-libz is used in binutils for Linux/x86 target.
that should not be the case. making someone open a bug report so you can close
it with "fixed" and a patch is wasting time. just fix it now.
all that said, if we look at your actual commit (89e7505fcde4bd83948f559f429a0):
gas/config/tc-i386.c:
+#ifdef TE_LINUX
+/* Default to compress debug sections for Linux. */
+int flag_compress_debug = 1;
+#endif
and we look at where that flag is used:
gas/as.c:
...
case OPTION_COMPRESS_DEBUG:
#ifdef HAVE_ZLIB_H
flag_compress_debug = 1;
#else
as_warn (_("cannot compress debug sections (zlib not installed)"));
#endif /* HAVE_ZLIB_H */
break;
case OPTION_NOCOMPRESS_DEBUG:
flag_compress_debug = 0;
break;
...
gas/write.c:
void
write_object_file (void)
{
...
if (flag_compress_debug)
bfd_map_over_sections (stdoutput, compress_debug, (char *) 0);
...
static void
compress_debug (bfd *abfd, asection *sec, void *xxx ATTRIBUTE_UNUSED)
{
...
strm = compress_init ();
if (strm == NULL)
return;
it turns out the current code does *not* require zlib. as long as that does not
change (either issuing a warning or throwing an error), i see no reason why we
need or should make zlib a requirement in binutils, regardless of target.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <https://sourceware.org/pipermail/binutils/attachments/20150218/47cf986b/attachment.sig>
More information about the Binutils
mailing list