<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>3782</bug_id>
          
          <creation_ts>2013-01-23 14:41:45 +0000</creation_ts>
          <short_desc>mklibs fails when building optimized image</short_desc>
          <delta_ts>2015-09-11 14:20:48 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>OE-Core</product>
          <component>devtools / tool chain</component>
          <version>1.3</version>
          <rep_platform>x86</rep_platform>
          <op_sys>x86_64</op_sys>
          <bug_status>VERIFIED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>1.9 M2</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Andre Schramm">andre.schramm</reporter>
          <assigned_to name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</assigned_to>
          <cc>bogdanx.a.voiculescu</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>richard.purdie</cc>
    
    <cc>sgw</cc>
          
          <qa_contact name="Bogdan Alexandru Voiculescu">bogdanx.a.voiculescu</qa_contact>
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>No (bug/feature does not impact docs)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>29085</commentid>
    <comment_count>0</comment_count>
    <who name="Andre Schramm">andre.schramm</who>
    <bug_when>2013-01-23 14:41:45 +0000</bug_when>
    <thetext>Baking core-image-minimal with IMAGE_FEATURES += &quot;splash x11&quot;, tuned for core2_64 and local.conf with:

USER_CLASSES ?= &quot;buildstats image-mklibs image-prelink&quot;
MKLIBS_OPTIMIZED_IMAGES ?= &quot;all&quot;


Python dies in build/tmp/sysroots/x86_64-linux/usr/bin/mklibs:343:

    default_lib_path = multiarch([&quot;/lib/&quot;, &quot;/usr/lib/&quot;, &quot;/usr/X11R6/lib/&quot;])

with

    &quot;OSError: [Errno 2] No such file or directory&quot;

Problem is mklibs:265:

    dpkg_architecture = subprocess.Popen(
        [&apos;dpkg-architecture&apos;, &apos;-qDEB_HOST_MULTIARCH&apos;],
        stdout=subprocess.PIPE, stderr=devnull)

as it does not check for dpkg-architecture being present first.

Installing dpkg-devel manually fixes this (CentOS 6), but this is not listed in the docs as prerequisite. This dependency seems to be added/fixed in mklibs 1.35. [1]
use-host.patch for apt recipe completely discards dpkg-architecture and uses a workaround.

I default-tuned for generic x64 before core2_64 and the problem did not show up there.


