<?xml version="1.0" encoding="UTF-8" ?>

<bugzilla version="5.2"
          urlbase="https://bugzilla.altlinux.org/"
          
          maintainer="jenya@basealt.ru"
>

    <bug>
          <bug_id>36382</bug_id>
          
          <creation_ts>2019-03-25 20:15:46 +0300</creation_ts>
          <short_desc>extlinux-6.04.pre1-alt1.5e426532 builds its own copy of zlib</short_desc>
          <delta_ts>2019-03-25 23:05:36 +0300</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>4</classification_id>
          <classification>Development</classification>
          <product>Sisyphus</product>
          <component>extlinux</component>
          <version>unstable</version>
          <rep_platform>all</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>NOTABUG</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P3</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Dmitry V. Levin">ldv</reporter>
          <assigned_to name="Alexey Gladkov">legion</assigned_to>
          <cc>legion</cc>
          
          <qa_contact>qa-sisyphus</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>179925</commentid>
    <comment_count>0</comment_count>
    <who name="Dmitry V. Levin">ldv</who>
    <bug_when>2019-03-25 20:15:46 +0300</bug_when>
    <thetext>$ grep -Fc /com32/lib/zlib/ beehive/logs/Sisyphus-x86_64/latest/success/extlinux-6.04.pre1-alt1.5e426532
53

