This is the mail archive of the libc-help@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

What causes sysdeps/mips/preconfigure to be sourced?


Hi all. I'm trying to build a mips cross compiler on an x86_64 build system, and I am running into an error; I've investigated as far as I can but am at a loss to understand how the configure process is supposed to work in this scenario.

I am using these arguments to glibc configure:

CFLAGS='-mips32 -mtune=5kf -mbranch-likely -Wa,--trap -O2'
--build=x86_64-unknown-linux-gnu
--host=mips-unknown-linux-gnu
--prefix=/home/bji/buildtools/output/install/stage1/mips-unknown-linux-gnu/usr
--with-headers=/home/bji/buildtools/output/sources/kernel/mips
--disable-shared
--disable-executables

(--disable-executables is an addition that I have made to the glibc configure and Makefiles to disable the building of any executables; this allows a multi-stage bootstrapping of gcc and glibc to proceed using a simpler and (I believe) more logical process than other bootstrapping procedures I have read about)

In file included from ../sysdeps/mips/libc-tls.c:20:0:
../csu/libc-tls.c: In function '__libc_setup_tls':
../csu/libc-tls.c:194:3: warning: implicit declaration of function 'INTERNAL_SYSCALL_DECL' [-Wimplicit-function-declaration]
../csu/libc-tls.c:194:25: error: 'err' undeclared (first use in this function)
../csu/libc-tls.c:194:25: note: each undeclared identifier is reported only once for each function it appears in
../csu/libc-tls.c:194:3: warning: implicit declaration of function 'INTERNAL_SYSCALL' [-Wimplicit-function-declaration]
../csu/libc-tls.c:194:25: error: 'set_thread_area' undeclared (first use in this function)
../csu/libc-tls.c:194:3: warning: implicit declaration of function 'INTERNAL_SYSCALL_ERROR_P' [-Wimplicit-function-declaration]
make[2]: *** [/home/bji/buildtools/output/build/stage1/mips-TiVo-linux-gnu/glibc/csu/libc-tls.o] Error 1
make[2]: Leaving directory `/home/bji/buildtools/output/sources/glibc/csu'
make[1]: *** [csu/subdir_lib] Error 2
make[1]: Leaving directory `/home/bji/buildtools/output/sources/glibc'


INTERNAL_SYSCALL_DECL is undefined; it should be being pulled in, I believe, from this glibc source file:

sysdeps/unix/sysv/linux/mips/mips32/sysdep.h

This header file is not being included. I don't understand why not.

I believe that this header file is included if the configure script detects that the mips32 sysdeps should be included. I haven't found any logic in the configure script that would cause mips32 to be included; but I have found this file which looks like it would cause mips32 to be included:

sysdeps/mips/preconfigure

This script very clearly looks like it establishes mips32 in the set of machine types to use when detecting sysdeps to use.

However, this script is not being sourced by the configure script for glibc.

How do I get this script to be sourced by glibc's configure script? I notice that there is logic surrounding a variable named "$libc_add_on" but I don't understand how to make that variable work. The configure script looks like it wants to find preconfigure scripts at:

$srcdir/$libc_add_on/sysdeps/*/preconfigure

but that won't find a preconfigure script at:

$srcdir/sysdeps/mips/preconfigure

In fact I grep'd every file in the glibc source distribution for the word 'preconfigure' but this use in the configure script is the only place I can even see it being referenced.

I should mention that I am trying to build glibc version 2.13 with glibc-ports-2.13.

Thanks!
Bryan


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]