This is the mail archive of the crossgcc@sources.redhat.com 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]

ToolChain building Problem


Respected Sir,
I am vipin Sharma working in software development company based in INDIA. We
are currently porting linux kernel 2.4.19 on SH7727 based board.
I am trying to build Toolchain for that but i m facing some problem
I followed following steps

bintutils:
$ ../binutils-2.11.2/configure --prefix=$PREFIX --target=$TARGET
$ make
$ make install
gcc-bootstrap:
$ ../gcc-3.0.3/configure --prefix=$PREFIX --target=$TARGET --with-newlib \
  --enable-languages="c" --disable-shared
$ make all-gcc
$ make install-gcc
glibc:

# First you need to create a "configparms" (mind the spelling) file, and
# place it in your glibc build directory:
  CFLAGS := -ml -m3 -O $(CFLAGS)
  ASFLAGS-.o := -ml
  LDFLAGS-relocatable := -ml
  crts-predefined=yes
  build-programs=no
  CC=sh3-linux-gcc -ml -m3
  RANLIB=sh-linux-ranlib
  AS=sh3-linux-gcc -ml
  LD=sh3-linux-ld -ml
  AR=sh3-linux-ar
  BUILD_CC=gcc

# The -ml -m3 flags are redundant if you use the `sh3-linux' target, but I
# left them in there in case you build `sh-unknown-linux'.

# Next set the path to your kernel headers:
# $HEADERS=/path/to/kernel/include

$ CC="sh3-linux-gcc -ml -m3" ../glibc-2.2.5/configure -host=$TARGET \
  --build=`arch`-linux --disable-debug --disable-profile \
  --with-headers=$HEADERS --prefix=$PREFIX --enable-add-ons \
  --disable-sanity-checks
$ make
$ touch iconv/iconv_prog login/pt_chown
$ make install_root=$PREFIX/$TARGET prefix="" install

# Because you don't have SH3 glibc shared libraries in /lib on your host
# system, you need to make a quick edit:
$ echo GROUP \( libc.so.6 libc_nonshared.a \) > $PREFIX/$TARGET/lib/libc.so

# You should now be able to compile normal C programs and have them execute
# on your target machine.

# Finally you can build the complete GCC toolchain
gcc-final:
$ ../gcc-3.0.3/configure --prefix=$PREFIX --target=$TARGET \
  --enable-languages="c,c++"
$ make
$ make install

till gcc-final everything goes smooth but in gcc-final step i am getting
following problem
checking whether the C compiler
(/home/knitterb/linuxce/src/build-gcc/gcc/xgcc -B/home/knitterb/linuxce/src/
build-gcc/gcc/ -B/home/knitterb/linuxce/root/sh-linux/bin/ -B/home/knitterb/
linuxce/root/sh-linux/lib/ -isystem
/home/knitterb/linuxce/root/sh-linux/include -g -O2 ) works... no
configure: error: installation or configuration problem: C compiler cannot
create executables.

Please guide me on this or If there is any other way of doing the same then
let me know.
Thanks in advance.



Regards
Vipin




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


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