The next problem is:

    cp: target `build/ipc/tmp/work/ipc-poky-linux/core-image-minimal-1.0-r0/rootfs/usr/lib64/libX11.so.6&apos; is not a directory


I added some debug output to mklibs, but can&apos;t figure what&apos;s wrong here and/or where &quot;cp&quot; is called.


[1] http://bazaar.launchpad.net/~ubuntu-installer/mklibs/master/revision/97</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>42045</commentid>
    <comment_count>1</comment_count>
    <who name="Mark Hatle">mark.hatle</who>
    <bug_when>2014-04-01 14:49:45 +0000</bug_when>
    <thetext>Investigate if mklibs is still required when we do 1.7 planning.  This may remove the necessity of this bug.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>46809</commentid>
    <comment_count>2</comment_count>
    <who name="Stephen K Jolley">sjolley.yp.pm</who>
    <bug_when>2014-11-06 16:09:37 +0000</bug_when>
    <thetext>Mark, Is this bug still required.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>47437</commentid>
    <comment_count>3</comment_count>
    <who name="Mark Hatle">mark.hatle</who>
    <bug_when>2014-12-08 19:55:53 +0000</bug_when>
    <thetext>mklibs is broken in some configurations.  I have not researched this in a while.  It&apos;s unclear to me how many people are using functionality to generate very small systems.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>50567</commentid>
    <comment_count>4</comment_count>
    <who name="Mark Hatle">mark.hatle</who>
    <bug_when>2015-04-28 18:10:37 +0000</bug_when>
    <thetext>To set a properly 1.9 milestone (or close this out) we need to understand if mklibs is still being used in any configurations.

If it&apos;s not, I&apos;d suggest removing it due to lack of proper maintainer.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>50585</commentid>
    <comment_count>5</comment_count>
    <who name="Stephen K Jolley">sjolley.yp.pm</who>
    <bug_when>2015-04-28 20:42:46 +0000</bug_when>
    <thetext>Mark Hatle also noted that we should check w/ the Tiny Linux / Micro Linux initiative.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>50649</commentid>
    <comment_count>6</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2015-04-30 14:39:47 +0000</bug_when>
    <thetext>I think we will have need for mklibs so we can&apos;t remove it just yet. I believe someone in GDC has some debian knowledge which may help in looking into how we can remove the dpkg-architecture call.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>51593</commentid>
    <comment_count>7</comment_count>
    <who name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</who>
    <bug_when>2015-06-09 20:54:56 +0000</bug_when>
    <thetext>(In reply to comment #0)
&gt; Baking core-image-minimal with IMAGE_FEATURES += &quot;splash x11&quot;, tuned for
&gt; core2_64 and local.conf with:
&gt; 
&gt; USER_CLASSES ?= &quot;buildstats image-mklibs image-prelink&quot;
&gt; MKLIBS_OPTIMIZED_IMAGES ?= &quot;all&quot;
&gt; 
Andre, can you send me your full local.conf or any general configuration I need to take into account? The point is that I have not seen the problems you are describing below.

&gt; 
&gt; Python dies in build/tmp/sysroots/x86_64-linux/usr/bin/mklibs:343:
&gt; 
&gt;     default_lib_path = multiarch([&quot;/lib/&quot;, &quot;/usr/lib/&quot;, &quot;/usr/X11R6/lib/&quot;])
&gt; 
&gt; with
&gt; 
&gt;     &quot;OSError: [Errno 2] No such file or directory&quot;
&gt; 
&gt; Problem is mklibs:265:
&gt; 
&gt;     dpkg_architecture = subprocess.Popen(
&gt;         [&apos;dpkg-architecture&apos;, &apos;-qDEB_HOST_MULTIARCH&apos;],
&gt;         stdout=subprocess.PIPE, stderr=devnull)
&gt; 
&gt; as it does not check for dpkg-architecture being present first.
&gt; 
&gt; Installing dpkg-devel manually fixes this (CentOS 6), but this is not listed
&gt; in the docs as prerequisite. This dependency seems to be added/fixed in
&gt; mklibs 1.35. [1]
&gt; use-host.patch for apt recipe completely discards dpkg-architecture and uses
&gt; a workaround.
&gt; 
&gt; I default-tuned for generic x64 before core2_64 and the problem did not show
&gt; up there.
&gt; 
&gt; 
&gt; The next problem is:
&gt; 
&gt;     cp: target
&gt; `build/ipc/tmp/work/ipc-poky-linux/core-image-minimal-1.0-r0/rootfs/usr/
&gt; lib64/libX11.so.6&apos; is not a directory
&gt; 
&gt; 
&gt; I added some debug output to mklibs, but can&apos;t figure what&apos;s wrong here
&gt; and/or where &quot;cp&quot; is called.
&gt; 
&gt; 
&gt; [1] http://bazaar.launchpad.net/~ubuntu-installer/mklibs/master/revision/97</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>52954</commentid>
    <comment_count>8</comment_count>
    <who name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</who>
    <bug_when>2015-08-10 15:07:40 +0000</bug_when>
    <thetext>Fixed with OE-Core 00a706e69c8cb9daf8458ee76aa4aedd8699f5a4</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>53976</commentid>
    <comment_count>9</comment_count>
    <who name="Bogdan Alexandru Voiculescu">bogdanx.a.voiculescu</who>
    <bug_when>2015-09-11 14:20:48 +0000</bug_when>
    <thetext>verified on master: d4585fa23d56a58c583ee33db067a23177a936b1</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>