OK thanks again Ken, I did see that mentioned in 5.3 and had been deleting source dirs as I go, but when I saw the error and related paths it reminded me of building libstdc++v3 already, and I thought maybe I could leave that built in $LFS/sources/gcc-8.2.0/build so that it wouldn't get "unnecessarily"
compiled again. Now I realise it must be necessary to rebuild it.

Anyway thanks I will give it another go! ;-)

On 28/12/2018 3:08 pm, Ken Moffat wrote:
On Fri, Dec 28, 2018 at 02:21:18PM +1100, Kent Cooper wrote:
So now I'm on chapter 5.10 of book version 8.3, trying to build the second
pass of GCC but I keep running into the same errors after 3 complete
restarts. I can
get up to 5.9 without a hitch, but there is one major thing I don't
understand:

Is it imperative to delete $LFS/sources/gcc-8.2.0 after completing chapter
5.8? Or should it be left there so that libstdc++-v3 doesn't need to be
recompiled?

Yes, it is imperative to delete the source before that package is
next used.  Delete it at the end o each page, after making sure you
have run all the commands on that page.

It's mentioned in section 5.3.
If I delete it, I get roughly 1.5 hours into chapter 5.10 before I encounter
the same problem described here 
<http://lists.linuxfromscratch.org/pipermail/lfs-support/2015-August/048881.html>:

checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for x86_64-pc-linux-gnu-gcc...
/mnt/lfs/sources/gcc-8.2.0/gcc/xgcc -B/mnt/lfs/sources/gcc-8.2.0/gcc/
-B/tools/x86_64-pc-linux-gnu/bin/ -B/tools/x86_64-pc-linux-gnu/lib/
-isystem /tools/x86_64-pc-linux-gnu/include -isystem
/tools/x86_64-pc-linux-gnu/sys-include   checking for C compiler default
output file name... a.out
checking whether the C compiler works... configure: error: in 
`/mnt/lfs/sources/gcc-8.2.0/build/x86_64-pc-linux-gnu/libstdc++-v3':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details.
make[1]: *** [configure-target-libstdc++-v3] Error 1
make[1]: Leaving directory `/mnt/lfs/sources/gcc-8.2.0/build'
make: *** [all] Error 2//
If I don't delete '/mnt/minlinux/sources/gcc-8.2.0' after 5.8, then once
again I get roughly 1.5 hours into 5.10 before hitting the following:

[discarding, investigating the results of a false build is not
useful :-( ]
So what the hell am I doing wrong?! MTIA :-)

If you have not deleted the extracted source after each step, that
in itself will break the build.  If the problem persists (the "cannot
run C compiled programs" above) look at config.log [ warning: there
might be more than one in gcc, binutils, and some other packages ]
and find that error message, then look at the lines above it to see
what the actual error reported was.  There will be a skeletal C
program, an attempt to link it and run it, and an error from that -
probably the link failed for some reason.

Unless the reason is obvious (years ago I was scripting for several
machines and accidentally included a ppc-specific item in my CFLAGS,
which x86 or x86_64 did not understand, and that was obvious when I
saw it) please report the actual error.

NB configure mostly runs a series of code fragments to find out about
the system, many of these will fail and that is fine, it is only the
code which caused "cannot run C compiled programs" to be reported
which is initially of interest. [ 'initially' because very rarely
something before the error is implicated, but that seems unlikely at
this early stage in LFS ]

ĸen
--
http://lists.linuxfromscratch.org/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/blfs/faq.html
Unsubscribe: See the above information page

Do not top post on this list.

A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?

http://en.wikipedia.org/wiki/Posting_style

Reply via email to