$ comm -12 &lt;(/usr/lib/rpm/provided_symbols /lib64/libz.so.1 |sort) \
&lt;(/usr/lib/rpm/provided_symbols /boot/extlinux/libcom32.c32 |sort)
adler32
adler32_combine
adler32_combine64
compress
compress2
compressBound
crc32
crc32_combine
crc32_combine64
deflate
deflateBound
deflateCopy
deflateEnd
deflateInit_
deflateInit2_
deflateParams
deflatePrime
deflateReset
deflateSetDictionary
deflateSetHeader
deflateTune
get_crc_table
inflate
inflateBack
inflateBackEnd
inflateBackInit_
inflateCopy
inflateEnd
inflateGetHeader
inflateInit_
inflateInit2_
inflateMark
inflatePrime
inflateReset
inflateReset2
inflateSetDictionary
inflateSync
inflateSyncPoint
inflateUndermine
uncompress
zError
zlibCompileFlags
zlibVersion</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>179928</commentid>
    <comment_count>1</comment_count>
    <who name="Alexey Gladkov">legion</who>
    <bug_when>2019-03-25 20:37:21 +0300</bug_when>
    <thetext>Yes. This code is executed before the kernel is loaded. It cannot be linked with dynamic libraries.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>179929</commentid>
    <comment_count>2</comment_count>
    <who name="Dmitry V. Levin">ldv</who>
    <bug_when>2019-03-25 20:40:08 +0300</bug_when>
    <thetext>(In reply to comment #1)
&gt; Yes. This code is executed before the kernel is loaded. It cannot be linked
&gt; with dynamic libraries.

What about linking with zlib.a?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>179933</commentid>
    <comment_count>3</comment_count>
    <who name="Alexey Gladkov">legion</who>
    <bug_when>2019-03-25 21:09:32 +0300</bug_when>
    <thetext>(In reply to comment #2)
&gt; What about linking with zlib.a?

They have not only zlib:

https://repo.or.cz/syslinux.git/tree/05ac953c23f90b2328d393f7eecde96e41aed067:/com32/lib/zlib
https://repo.or.cz/syslinux.git/tree/05ac953c23f90b2328d393f7eecde96e41aed067:/com32/lib/libpng

BTW I can see that they changed this code:

https://repo.or.cz/syslinux.git/history/HEAD:/com32/lib/zlib

I see no point in linking this code with static zlib and libpng. It runs on another level than kernel or everything else in the system.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>179936</commentid>
    <comment_count>4</comment_count>
    <who name="Dmitry V. Levin">ldv</who>
    <bug_when>2019-03-25 21:47:44 +0300</bug_when>
    <thetext>(In reply to comment #3)
&gt; (In reply to comment #2)
&gt; &gt; What about linking with zlib.a?
&gt; 
&gt; They have not only zlib:
&gt; 
&gt; https://repo.or.cz/syslinux.git/tree/05ac953c23f90b2328d393f7eecde96e41aed067:/com32/lib/zlib
&gt; https://repo.or.cz/syslinux.git/tree/05ac953c23f90b2328d393f7eecde96e41aed067:/com32/lib/libpng
&gt; 
&gt; BTW I can see that they changed this code:
&gt; 
&gt; https://repo.or.cz/syslinux.git/history/HEAD:/com32/lib/zlib

It&apos;s the same code as zlib v1.2.11 with some files removed.

&gt; I see no point in linking this code with static zlib and libpng. It runs on
&gt; another level than kernel or everything else in the system.

Could you at least make these zlib symbols hidden?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>179938</commentid>
    <comment_count>5</comment_count>
    <who name="Alexey Gladkov">legion</who>
    <bug_when>2019-03-25 22:21:22 +0300</bug_when>
    <thetext>(In reply to comment #4)
&gt; &gt; I see no point in linking this code with static zlib and libpng. It runs on
&gt; &gt; another level than kernel or everything else in the system.
&gt; 
&gt; Could you at least make these zlib symbols hidden?

Why ?

All that is below the /boot/extlinux can&apos;t be verified for unresolved symbols as well. We agreed that these files will be ignored by any distro checks.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>179940</commentid>
    <comment_count>6</comment_count>
    <who name="Dmitry V. Levin">ldv</who>
    <bug_when>2019-03-25 22:32:57 +0300</bug_when>
    <thetext>(In reply to comment #5)
&gt; (In reply to comment #4)
&gt; &gt; &gt; I see no point in linking this code with static zlib and libpng. It runs on
&gt; &gt; &gt; another level than kernel or everything else in the system.
&gt; &gt; 
&gt; &gt; Could you at least make these zlib symbols hidden?
&gt; 
&gt; Why ?

Because you can.
I wish I could change the default in gcc to generate all symbols as hidden.

&gt; All that is below the /boot/extlinux can&apos;t be verified for unresolved symbols
&gt; as well. We agreed that these files will be ignored by any distro checks.

I don&apos;t see any signs of it in the code.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>179943</commentid>
    <comment_count>7</comment_count>
    <who name="Alexey Gladkov">legion</who>
    <bug_when>2019-03-25 22:48:05 +0300</bug_when>
    <thetext>(In reply to comment #6)
&gt; &gt; Why ?
&gt; 
&gt; Because you can.
&gt; I wish I could change the default in gcc to generate all symbols as hidden.

Я могу попробовать, но не обещаю. Я очень не хочу этот код сломать изменениями ради изменений. Если он тебе мешает, то удаляй его из сизифа. Я буду его использовать вне репозитория.

&gt; &gt; All that is below the /boot/extlinux can&apos;t be verified for unresolved symbols
&gt; &gt; as well. We agreed that these files will be ignored by any distro checks.
&gt; 
&gt; I don&apos;t see any signs of it in the code.

Дим, да ты чего ? Мы же с тобой отдельно расследовали это, когда я выкладывал extlinux-6 и когда он не мог пройти сборочницу из-за того что апстрим перешёл на ELF.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>179944</commentid>
    <comment_count>8</comment_count>
    <who name="Dmitry V. Levin">ldv</who>
    <bug_when>2019-03-25 22:57:57 +0300</bug_when>
    <thetext>(In reply to comment #7)
&gt; (In reply to comment #6)
&gt; &gt; &gt; Why ?
&gt; &gt; 
&gt; &gt; Because you can.
&gt; &gt; I wish I could change the default in gcc to generate all symbols as hidden.
&gt; 
&gt; Я могу попробовать, но не обещаю. Я очень не хочу этот код сломать изменениями
&gt; ради изменений. Если он тебе мешает, то удаляй его из сизифа. Я буду его
&gt; использовать вне репозитория.

Тебе же будет лучше, если zlib не будет из него светиться.

&gt; &gt; &gt; All that is below the /boot/extlinux can&apos;t be verified for unresolved symbols
&gt; &gt; &gt; as well. We agreed that these files will be ignored by any distro checks.
&gt; &gt; 
&gt; &gt; I don&apos;t see any signs of it in the code.
&gt; 
&gt; Дим, да ты чего ? Мы же с тобой отдельно расследовали это, когда я выкладывал
&gt; extlinux-6 и когда он не мог пройти сборочницу из-за того что апстрим перешёл
&gt; на ELF.

Значит, я тогда сделал какое-то временное решение, которое никуда не закоммичено.  Плохо.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>179946</commentid>
    <comment_count>9</comment_count>
    <who name="Alexey Gladkov">legion</who>
    <bug_when>2019-03-25 23:05:36 +0300</bug_when>
    <thetext>(In reply to comment #8)
&gt; &gt; Я могу попробовать, но не обещаю. Я очень не хочу этот код сломать изменениями
&gt; &gt; ради изменений. Если он тебе мешает, то удаляй его из сизифа. Я буду его
&gt; &gt; использовать вне репозитория.
&gt; 
&gt; Тебе же будет лучше, если zlib не будет из него светиться.

С чего мне будет лучше ? Это никак не влияет на функционал. Это только заткнёт ещё одну userspace проверку разве что.

&gt; &gt; Дим, да ты чего ? Мы же с тобой отдельно расследовали это, когда я выкладывал
&gt; &gt; extlinux-6 и когда он не мог пройти сборочницу из-за того что апстрим перешёл
&gt; &gt; на ELF.
&gt; 
&gt; Значит, я тогда сделал какое-то временное решение, которое никуда не
&gt; закоммичено.  Плохо.

$ diff -u /usr/lib64/perl5/qa/rpmelfsym.pm{~,}                                                                                              
--- /usr/lib64/perl5/qa/rpmelfsym.pm~                                                                                                       
+++ /usr/lib64/perl5/qa/rpmelfsym.pm                                                                                                        
@@ -33,6 +33,7 @@                                                                                                                           
                $filename =~ s#^\./|^/|^#/#;                                                                                                
                                                                                                                                            
                next if $filename =~ m#^/usr/lib/debug/.+\.debug\z#;                                                                        
+               next if $filename =~ /^\/boot\//;                                                                                           
                                                                                                                                            
                $ent-&gt;read(my $magic, 4) == 4                                                                                               
                        or die &quot;$rpm: $filename: cpio read failed&quot;; 

Смотри наш тред &quot;Re: [#197489] FAILED extlinux.git=6.03-alt1&quot; от 26 декабря 2017.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>