<div>thanks for the reply :).</div>
<div>when i checked the linux src for mips in asm-mips folder PAGE_SIZE was defined only in kernel context.</div>
<div>if __KERNEL__ was defined only then was PAGE_SIZE defined. on the other hand PAGE_SIZE is defined for non kernel context in i386 and arm asm folders. i was able to fix the problem by defining PAGE_SIZE in asm-mips/page.h. that compiled the uClibc-0.9.26, then i compiled full build of gcc-3.3.3 and also was able to run test programs on the ubnt litestation2 mips-4kc board.</div>
<div> isnt there a patch available for doing this the right way? i understand that making changes in the kernel code is not a good idea. is there a fix available for this problem?<br>i would like to post my findings about the toolchain build procedure but not before getting the right solution for this problem.</div>
<div> </div>
<div>regards</div>
<div>abhijit</div>
<div> </div>
<div class="gmail_quote">On Fri, Apr 4, 2008 at 12:37 AM, Filippo ARCIDIACONO <<a href="mailto:filippo.arcidiacono@st.com">filippo.arcidiacono@st.com</a>> wrote:<br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">I suggest you to upgrade the uClibc to the 0.9.29 version.<br>
<div>
<div></div>
<div class="Wj3C7c"><br>> -----Original Message-----<br>> From: <a href="mailto:uclibc-bounces@uclibc.org">uclibc-bounces@uclibc.org</a><br>> [mailto:<a href="mailto:uclibc-bounces@uclibc.org">uclibc-bounces@uclibc.org</a>] On Behalf Of abhijit ayarekar<br>
> Sent: Thursday, April 03, 2008 10:12 PM<br>> To: <a href="mailto:uclibc@uclibc.org">uclibc@uclibc.org</a><br>> Subject: Problems in compiling for mips<br>><br>> I am trying to compile uclibc-0.9.26 with binutils-2.15,<br>
> gcc-3.3.3, kernel headers version 2.4.27<br>><br>> when i run make i get the following error<br>><br>> [root@shastabuild uClibc-0.9.26]# make CROSS=mips-linux-<br>> + ./extra/scripts/fix_includes.sh -k<br>
> + /mnt/hdb/mips-toolchain/kernel/linux-kernel-2.4 -t mips<br>> Current kernel version is 2.4.27-ubnt0<br>><br>> Using kernel headers from 2.4.27-ubnt0 for architecture 'mips'<br>> provided in directory<br>
> /mnt/hdb/mips-toolchain/kernel/linux-kernel-2.4<br>><br>> + TOPDIR=.<br>> + CC=mips-linux-gcc<br>> + /bin/sh extra/scripts/gen_bits_syscall_h.sh<br>> + cmp include/bits/sysnum.h include/bits/sysnum.h.new mv -f<br>
> + include/bits/sysnum.h.new include/bits/sysnum.h<br>> make -C libc/sysdeps/linux/common headers<br>> make[1]: Entering directory<br>> `/mnt/hdb/mips-toolchain/sources/uClibc-0.9.26/libc/sysdeps/li<br>nux/common'<br>
> ln -fs ../libc/sysdeps/linux/common/fpu_control.h<br>> ../../../..//include/<br>> make[1]: Leaving directory<br>> `/mnt/hdb/mips-toolchain/sources/uClibc-0.9.26/libc/sysdeps/li<br>nux/common'<br>> make -C libc/sysdeps/linux/mips headers<br>
> make[1]: Entering directory<br>> `/mnt/hdb/mips-toolchain/sources/uClibc-0.9.26/libc/sysdeps/li<br>nux/mips'<br>> ln -fs ../libc/sysdeps/linux/mips/sgidefs.h<br>> ../../../..//include/ ln -fs<br>> ../libc/sysdeps/linux/mips/fpu_control.h ../../../..//include/<br>
> make[1]: Leaving directory<br>> `/mnt/hdb/mips-toolchain/sources/uClibc-0.9.26/libc/sysdeps/li<br>nux/mips'<br>> make -C ldso<br>> make[1]: Entering directory<br>> `/mnt/hdb/mips-toolchain/sources/uClibc-0.9.26/ldso'<br>
> ln -fs ../../include/elf.h include/<br>> ln -fs ../ldso/mips/boot1_arch.h include/ ln -fs<br>> ../ldso/mips/ld_syscalls.h include/ ln -fs<br>> ../ldso/mips/ld_sysdep.h include/ make -C ldso;<br>> make[2]: Entering directory<br>
> `/mnt/hdb/mips-toolchain/sources/uClibc-0.9.26/ldso/ldso'<br>> mips-linux-gcc -Wall -Wstrict-prototypes -Wno-trigraphs<br>> -fno-strict-aliasing -Os -mno-split-addresses -mips32<br>> -mtune=mips32 -fPIC<br>
> -DUCLIBC_RUNTIME_PREFIX=\"/mnt/hdb/mips-toolchain/mips-linux/\<br>" -fno-builtin -nostdinc -I../../ldso/include -I. -> I../../include<br>> -I/mnt/hdb/mips-toolchain/lib/gcc-lib/mips-linux/3.3.3/include<br>
> -I../libdl -c ldso.c -o ldso.o In file included from<br>> _dl_progname.h:2,<br>> from ldso.c:156:<br>> mips/elfinterp.c: In function `_dl_parse_relocation_information':<br>> mips/elfinterp.c:177: warning: unused variable `old_val'<br>
> ldso.c: In function `_dl_boot2':<br>> ldso.c:362: error: `PAGE_SIZE' undeclared (first use in this function)<br>> ldso.c:362: error: (Each undeclared identifier is reported only once<br>> ldso.c:362: error: for each function it appears in.)<br>
> ldso.c:454:2: warning: #warning "Debugging threads on mips<br>> won't work till someone fixes this..."<br>> ../../ldso/include/ld_syscall.h:56: warning: use of memory<br>> input without lvalue in asm operand 7 is deprecated In file<br>
> included from ldso.c:1343:<br>> readelflib1.c: In function `_dl_load_elf_shared_library':<br>> readelflib1.c:452: error: `PAGE_SIZE' undeclared (first use<br>> in this function) In file included from ldso.c:1343:<br>
> ../../ldso/include/ld_syscall.h:56: warning: use of memory<br>> input without lvalue in asm operand 7 is deprecated<br>> ../../ldso/include/ld_syscall.h:56: warning: use of memory<br>> input without lvalue in asm operand 7 is deprecated<br>
> ../../ldso/include/ld_syscall.h:56: warning: use of memory<br>> input without lvalue in asm operand 7 is deprecated<br>> ../../ldso/include/ld_syscall.h:56: warning: use of memory<br>> input without lvalue in asm operand 7 is deprecated<br>
> ../../ldso/include/ld_syscall.h:56: warning: use of memory<br>> input without lvalue in asm operand 7 is deprecated<br>> readelflib1.c: In function `_dl_dprintf':<br>> readelflib1.c:787: error: `PAGE_SIZE' undeclared (first use<br>
> in this function) In file included from ldso.c:1343:<br>> ../../ldso/include/ld_syscall.h:56: warning: use of memory<br>> input without lvalue in asm operand 7 is deprecated In file<br>> included from ldso.c:1343:<br>
> readelflib1.c: In function `_dl_malloc':<br>> readelflib1.c:886: error: `PAGE_SIZE' undeclared (first use<br>> in this function) In file included from ldso.c:1343:<br>> ../../ldso/include/ld_syscall.h:56: warning: use of memory<br>
> input without lvalue in asm operand 7 is deprecated<br>> ../../ldso/include/ld_syscall.h: In function `_dl_mmap':<br>> ../../ldso/include/ld_syscall.h:56: warning: use of memory<br>> input without lvalue in asm operand 7 is deprecated<br>
> make[2]: *** [ldso.o] Error 1<br>> make[2]: Leaving directory<br>> `/mnt/hdb/mips-toolchain/sources/uClibc-0.9.26/ldso/ldso'<br>> make[1]: *** [all] Error 2<br>> make[1]: Leaving directory<br>> `/mnt/hdb/mips-toolchain/sources/uClibc-0.9.26/ldso'<br>
> make: *** [_dir_ldso] Error 2<br>><br>> can anyone please help me solve this problem?<br>><br>> regards<br>> abhijit<br>><br>><br><br></div></div></blockquote></div><br>