LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Kernel (https://www.linuxquestions.org/questions/linux-kernel-70/)
-   -   glibc compilation failure (https://www.linuxquestions.org/questions/linux-kernel-70/glibc-compilation-failure-927553/)

ramendra 02-04-2012 06:17 AM

glibc compilation failure
 
I am trying to configure environment for glibc (glibc-2.5-20061008T1257) compilation.

[root@IT23 build]# ../configure
checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
configure: running configure fragment for add-on build
checking build system type... (cached) i686-pc-linux-gnu
checking host system type... (cached) i686-pc-linux-gnu
configure: running configure fragment for add-on build
checking build system type... (cached) i686-pc-linux-gnu
checking host system type... (cached) i686-pc-linux-gnu
configure: running configure fragment for add-on build
checking build system type... (cached) i686-pc-linux-gnu
checking host system type... (cached) i686-pc-linux-gnu
configure: running configure fragment for add-on build
checking build system type... (cached) i686-pc-linux-gnu
checking host system type... (cached) i686-pc-linux-gnu
configure: running configure fragment for add-on build
checking build system type... (cached) i686-pc-linux-gnu
checking host system type... (cached) i686-pc-linux-gnu
configure: running configure fragment for add-on build

My system is :
[root@IT23 build]# uname -a
Linux IT23 2.6.18-274.el5xen #1 SMP Fri Jul 22 06:14:51 EDT 2011 i686 athlon i386 GNU/Linux
[root@IT23 build]# ld -v
GNU ld version 2.17.50.0.6-14.el5 20061020

Please help me if I have to cross check my compilation Environment or any other changes needed.

John VV 02-05-2012 01:06 AM

a question
why are you building a different libc on this ( el5) red hat 5 based system
and a VERY old one at that
the kernel and glibc ARE the operating system

if you build a different glibc you will have to build the entire operating system from scratch
and the current software will not be able to use a glibc form 2006 ( 6 years out of date)

Quote:

Please help me if I have to cross check my compilation Environment or any other changes needed.
try EVERY and ALL program ever installed will NEED to be rebuilt from scratch and using such an old glibc might not even work

It is a almost 99% certainty you will completely mess up this unknown version of something based on rhel5

ramendra 02-06-2012 11:55 PM

Hi,

Thanks for your support and prompt Response. I am not able to find the cause for "configure: running configure fragment for add-on build" . We are doing R&D for porting glibc for MIPS but prior to that we are just trying to compile it normally and facing this issue while configuring the compilation Environment.Cross compilation for MIPS will be done after this step.

Is there any better way to doing it .

Regards
Ramendra

knudfl 02-07-2012 04:41 AM

A glibc for MIPS can be found here
http://packages.debian.org/lenny/libc6
> libc6-2.7, created from glibc-2.7 :
> http://ftp.se.debian.org/debian/pool...enny7_mips.deb


Cross compiling glibc http://trac.cross-lfs.org/
>>> http://cross-lfs.org/view/1.1.0/x86/
> glibc > http://cross-lfs.org/view/1.1.0/x86/...tem/glibc.html
Be aware that ...
glibc requires a build directory outside the glibc-2.x/ source directory.
.

ramendra 02-15-2012 01:44 AM

I am trying to configure my Environment for cross compilation of glib-1.2.10 with following command:

./configure --host=i686-pc-linux-gnu --target=mips64-nlm-linux- --prefix= --enable-add-ons

I am getting following output in config.log file. What could be the problem and how can I debug and proceed further.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
configure:634: checking for a BSD compatible install
configure:687: checking whether build environment is sane
configure:744: checking whether make sets ${MAKE}
configure:783: checking for working aclocal
configure:796: checking for working autoconf
configure:809: checking for working automake
configure:822: checking for working autoheader
configure:835: checking for working makeinfo
configure:951: checking host system type
configure:972: checking build system type
configure:992: checking for ranlib
configure:1022: checking for gcc
configure:1135: checking whether the C compiler (mips64-nlm-elf-gcc ) works
configure:1151: mips64-nlm-elf-gcc -o conftest conftest.c 1>&5
/home/ramendra/sdk2.2/sdk-base/toolchains_bin/mipscross/elf/bin/../lib/gcc/mips64-nlm-elf/4.4.5/../../../../mips64-nlm-elf/bin/as: Symbol `mips_builtin_opcodes' has different size in shared object, consider re-linking
mips64-nlm-elf-gcc: Internal error: Segmentation fault (program as)

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

theNbomr 02-17-2012 10:44 AM

If you are going to do cross development, you will need a cross toolchain (compiler, libc, lots of other stuff) that runs on your build host and creates binaries to run on your target host. Don't even consider trying to do this yourself; there are way too many problems to solve. The good news is that Crosstool-NG has already solved most or all of them. It is a mature package, currently maintained, and supported by an active mailing list.
As John VV correctly points out, failing to do things properly will not only result in a non-working cross compiler, but may corrupt your development host beyond repair.
--- rod.


All times are GMT -5. The time now is 09:08 PM.