This is the mail archive of the crossgcc@sourceware.org mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


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

RE: missing <sys/ucontext.h> header file for SH3 build


Robert P. J. Day wrote:
>   here's one example of what i've found related to the necessity of
> having to install the glibc header files, at least for a specific
> architecture.
> 
>   if i try to build a toolchain for sh3 *without* installing the glibc
> header files, the build of the bootstrap gcc fails with:

> -fexceptions  -c /home/rpjday/unpack/gcc-4.1-20051029/gcc/unwind-dw2.c
> -o libgcc/./unwind-dw2.o
> In file included from
> /home/rpjday/unpack/gcc-4.1-20051029/gcc/unwind-dw2.c:256:
> /home/rpjday/unpack/gcc-4.1-20051029/gcc/config/sh/linux-unwind.h:32:20:
> error: signal.h: No such file or directory
> /home/rpjday/unpack/gcc-4.1-20051029/gcc/config/sh/linux-unwind.h:33:26:
> error: sys/ucontext.h: No such file or directory
> 
> 
>   sure enough, the file gcc-4.1-.../gcc/config/sh/linux-unwind.h
> contains the include directive:
> 
>   #include <sys/ucontext.h>

  In your mini-crosstool script, you're configuring the bootstrap compiler
with

	${GCC_SRC_DIR}/configure \
		--host=${HOST} \
		--target=${TARGET} \
		--prefix=${CORE_PREFIX} \
		--with-local-prefix=${SYSROOT_DIR} \
		--with-sysroot=${SYSROOT_DIR} \
		--disable-multilib \
		--with-newlib \
		--disable-nls \
		--disable-shared \
		--enable-threads=yes \
		--enable-symvers=gnu \
		--enable-__cxa_atexit \
		--enable-languages=c

  I don't understand on what basis you chose all these options and the values
you've assigned to them.  I'm used to configuring and building bootstrap
compilers with a far more minimal set of options, something like


	${GCC_SRC_DIR}/configure \
		--host=${HOST} \
		--target=${TARGET} \
		--prefix=${CORE_PREFIX} \
		--with-newlib \
		--without-headers --without-libs --with-gnu-as --with-gnu-ld \
		--enable-languages=c

  In particular, it seems *very* plausible to me that the
"--enable-__cxa_atexit" option, which is something to do with termination
handlers, might very well be responsible for pulling in the dwarf unwinder, so
if I was going to suspect just one thing, I'd try changing that to
"--disable-__cxa_atexit" first off.


    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....


------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com


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