<div><span class="gmail_quote">On 9/21/06, <b class="gmail_sendername">Bernhard Fischer</b> &lt;<a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:rep.nop@aon.at" target="_blank">rep.nop@aon.at</a>&gt; wrote:
</span></div>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">On Wed, Sep 20, 2006 at 09:34:24PM +0800, Qiu Yu wrote:<br>&gt;Hi, all<br>&gt;<br>&gt;Paid some effort, I finally got my first buildroot-made rootfs image for 
<br>&gt;mipsel platform, but this pleasure did't last long.<br>&gt;<br>&gt;When I mount it on my board, after kernel started, I got an error message:<br>&gt;&quot;bin/sh&quot; can't resolve symbol bcopy<br><br>Either enable legacy support in uClibc (i wouldn't do this), or make 
<br>sure that busybox doesn't contain bcopy which itself is flagged<br>DEPRECATED<br><br>Same goes for bzero which, too, is deprecated and generates equal size<br>to a plain memset with any reasonable version of gcc anyway. 
</blockquote>
<div>&nbsp;</div>
<div>I noticed that uClibc-0.9.28 does contain a bzero.o under libc/string, which is produced by this rule (libc/string/Makefile):</div>
<div>&nbsp;</div>
<blockquote dir="ltr" style="MARGIN-RIGHT: 0px">
<div>$(MOBJ): $(MSRC)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $(CC) $(CFLAGS) -DL_$* $&lt; -c -o $*.o<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $(STRIPTOOL) -x -R .note -R .comment $*.o</div></blockquote>
<div dir="ltr">/home/qiuyu/buildroot/build_mipsel/staging_dir/bin/mipsel-linux-uclibc-gcc&nbsp; -Wall -Wstrict-prototypes -Wno-trigraphs&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; -fno-strict-aliasing&nbsp; -mips1&nbsp; -fno-builtin -nostdinc -D_LIBC -I../../include -I.&nbsp; -Os&nbsp;&nbsp; -mno-split-addresses -isystem&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /home/qiuyu/buildroot/build_mipsel/staging_dir/lib/gcc-lib/mipsel-linux-uclibc/3.3.5/include -DNDEBUG -fPIC -DL_bcop&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; y 
wstring.c -c -o bcopy.o</div>
<div>&nbsp;</div>
<div>and in wstring.c bzero() is simply implemented via memmove()</div>
<blockquote dir="ltr" style="MARGIN-RIGHT: 0px">
<p>#ifdef L_bcopy</p>
<p>void bcopy(const void *s2, void *s1, size_t n)<br>{<br>#if 1<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; memmove(s1, s2, n);<br>#else<br></p>
<div>...</div>
<div>}</div>
<div>#endif<br>&nbsp;</div></blockquote>
<div dir="ltr">But....if that code means bcopy does implemented in uClibc, how to explain my &quot;<span style="FONT-SIZE: larger">can't resolve symbol bcopy</span>&nbsp;&quot; problem?&nbsp; confused...</div>
<div dir="ltr">&nbsp;</div>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">That said, current busybox trunk doesn't contain bcopy, i don't have a<br>1.2 tarball at hand to see if it's erroneously used there. 
</blockquote>
<div>&nbsp;</div>
<div>&nbsp;</div>
<div>I made a grep search under busybox-1.2.1 but found nothing</div>
<div>&nbsp;</div>
<div><a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:qiuyu@dsarge:~/buildroot/build_mipsel/busybox-1.2.1$" target="_blank">qiuyu@dsarge:~/buildroot/build_mipsel/busybox-1.2.1$</a> grep -nHr bcopy *
<br>61:&nbsp;&nbsp;&nbsp;&nbsp; grep -E -e '\&lt;(bcmp|bcopy|bzero|getwd|index|mktemp|rindex|utimes)\&gt;[[:space:]]*\(' \ <br>&nbsp;</div><br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Only recently one instance of bzero was erroneously added to busybox:<br><a onclick="return top.js.OpenExtLink(window,event,this)" href="http://www.busybox.net/lists/busybox/2006-September/024328.html" target="_blank">
http://www.busybox.net/lists/busybox/2006-September/024328.html</a><br><br>If uClibc was cleaned up properly NOT to provide fallback defines behind<br>your back for e.g. bzero, then you'd have seen a proper compile failure 
<br>(there most likely was an error about a call to &quot;(bcopy)(s,d,sz)&quot;<br>somewhere in your make output anyway...).<br><br>&gt;<br>&gt;I tried to google it, and only got this page &quot;<br>&gt;<a onclick="return top.js.OpenExtLink(window,event,this)" href="http://mailman.uclinux.org/pipermail/uclinux-dev/2006-April/037797.html" target="_blank">
 http://mailman.uclinux.org/pipermail/uclinux-dev/2006-April/037797.html</a>&quot;. I<br>&gt;contacted the guy who sent this message, and he did't find out the cause of<br>&gt;the problem. All he suggests me is to try different version, and maybe 
<br>&gt;change some compiler option.<br>&gt;<br>&gt;But...any body knows why and how to fix it? Please help me out and thanks!<br>&gt;<br>&gt;My buildroot configuration:<br>&gt;<br>&gt;Kernel Headers (Linux 2.4.31 kernel headers)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;-- I'm using Linux 
<br>&gt;2.4.17 to boot the board, can this be a problem?<br>&gt;Binutils Version (binutils 2.16.1)<br>&gt;GCC compiler Version (gcc 3.4.2)<br>&gt;uClibc-0.9.28<br>&gt;busybox-1.2.1<br>&gt;<br>&gt;--<br>&gt;Qiu, Yu<br>&gt;----------------------------------------------------------- 
<br>&gt;<a onclick="return top.js.OpenExtLink(window,event,this)" href="http://www.unibeing.net/" target="_blank">http://www.unibeing.net</a><br>&gt;-----------------------------------------------------------<br><br>&gt;_______________________________________________
<br>&gt;buildroot mailing list <br>&gt;<a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:buildroot@uclibc.org" target="_blank">buildroot@uclibc.org</a><br>&gt;<a onclick="return top.js.OpenExtLink(window,event,this)" href="http://busybox.net/mailman/listinfo/buildroot" target="_blank">
http://busybox.net/mailman/listinfo/buildroot</a><br></blockquote>
<div><br><br clear="all"><br>-- <br>Qiu, Yu<br>-----------------------------------------------------------</div>
<div><a onclick="return top.js.OpenExtLink(window,event,this)" href="http://www.unibeing.net/" target="_blank">http://www.unibeing.net</a></div>
<div>----------------------------------------------------------- </div>