LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
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


Reply
  Search this Thread
Old 03-30-2014, 11:18 AM   #1
luke11
LQ Newbie
 
Registered: Mar 2014
Posts: 11

Rep: Reputation: Disabled
LFS 7.5 - Stage 5.5


Cannot prepare gcc for compilation, the Konsole output says it can't find crti.o file AND, for some reason, it seems to try executing the parametres as a commands:
Code:
If '-target' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf -target
Code:
If '-prefix' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf -prefix
My host system is OpenSUSE 13.1 with KDE.

Sorry, if my post might seem naive, for i'm newbie.
 
Old 03-30-2014, 12:47 PM   #2
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Linux From Scratch, Slackware64, Partedmagic
Posts: 2,651

Rep: Reputation: 660Reputation: 660Reputation: 660Reputation: 660Reputation: 660Reputation: 660
What exactly did you type? looks like a typo to me
 
Old 03-30-2014, 12:52 PM   #3
luke11
LQ Newbie
 
Registered: Mar 2014
Posts: 11

Original Poster
Rep: Reputation: Disabled
Quote:
What exactly did you type? looks like a typo to me
Just exactly what's in the book. Sorry, I'll post the console output tomorrow.

Last edited by luke11; 03-30-2014 at 12:54 PM.
 
Old 03-30-2014, 01:09 PM   #4
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Linux From Scratch, Slackware64, Partedmagic
Posts: 2,651

Rep: Reputation: 660Reputation: 660Reputation: 660Reputation: 660Reputation: 660Reputation: 660
its this bit
Quote:
If '-target' is not a typo
that makes me think its a typo you may have thought you typed it correctly but unless you paste in EXACTLY what you typed we can't really help , though I get the impression you are not at your machine at the meoment and can't do that.

Both the -target AND the -prefix is wrong it should be '--target' and '--prefix'
 
Old 03-30-2014, 01:11 PM   #5
luisfpetrucci
LQ Newbie
 
Registered: Mar 2014
Location: Colombia
Distribution: Fedora
Posts: 11

Rep: Reputation: Disabled
Hello, are you copying and pasting? be careful with that if you are building a lfs.
 
Old 03-30-2014, 09:03 PM   #6
ReaperX7
LQ Guru
 
Registered: Jul 2011
Location: California
Distribution: Slackware64-Current
Posts: 6,442
Blog Entries: 15

Rep: Reputation: 2007Reputation: 2007Reputation: 2007Reputation: 2007Reputation: 2007Reputation: 2007Reputation: 2007Reputation: 2007Reputation: 2007Reputation: 2007Reputation: 2007
Check your environment with

Code:
echo $LFS
first to see if the environment path is set. If it's not, reset it with:

Code:
export LFS=/mnt/lfs
and try again.
 
Old 04-01-2014, 11:02 AM   #7
luke11
LQ Newbie
 
Registered: Mar 2014
Posts: 11

Original Poster
Rep: Reputation: Disabled
So I'm back with my problem
Code:
config.status: creating Makefile
linux-xwp9:/mnt/lfs/sources/gcc-build # --target=$LFS_TGT
If '--target=' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --target=
linux-xwp9:/mnt/lfs/sources/gcc-build # --prefix=/tools
-bash: --prefix=/tools: No such file or directory
linux-xwp9:/mnt/lfs/sources/gcc-build # --with-sysroot=$LFS
If '--with-sysroot=' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --with-sysroot=
linux-xwp9:/mnt/lfs/sources/gcc-build # --with-newlib
If '--with-newlib' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --with-newlib
linux-xwp9:/mnt/lfs/sources/gcc-build # --without-headers
If '--without-headers' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --without-headers
linux-xwp9:/mnt/lfs/sources/gcc-build # --with-local-prefix=/tools
-bash: --with-local-prefix=/tools: No such file or directory
linux-xwp9:/mnt/lfs/sources/gcc-build # --with-native-system-header-dir=/tools/include
-bash: --with-native-system-header-dir=/tools/include: No such file or directory
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-nls
If '--disable-nls' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-nls
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-shared
If '--disable-shared' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-shared
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-multilib
If '--disable-multilib' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-multilib
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-decimal-float
If '--disable-decimal-float' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-decimal-float
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-threads
If '--disable-threads' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-threads
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-libatomic
If '--disable-libatomic' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-libatomic
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-libgomp
If '--disable-libgomp' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-libgomp
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-libitm
If '--disable-libitm' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-libitm
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-libmudflap
If '--disable-libmudflap' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-libmudflap
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-libquadmath
If '--disable-libquadmath' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-libquadmath
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-libsanitizer
If '--disable-libsanitizer' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-libsanitizer
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-libssp
If '--disable-libssp' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-libssp
linux-xwp9:/mnt/lfs/sources/gcc-build # --disable-libstdc++-v3
If '--disable-libstdc++-v3' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-libstdc++-v3
linux-xwp9:/mnt/lfs/sources/gcc-build # --enable-languages=c,c++
If '--enable-languages=c,c++' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --enable-languages=c,c++
linux-xwp9:/mnt/lfs/sources/gcc-build # --with-mpfr-include=$(pwd)/../gcc-4.8.2/mpfr/src
-bash: --with-mpfr-include=/mnt/lfs/sources/gcc-build/../gcc-4.8.2/mpfr/src: No such file or directory
linux-xwp9:/mnt/lfs/sources/gcc-build # --with-mpfr-lib=$(pwd)/mpfr/src/.libs
-bash: --with-mpfr-lib=/mnt/lfs/sources/gcc-build/mpfr/src/.libs: No such file or directory
linux-xwp9:/mnt/lfs/sources/gcc-build # \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
> \
>
It actually generates makefile at "Prepare GCC for compilation" but for some reasons it tries to parse parametres as commands.
And yes, I've set the $LFS and 'echo $TGT_LFS' gives the proper output.

