<?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>3547</bug_id>
          
          <creation_ts>2012-12-06 11:37:36 +0000</creation_ts>
          <short_desc>mkelfimage-native: do_compile failed if host does not install libz</short_desc>
          <delta_ts>2013-01-11 09:25:35 +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.4</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</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.4</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Hongxu Jia">hongxu.jia</reporter>
          <assigned_to name="Hongxu Jia">hongxu.jia</assigned_to>
          <cc>bogdan.a.marinescu</cc>
    
    <cc>kai.kang</cc>
    
    <cc>liang.li2</cc>
    
    <cc>liezhi.yang</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>Qi.Chen</cc>
    
    <cc>sgw</cc>
    
    <cc>yi.zhao</cc>
    
    <cc>zhenfeng.zhao</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>---</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>28039</commentid>
    <comment_count>0</comment_count>
    <who name="Hongxu Jia">hongxu.jia</who>
    <bug_when>2012-12-06 11:37:36 +0000</bug_when>
    <thetext>OS:Fedora 17
tree/branch: poky/master
commit 381c4b69c7e8b452f4d3de2f8214e6e5f6a9abe7

*problem
Compile mkelfimage-native failed if host does not 
install libz.
&gt;&gt;log&lt;&lt;
...
fatal error: zlib.h: No such file or directory
/usr/bin/ld: cannot find -lz
...

*analysis
If the host does not install libz, bitbake mkelfimage 
works well but mkelfimage-native failed, because
mkelfimage-native find libz from host dir, not from 
the staging directories.

*solution
1.Config LDFLAGS and LDFALGS_class-native in bb 
file to let mkelfimage and mkelfimage-native 
find libz and zlib.h from the staging directories.

2.Modify confiugre.ac to let makefile find libz 
and zlib.h by CFLAGS and LDFLAGS. Because the 
original Makefile don&apos;t make use of them.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>28387</commentid>
    <comment_count>1</comment_count>
    <who name="Hongxu Jia">hongxu.jia</who>
    <bug_when>2012-12-20 00:36:52 +0000</bug_when>
    <thetext>Merged into master:

http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=b70784ce581de8c0bf38227106e7313bb485c3d3</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>28751</commentid>
    <comment_count>2</comment_count>
    <who name="liang li">liang.li2</who>
    <bug_when>2013-01-11 09:25:35 +0000</bug_when>
    <thetext>verified on git commit 66f4c8a674d9f8db958b13866af4d63ab8cbcd44</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>