Bug 155

Summary: uClibc 0.9.28.3 fails to build
Product: buildroot Reporter: Luke <luke_tucker>
Component: Outdated packageAssignee: unassigned
Status: RESOLVED WONTFIX    
Severity: normal CC: buildroot
Priority: P5    
Version: unspecified   
Target Milestone: 2010.02   
Hardware: PC   
OS: Linux   
Host: openSuSE 11.1 Target: mipsel TViX DVICO m-6500
Build:

Description Luke 2009-03-07 23:27:09 UTC
When building the default configuration with the following differences:
mipsel
-obsolete options on
-gcc 4.0.4
-binutils 2.18
-uClibc 0.9.28.3
-kernel-headers 2.6.20.4

The following build error occurs in uClibc:
make[5]: Entering directory `/home/luke/buildroot/toolchain_build_mipsel/uClibc-0.9.28.3/libc/sysdeps/linux/mips'
/home/luke/buildroot/build_mipsel/staging_dir/usr/bin/mipsel-linux-uclibc-gcc  -Wall -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing  -mips1  -fno-builtin -nostdinc -D_LIBC -I../../../../include -I.  -Os -funit-at-a-time  -mno-split-addresses -isystem /home/luke/buildroot/build_mipsel/staging_dir/bin/../lib/gcc/mipsel-linux-uclibc/4.0.4/include -DNDEBUG -fPIC  -c clone.S -o clone.o
clone.S:27:21: error: asm/asm.h: No such file or directory
make[5]: *** [clone.o] Error 1
make[5]: Leaving directory `/home/luke/buildroot/toolchain_build_mipsel/uClibc-0.9.28.3/libc/sysdeps/linux/mips'
make[4]: *** [mips] Error 2
make[4]: Leaving directory `/home/luke/buildroot/toolchain_build_mipsel/uClibc-0.9.28.3/libc/sysdeps/linux'
make[3]: *** [_dir_linux] Error 2
make[3]: Leaving directory `/home/luke/buildroot/toolchain_build_mipsel/uClibc-0.9.28.3/libc/sysdeps'
make[2]: *** [_dir_sysdeps] Error 2
make[2]: Leaving directory `/home/luke/buildroot/toolchain_build_mipsel/uClibc-0.9.28.3/libc'
make[1]: *** [_dir_libc] Error 2
make[1]: Leaving directory `/home/luke/buildroot/toolchain_build_mipsel/uClibc-0.9.28.3'
make: *** [/home/luke/buildroot/toolchain_build_mipsel/uClibc-0.9.28.3/lib/libc.a] Error 2
Comment 1 Luke 2009-03-08 00:02:52 UTC
I looked at 0.9.29 and found an easy patch:

--- uClibc-0.9.28.3/libc/sysdeps/linux/mips/clone.S.orig        2009-03-08 01:00:30.000000000 +0100
+++ uClibc-0.9.28.3/libc/sysdeps/linux/mips/clone.S     2009-03-08 01:01:06.000000000 +0100
@@ -24,7 +24,7 @@
 #include <sys/regdef.h>
 #define _ERRNO_H       1
 #include <bits/errno.h>
-#include <asm/asm.h>
+#include <sys/asm.h>

 /* int clone(int (*fn)(void *arg), void *child_stack, int flags, void *arg) */

Comment 2 Luke 2009-03-08 00:22:35 UTC
Ooops, I jumped the gun a bit. The asm directory also needs patching in the following files.


--- uClibc-0.9.28.3/libc/sysdeps/linux/mips/pipe.S.orig 2009-03-08 01:15:35.000000000 +0100
+++ uClibc-0.9.28.3/libc/sysdeps/linux/mips/pipe.S      2009-03-08 01:16:35.000000000 +0100
@@ -3,9 +3,9 @@
 /*see uClibc's sh/pipe.c and glibc-2.2.4's mips/pipe.S */

 #include <features.h>
-#include <asm/asm.h>
+#include <sys/asm.h>
 #include <asm/unistd.h>
-#include <asm/regdef.h>
+#include <sys/regdef.h>

         .globl  pipe
         .ent    pipe, 0
--- uClibc-0.9.28.3/libc/sysdeps/linux/mips/syscall.S.orig      2009-03-08 01:07:34.000000000 +0100
+++ uClibc-0.9.28.3/libc/sysdeps/linux/mips/syscall.S   2009-03-08 01:09:24.000000000 +0100
@@ -17,8 +17,8 @@
    02111-1307 USA.  */

 #include <features.h>
-#include <asm/asm.h>
-#include <asm/regdef.h>
+#include <sys/asm.h>
+#include <sys/regdef.h>

 #ifdef __PIC__
        .option pic2
Comment 3 Thomas Petazzoni 2009-08-07 17:23:01 UTC
I would suggest to add http://lists.busybox.net/pipermail/uclibc-cvs/2006-September/023471.html to our list of patches, or to remove support for the obsolete 0.9.28.3 version of uClibc.
Comment 4 Thomas Petazzoni 2010-04-09 14:45:49 UTC
uClibc 0.9.28 is deprecated, so I'm closing this bug. If you ever have an issue with a more recent version (0.9.30 or 0.9.31), do not hesitate to open another bug. Thanks!