LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux From Scratch (https://www.linuxquestions.org/questions/linux-from-scratch-13/)
-   -   Problem with Adjusting ToolChain.... sed: can't read >: No such file or directory (https://www.linuxquestions.org/questions/linux-from-scratch-13/problem-with-adjusting-toolchain-sed-cant-read-no-such-file-or-directory-618998/)

lfs_rocks 02-06-2008 12:49 AM

Problem with Adjusting ToolChain.... sed: can't read >: No such file or directory
 
Hi all

i am at the chapter 5.7 Adjusting Tool Chain of the book LFS 6.3
when i run the following command i am getting error...
Quote:

gcc -dumpspecs | sed 's@^/lib/ld-linux.so.2@/tools&@g' \
> `dirname $(gcc -print-libgcc-file-name)`/specs
---------
ERROR
---------
Quote:

lfs@boss:/mnt/lfs/sources$ gcc -dumpspecs | sed 's@^/lib/ld-linux.so.2@/tools&@g' \> `dirname $(gcc -print-libgcc-file-name)`/specs
sed: can't read >: No such file or directory
sed: can't read /mnt/lfs/tools/bin/../lib/gcc/i686-pc-linux-gnu/4.1.2/specs: No such file or directory
lfs@boss:/mnt/lfs/sources$
faqs say that it may be due to
With the new Ch 5 build procedure, the most common cause of this problem is forgetting to apply the specs patch.

but how to apply the specs path....??

Please help me to resolve this problem

THANKS IN ADVANCE

druuna 02-06-2008 03:56 AM

Hi,

The command you entered is not correct:
gcc -dumpspecs | sed 's@^/lib/ld-linux.so.2@/tools&@g' \> `dirname $(gcc -print-libgcc-file-name)`/specs

It should be:
gcc -dumpspecs | sed 's@^/lib/ld-linux.so.2@/tools&@g' > `dirname $(gcc -print-libgcc-file-name)`/specs

or

gcc -dumpspecs | sed 's@^/lib/ld-linux.so.2@/tools&@g' \
> `dirname $(gcc -print-libgcc-file-name)`/specs


The command given in the book is spread over 2 lines, which can only be done with the \ on the end of the first line, it is not needed if you put all on one line. It will work, but then you need a space betwee the \ and the > (which your command lacks).

Another question: Did you solve all other problems you had before, especially the glibc one?? There's no point in continuing if you did not solve them.

Hope this helps.

lfs_rocks 02-06-2008 10:36 AM

Quote:

Originally Posted by druuna (Post 3047693)

Another question: Did you solve all other problems you had before, especially the glibc one?? There's no point in continuing if you did not solve them.

Hope this helps.

i didnt get any error for glibc make after doing everything from beginning...
but i am getting two errors during the glibc make check.... in the ebook its given that make check error can be neglected at this stage and shud be saved for future reference....


notes given in the lfs 6.3 ebook
Quote:

Glibc test suite failures in this chapter are typically not worrisome.
When experiencing a failure, make a note of it, then continue by reissuing the make check command. The test suite should pick up where it left off and continue. This stop-start sequence can be circumvented by issuing a make -k check command. If using this option, be sure to log the output so that the log file can be examined for failures later.
make check errors....
Quote:

/tools/bin/ld: cannot find -lstdc++
collect2: ld returned 1 exit status
make[2]: *** [/mnt/lfs/sources/glibc-build/dlfcn/bug-atexit3-lib.so] Error 1
make[2]: Target `tests' not remade because of errors.
make[1]: *** [dlfcn/tests] Error 2
/tools/bin/ld: cannot find -lstdc++
collect2: ld returned 1 exit status
make[2]: *** [/mnt/lfs/sources/glibc-build/nptl/tst-cancel24] Error 1
make[2]: Target `tests' not remade because of errors.
make[1]: *** [nptl/tests] Error 2
make[1]: Target `check' not remade because of errors.
make: *** [check] Error 2
i have succesfully installed glibc in spite of these errors for make check...

Please let me know if i am doing any mistake in neglecting these errors...

druuna 02-06-2008 12:44 PM

Hi,

I personally don't use the make check part in all of chapter 5 (I do believe the LFS book mentions this somewhere). I do use it in chapter 6!

Just keep going if make check is the only part that gives you problems.

zzypty 03-08-2009 10:30 AM

Problems in section 5.7
 
Hi!

@ lfs_rocks :
If you are having trouble in section 5.7 (with the glibc), do see this post.

HTH


All times are GMT -5. The time now is 08:47 PM.