Unable to build uClibc with _FILE_OFFSET_BITS=64

Bernhard Reutner-Fischer rep.dot.nop at gmail.com
Wed Jan 9 11:50:05 UTC 2013


On 9 January 2013 11:12,  <mail-an-mw123 at gmx.de> wrote:
>> > If I force definition of the _FILE_OFFSET_BITS flag in file
>> include/features.h I get the following error:
>>
>> This is not how you are supposed to turn on LFS.
> It was just a test because simply turn on LFS does not define _FILE_OFFSET_BITS.
>
>> >
>> > ######################################
>> > # build uClibc                       #
>> > ######################################
>> > make -C lib/uClibc/ -f Makefile
>>
>> please show me that Makefile or the relevant parts of it.
> I've attached the makefiles in the uClibc root folder.

ah, i see. Those are the makefiles of uClibc, so they are not interesting.
>
>>
>> Can you try to build uClibc manually, like:
>>
>> $ git clone -q git://git.uClibc.org/uClibc.git /tmp/uClibc
>> $ cd !$
>> cd /tmp/uClibc
>> $ make CROSS_COMPILE=mips-linux-gnu- ARCH=mips
>> (or however your program prefix looks like)
> Yields the following:
>
> /tmp/uClibc$ make CROSS_COMPILE=mipsel-linux- ARCH=mipsel all
>   MKDIR include/bits
>   GEN include/bits/uClibc_config.h
>   LN include/sgidefs.h
>   ... [more LN following]
>   LN include/sys/user.h
>   GEN include/bits/sysnum.h
>   MKDIR lib
>   AS lib/crt1.o
>   AS lib/Scrt1.o
> libc/sysdeps/linux/mips/crt1.S: Assembler messages:
> libc/sysdeps/linux/mips/crt1.S:116: Warning: No .cprestore pseudo-op used in PIC code
>   AS lib/crti.o
>   AS lib/crtn.o
>   CC ldso/ldso/ldso.oS
>   AS ldso/ldso/mips/resolve.oS
> ldso/ldso/mips/resolve.S: Assembler messages:
> ldso/ldso/mips/resolve.S:151: Warning: No .cprestore pseudo-op used in PIC code
>   AR cr ldso/ldso/ld-uClibc_so.a
>   STRIP -x -R .note -R .comment ldso/ldso/ld-uClibc_so.a
>   LD ld-uClibc-0.9.34-git.so
> collect2: ld terminated with signal 11 [Segmentation fault]
> /opt/BCM/stbgcc-4.5.3-2.4/bin/../lib/gcc/mipsel-linux-uclibc/4.5.3/../../../../mipsel-linux-uclibc/bin/ld: ldso/ldso/ld-uClibc_so.a(ldso.oS): compiled for a little endian system and target is big endian

You either have to use mips for big-endian or mipsel for
little-endian. You seem to have a mix of endian configured in uClibc
and the default of your compiler.
If the latter, put either -EL or -EB into UCLIBC_EXTRA_CFLAGS of your
.config (and please show me what you set for UCLIBC_EXTRA_CFLAGS).


More information about the uClibc mailing list