Last edited by luke11; 04-01-2014 at 11:04 AM.
 
Old 04-01-2014, 11:16 AM   #8
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Linux From Scratch, Slackware64, Partedmagic
Posts: 2,651

Rep: Reputation: 660Reputation: 660Reputation: 660Reputation: 660Reputation: 660Reputation: 660
you are obviously doing something wrong with the configure command, scroll back through your shell history and paste here EXACTLY what you have typed for the configure command.
 
Old 04-01-2014, 11:47 AM   #9
luke11
LQ Newbie
 
Registered: Mar 2014
Posts: 11

Original Poster
Rep: Reputation: Disabled
Well, now trying to configure binutils (stage 5.4.1) I got the same error:
Code:
config.status: creating Makefile
lfs:/mnt/lfs/sources/binutils-build$  \
> --prefix=/tools
bash: --prefix=/tools: No such file or directory
lfs:/mnt/lfs/sources/binutils-build$  \
> --with-sysroot=$LFS
bash: --with-sysroot=/mnt/lfs: No such file or directory
lfs:/mnt/lfs/sources/binutils-build$  \
> --with-lib-path=/tools/lib
bash: --with-lib-path=/tools/lib: No such file or directory
lfs:/mnt/lfs/sources/binutils-build$  \
> --target=$LFS_TGT
If '--target=i686-lfs-linux-gnu' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --target=i686-lfs-linux-gnu
lfs:/mnt/lfs/sources/binutils-build$  \
> --disable-nls
If '--disable-nls' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-nls
lfs:/mnt/lfs/sources/binutils-build$  \
> --disable-werror
If '--disable-werror' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf --disable-werror
lfs:/mnt/lfs/sources/binutils-build$ echo $LFS
/mnt/lfs
Just foolowing the book instructions.

Funny, re-typeing worked.

Last edited by luke11; 04-01-2014 at 11:53 AM.
 
Old 04-01-2014, 11:49 AM   #10
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Linux From Scratch, Slackware64, Partedmagic
Posts: 2,651

Rep: Reputation: 660Reputation: 660Reputation: 660Reputation: 660Reputation: 660Reputation: 660
If you don't post what you have typed we can't really help.
 
Old 04-01-2014, 12:54 PM   #11
luke11
LQ Newbie
 
Registered: Mar 2014
Posts: 11

Original Poster
Rep: Reputation: Disabled
Well, just compiled and installed successfully. What I've done: re-typed the configure script from the book instead copy-pasting it. Should I mark the topic as SOLVED?
 
Old 04-01-2014, 08:03 PM   #12
stoat
Member
 
Registered: May 2007
Distribution: LFS
Posts: 615

Rep: Reputation: 180Reputation: 180
Yes. Mark it as solved. But I have a few parting comments.

As you certainly know, that configure command is one very long command that has been split into multiple lines with those "\" characters spaced over a bit at the end of each line. A possible explanation for the output shown in post #7 is that the terminal being copied from (or the one being copied to) was not maximized, or at least not large enough for each line pasted to be on one line. With the "\" characters possibly cut off, all of that stuff may have been run as commands (including all of the "\" characters themselves seen at the end of your posted output). Maybe not this time, but I promise that I have experienced that exact thing when copying the CA Certificates scripts in BLFS from Lynx in an umaximized terminal (watch out for that if you ever get to that point).

Anyway, a conclusion that you or future readers may form from all this is that copying & pasting is bad. That would be a wrong conclusion IMO. Copying & pasting cannot be done carelessly or mindlessly (which can happen after hours of doing it). IMO, it is not wrong, unmanly, or cheating to copy and paste. You still can read the commands, think about them, and learn from them. Then copy and paste them for speed and accuracy (if done carefully, like anything else). Of course type away if you like, but just don't let this bizarre incident create in your (or any other reader's) mind a possibly false cause for the effect.

Last edited by stoat; 04-01-2014 at 08:12 PM.
 
1 members found this post helpful.
Old 04-02-2014, 05:34 PM   #13
caffewmilk
LQ Newbie
 
Registered: Apr 2014
Location: Californ-i-a
Distribution: *ubuntu
Posts: 21
Blog Entries: 1

Rep: Reputation: Disabled
If you were copying-n-pasting from a PDF document, then it could've been the 'back tick' versus 'apostrophe' conversion in the process. I've ran into that myself and left me head scratching for a while. Very hard to debug.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] LFS 6.7 : $LFS/sources and $LFS/tools folders missing prakashsince92 Linux From Scratch 5 12-09-2010 02:26 PM
Completed the LFS construction, if there's a need to re-do the steps in stage 6 or 7, just.srad Linux From Scratch 4 09-19-2008 05:05 PM
malloc(): memory corruption: in first stage compile of gcc for lfs 6.3 Skazi Linux From Scratch 1 11-03-2007 12:36 AM
Half of my applications are broken. I am using Gentoo stage 1 on 3 nptl (stage 1.5) dragonslay Linux - Games 3 04-01-2005 05:23 PM
Gentoo: Stage 1, Stage 2, or Stage 3 skorpi0wn Linux - Distributions 3 03-01-2005 07:47 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 12:13 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration