Skip to main content
Topic solved
This topic has been marked as solved and requires no further attention.
Topic: [SOLVED] LFS-11.3 (Read 736 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

[SOLVED] LFS-11.3

  I was pleased when binutils installed as step 1 of the independent toolchain you need to build LFS.  Next gcc, kernel-headers and glibc.  Fall at the next hurdle - gcc builds but then an error occurs  "checking for CET support: configure error: link tests are not allowed after GCC_NO_EXECUTABLES ".  Build options included "without-headers, --newlib,  --with-sysroot=[new lfs partition], --with-prefix=[toolchain root] --with-target=x86_64-lfs-linux-gnu --disable-shared" and disable a lot of other things,  copied verbatim from LFS 11.3 book.

  If I could change configure to check for CET support without using link tests, that would be nice; or just disable CET.  For some reason binutils installed into [toolchain root]/x86_64-pc-linux-gnu instead of x86_64-lfs-linux-gnu, as specified.  I renamed it and made a symlink to point ldscripts correctly but gcc configure was unimpressed.

  Any ideas appreciated.

Re: LFS-11.3

Reply #1
First building an LFS system is a good thing to do educationally imho.

But here is probably not the best place to ask about problems as those of us who have done it probably did so some time ago.

There are mailing lists you can sign up to.
https://lists.linuxfromscratch.org/sympa/info/lfs-support amongst others.
I took advantage of them at the time I built mine.

There is a forum which seems reasonably active here https://www.linuxquestions.org/questions/linux-from-scratch-13/
I'm not saying don't ask here. Just ask there as well. For likely better quality responses.

Also the toolchain is very important. That needs to be got right or I suspect you'll have many problems ahead. No hacks or winging it.

Good luck

Re: LFS-11.3

Reply #2
  Thanks for these links, gzipped, and I have been to the Linux Questions one but it wasn't very helpful.  I'll investigate the other one now.  Appreciate it, thx.

Re: LFS-11.3

Reply #3
  Tried it without --enable-default-ssp and it built on my desktop but on my laptop ran into libcp1plugin - "no include path found in which to search for stdc-predef".  I guess it isn't easy to build gcc with nothing but binutils to support it.  Apparently you could put binutils in the gcc source tree but whether a second build would lead to any improved functionality I have no idea.  Perhaps after the first binutils install I could put something in the environment to point to the include directory, CPATH perhaps.  Doesn't say in the book, though.
 

Re: LFS-11.3

Reply #4
  Setting CPATH to include dir installed by binutils helped so I also set LD_LIBRARY_PATH to libs installed by binutils but now I get "cannot compute suffix for object files" when conftest fails in libgcc build.  Apparently this often happens when gmp. mpfr, mpc are not in place before gcc but that's the LFS book procedure.

Re: LFS-11.3

Reply #5
  Seems to be a matter of updating CPATH, LD_LIBRARY_PATH etc when new functionality is available.  Binutils and GCC installed fine following the book so I'll mark thread solved.

 

Re: [SOLVED] LFS-11.3

Reply #6
tried it some years ago.  was able to build without errors but then my kernel wouldnt boot.  don't know if i have the gumption to try again.  best of luck to you though!
Cat Herders of Linux