This is the mail archive of the
mailing list for the GCC project.
Would you like to give me advice about how to compile gcc?
- From: "L.Yan" <g_lqyan at stu dot edu dot cn>
- To: gcc at gcc dot gnu dot org
- Date: Sat, 27 Oct 2007 19:49:36 +0800
- Subject: Would you like to give me advice about how to compile gcc?
I want to build the source of gcc and make '-msoft-float' available. But
I don't know how to build the source code. I just do it as the following
1. download the source code, gcc-4.1.2.tar.gz, from the mirror site;
2. tar -xzf gcc-4.1.2.tar.gz;
3. ./configure --prefix=/home/user/gcc4.1.2/install
4. make CFLAGS='-O' LIBCFLAGS='-g -O2' LIBCXXFLAGS='-g -O2
-fno-implicit-templates -msoft-float' bootstrap
5. make install
Finally, I use the above gcc to compile a test program
/home/user/gcc4.1.2/install/bin/gcc -msoft-float test.c -o test
but there are errors :
/tmp/ccWjy9Ug.o: In function `main':
test.c:(.text+0x2f): undefined reference to `__floatsidf'
test.c:(.text+0x55): undefined reference to `__adddf3'
test.c:(.text+0x61): undefined reference to `__fixdfsi'
collect2: ld returned 1 exit status
Would you like to tell me how to configure and compile GCC, and then I
could use the '-msoft-float' flag.
Any suggestions from you are appreciated.