Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
08-12-2008, 12:23 AM
|
#1
|
LQ Newbie
Registered: Oct 2007
Posts: 10
Rep:
|
6.12. GCC-4.1.2 make error.
Hello all, I'm currently stuck on: Linux From Scratch - Version 6.3,
Chapter 6. Installing Basic System Software, 6.12. GCC-4.1.2
I received the following make error while executing the make command. Also, I'm using Ubuntu as my host.
NOTE:I deleted both the gcc-4.1.2 and gcc-build folders. Then extracted and created the gcc-build folder again.
In file included from ../../gcc-4.1.2/gcc/crtstuff.c:68:
../../gcc-4.1.2/gcc/tsystem.h:90:19: error: stdio.h: No such file or directory
../../gcc-4.1.2/gcc/tsystem.h:93:23: error: sys/types.h: No such file or directory
../../gcc-4.1.2/gcc/tsystem.h:96:19: error: errno.h: No such file or directory
../../gcc-4.1.2/gcc/tsystem.h:103:20: error: string.h: No such file or directory
../../gcc-4.1.2/gcc/tsystem.h:104:20: error: stdlib.h: No such file or directory
../../gcc-4.1.2/gcc/tsystem.h:105:20: error: unistd.h: No such file or directory
In file included from /usr/local/include/limits.h:27,
from /sources/gcc-build/./gcc/include/limits.h:122,
from /sources/gcc-build/./gcc/include/syslimits.h:7,
from /sources/gcc-build/./gcc/include/limits.h:11,
from ../../gcc-4.1.2/gcc/tsystem.h:108,
from ../../gcc-4.1.2/gcc/crtstuff.c:68:
/usr/local/include/features.h:323:25: error: sys/cdefs.h: No such file or directory
In file included from /usr/local/include/features.h:346,
from /usr/local/include/limits.h:27,
from /sources/gcc-build/./gcc/include/limits.h:122,
from /sources/gcc-build/./gcc/include/syslimits.h:7,
from /sources/gcc-build/./gcc/include/limits.h:11,
from ../../gcc-4.1.2/gcc/tsystem.h:108,
from ../../gcc-4.1.2/gcc/crtstuff.c:68:
/usr/local/include/gnu/stubs.h:4:27: error: bits/wordsize.h: No such file or directory
/usr/local/include/gnu/stubs.h:11:3: error: #error "unexpected value for __WORDSIZE macro"
In file included from /sources/gcc-build/./gcc/include/limits.h:122,
from /sources/gcc-build/./gcc/include/syslimits.h:7,
from /sources/gcc-build/./gcc/include/limits.h:11,
from ../../gcc-4.1.2/gcc/tsystem.h:108,
from ../../gcc-4.1.2/gcc/crtstuff.c:68:
/usr/local/include/limits.h:145:30: error: bits/posix1_lim.h: No such file or directory
/usr/local/include/limits.h:149:30: error: bits/posix2_lim.h: No such file or directory
In file included from /usr/local/include/limits.h:153,
from /sources/gcc-build/./gcc/include/limits.h:122,
from /sources/gcc-build/./gcc/include/syslimits.h:7,
from /sources/gcc-build/./gcc/include/limits.h:11,
from ../../gcc-4.1.2/gcc/tsystem.h:108,
from ../../gcc-4.1.2/gcc/crtstuff.c:68:
/usr/local/include/bits/xopen_lim.h:34:28: error: bits/stdio_lim.h: No such file or directory
In file included from ../../gcc-4.1.2/gcc/crtstuff.c:68:
../../gcc-4.1.2/gcc/tsystem.h:111:18: error: time.h: No such file or directory
../../gcc-4.1.2/gcc/crtstuff.c:92:18: error: link.h: No such file or directory
make[2]: *** [crtbegin.o] Error 1
make[2]: Leaving directory `/sources/gcc-build/gcc'
make[1]: *** [all-gcc] Error 2
make[1]: Leaving directory `/sources/gcc-build'
make: *** [all] Error 2
Last edited by rcg1984; 08-12-2008 at 12:30 AM.
|
|
|
08-12-2008, 01:11 AM
|
#2
|
Senior Member
Registered: Jun 2008
Posts: 2,529
Rep:
|
You are missing the basic libc header files. They are pretty important!
|
|
|
08-12-2008, 01:12 AM
|
#3
|
Senior Member
Registered: Jun 2008
Posts: 2,529
Rep:
|
duplicate post -- sorry.
Last edited by Mr. C.; 08-12-2008 at 01:27 AM.
|
|
|
08-12-2008, 01:31 AM
|
#4
|
LQ Newbie
Registered: Oct 2007
Posts: 10
Original Poster
Rep:
|
Quote:
Originally Posted by Mr. C.
You are missing the basic libc header files. They are pretty important!
|
Well, before configuring gcc I ran the following commands:
sed -i 's/install_to_$(INSTALL_DEST) //' libiberty/Makefile.in
sed -i 's/^XCFLAGS =$/& -fomit-frame-pointer/' gcc/Makefile.in
sed -i 's@\./fixinc\.sh@-c true@' gcc/Makefile.in
sed -i 's/@have_mktemp_command@/yes/' gcc/gccbug.in
mkdir -v ../gcc-build
cd ../gcc-build
Finally within the gcc-build directory I ran:
../gcc-4.1.2/configure --prefix=/usr \
--libexecdir=/usr/lib --enable-shared \
--enable-threads=posix --enable-__cxa_atexit \
--enable-clocale=gnu --enable-languages=c,c++
Am I still missing the libc header files? If so, how do I get them(what chapter do I need to reread)?
Last edited by rcg1984; 08-12-2008 at 01:32 AM.
|
|
|
08-12-2008, 01:46 AM
|
#5
|
LQ Newbie
Registered: Oct 2007
Posts: 10
Original Poster
Rep:
|
Quote:
Originally Posted by Mr. C.
You are missing the basic libc header files. They are pretty important!
|
Sweet! I just found out my mistake. I kept reinstating the specs patch to gcc and tried to make.. I left out the patch and it worked. On to make -k check :-)
-Thanks,
Rich
|
|
|
08-12-2008, 01:59 AM
|
#6
|
Senior Member
Registered: Jun 2008
Posts: 2,529
Rep:
|
I don't know the procedure you are following, sorry. I can only tell you what the errors mean.
The system includes are normally found in /usr/include, and are pulled in from source code as :
#include <errno.h>
#include <sys/types.h>
...
But when you are bootstrap building a system, the base directory can be changed, such as /usr/local/include so that you don't destroy your current system's build environment.
I see references to /usr/local/include/limits.h, etc. so there is something incorrect about how either include fixups were done or with specifying the base include directory. Try to backtrack the procedure to see where include files are generated, installed, or the build environment modified to use non-default includes ( I see one reference to removing fixinc.sh from Makefile.in, but again, I don't know the procedure you are working from ).
|
|
|
All times are GMT -5. The time now is 05:57 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|