LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 07-20-2005, 06:06 AM   #1
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,695

Rep: Reputation: 56
LFS 6.1 - Tricks and problems


Hi folks,

I encountered following problems on continue building LFS 6.1

1)
5.5. Linux-Libc-Headers-2.6.11.2
http://www.linuxfromscratch.org/lfs/...c-headers.html

lfs:/mnt/lfs/sources/gcc-build$ cd ../
lfs:/mnt/lfs/sources$ tar xjf linux-libc-headers-2.6.11.2.tar.bz2
lfs:/mnt/lfs/sources$ cp -R include/asm-i386 /tools/include/asm
Code:
 
cp: cannot stat `include/asm-i386': No such file or directory
It did not work

lfs:/mnt/lfs/sources$ cp -R linux-libc-headers-2.6.11.2/include/asm-i386 /tools/include/asm
It worked with no complaint

lfs:/mnt/lfs/sources$ cp -R include/linux /tools/include
Code:
cp: cannot stat `include/linux': No such file or directory
It did not work

lfs:/mnt/lfs/sources$ cp -R linux-libc-headers-2.6.11.2/include/linux /tools/include
It worked with no complaint

Did I make mistakes here???


2)
5.6. Glibc-2.3.4
http://www.linuxfromscratch.org/lfs/...r05/glibc.html

lfs:/mnt/lfs/sources$ patch -Np1 -i glibc-2.3.4-fix_test-1.patch
Code:
can't find file to patch at input line 11
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|Submitted By: Archaic (archaic -aT- linuxfromscratch -DoT- org)
|Date: 2005-04-27
|Initial Package Version: 2.3.4
|Origin: http://sources.redhat.com/ml/libc-al.../msg00056.html
|Upstream Status: Applied
|Description: Allows tst-cancel17 and tst-cancelx17 to pass with kernel-2.6.11.x
|
|diff -Naur glibc-2.3.5.orig/nptl/tst-cancel17.c glibc-2.3.5/nptl/tst-cancel17.c
|--- glibc-2.3.5.orig/nptl/tst-cancel17.c       2003-08-08 02:09:57.000000000 -0500
|+++ glibc-2.3.5/nptl/tst-cancel17.c    2005-04-27 10:46:26.000000000 -0500
--------------------------
File to patch: glibc-2.3.4.tar.bz2
Code:
patching file glibc-2.3.4.tar.bz2
Hunk #1 FAILED at 1.
Hunk #2 FAILED at 228.
2 out of 2 hunks FAILED -- saving rejects to file glibc-2.3.4.tar.bz2.rej
cat /mnt/lfs/sources/glibc-2.3.4.tar.bz2.rej
Code:
***************
*** 1,4 ****
- /* Copyright (C) 2003 Free Software Foundation, Inc.
     This file is part of the GNU C Library.
     Contributed by Ulrich Drepper <drepper@redhat.com>, 2003.
  
--- 1,4 ----
+ /* Copyright (C) 2003, 2005 Free Software Foundation, Inc.
     This file is part of the GNU C Library.
     Contributed by Ulrich Drepper <drepper@redhat.com>, 2003.
  
***************
*** 228,234 ****
  
    size_t len2 = fpathconf (fds[1], _PC_PIPE_BUF);
    size_t page_size = sysconf (_SC_PAGESIZE);
-   len2 = (len2 < page_size ? page_size : len2) + sizeof (mem) + 1;
    char *mem2 = malloc (len2);
    if (mem2 == NULL)
      {
--- 228,234 ----
  
    size_t len2 = fpathconf (fds[1], _PC_PIPE_BUF);
    size_t page_size = sysconf (_SC_PAGESIZE);
+   len2 = 20 * (len2 < page_size ? page_size : len2) + sizeof (mem) + 1;
    char *mem2 = malloc (len2);
    if (mem2 == NULL)
      {
Please advise how to fix it. TIA

B.R.
satimis
 
Old 07-20-2005, 07:11 AM   #2
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,695

Original Poster
Rep: Reputation: 56
Hi folks,

Further to point 2) on my first posting, I left out extracting the tarball. I repeated this step and subsequent steps as follows;

lfs:/mnt/lfs/sources$ tar xjf glibc-2.3.4.tar.bz2
lfs:/mnt/lfs/sources$ patch -Np1 -i glibc-2.3.4-fix_test-1.patch
Code:
can't find file to patch at input line 11
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|Submitted By: Archaic (archaic -aT- linuxfromscratch -DoT- org)
|Date: 2005-04-27
|Initial Package Version: 2.3.4
|Origin: http://sources.redhat.com/ml/libc-al.../msg00056.html
|Upstream Status: Applied
|Description: Allows tst-cancel17 and tst-cancelx17 to pass with kernel-2.6.11.x
|
|diff -Naur glibc-2.3.5.orig/nptl/tst-cancel17.c glibc-2.3.5/nptl/tst-cancel17.c
|--- glibc-2.3.5.orig/nptl/tst-cancel17.c       2003-08-08 02:09:57.000000000 -0500
|+++ glibc-2.3.5/nptl/tst-cancel17.c    2005-04-27 10:46:26.000000000 -0500
--------------------------
File to patch: glibc-2.3.4
patch: **** File glibc-2.3.4 is not a regular file -- can't patch
Tried again;
lfs:/mnt/lfs/sources$ patch -Np1 -i glibc-2.3.4-fix_test-1.patch
Code:
can't find file to patch at input line 11
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|Submitted By: Archaic (archaic -aT- linuxfromscratch -DoT- org)
|Date: 2005-04-27
|Initial Package Version: 2.3.4
|Origin: http://sources.redhat.com/ml/libc-al.../msg00056.html
|Upstream Status: Applied
|Description: Allows tst-cancel17 and tst-cancelx17 to pass with kernel-2.6.11.x
|
|diff -Naur glibc-2.3.5.orig/nptl/tst-cancel17.c glibc-2.3.5/nptl/tst-cancel17.c
|--- glibc-2.3.5.orig/nptl/tst-cancel17.c       2003-08-08 02:09:57.000000000 -0500
|+++ glibc-2.3.5/nptl/tst-cancel17.c    2005-04-27 10:46:26.000000000 -0500
--------------------------
File to patch:
Skip this patch? [y] y
Skipping patch.
2 out of 2 hunks ignored
lfs:/mnt/lfs/sources$

Stil the same result procured. Which file I have to patch?

TIA

B.R.
satimis
 
Old 07-20-2005, 08:43 AM   #3
kjordan
Member
 
Registered: Jul 2004
Distribution: LFS, I felt the itch and scratched it
Posts: 227

Rep: Reputation: 31
You're forgetting to enter the source directory again.

lfs:/mnt/lfs/sources$ tar xjf glibc-2.3.4.tar.bz2
lfs:/mnt/lfs/sources$ cd glibc-2.3.4
lfs:/mnt/lfs/sources/glibc-2.3.4$ patch -Np1 -i glibc-2.3.4-fix_test-1.patch

Last edited by kjordan; 07-20-2005 at 08:44 AM.
 
Old 07-20-2005, 08:50 AM   #4
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,695

Original Poster
Rep: Reputation: 56
Hi kjordan,

Tks for your advice.

I got it. I'm now running "make check"

Steps performed as follows;

lfs:/mnt/lfs/sources$ tar xjf glibc-2.3.4.tar.bz2
lfs:/mnt/lfs/sources$ cd glibc-2.3.4
lfs:/mnt/lfs/sources/glibc-2.3.4$ patch -Np1 -i ../glibc-2.3.4-fix_test-1.patch
patching file nptl/tst-cancel17.c
lfs:/mnt/lfs/sources/glibc-2.3.4$ cd ../glibc-build
lfs:/mnt/lfs/sources/glibc-build$ ../glibc-2.3.4/configure --prefix=/tools --disable-profile --enable-add-ons --enable-kernel=2.6.0 --with-binutils=/tools/bin --without-gd --with-headers=/tools/include --without-selinux
lfs:/mnt/lfs/sources/glibc-build$ make
lfs:/mnt/lfs/sources/glibc-build$ make check........

Have you had any comment on point 1) of my first posting.

B.R.
satimis
 
Old 07-20-2005, 09:39 AM   #5
kjordan
Member
 
Registered: Jul 2004
Distribution: LFS, I felt the itch and scratched it
Posts: 227

Rep: Reputation: 31
Same problem, you had to be in the directory.


lfs:/mnt/lfs/sources/gcc-build$ cd ../
lfs:/mnt/lfs/sources$ tar xjf linux-libc-headers-2.6.11.2.tar.bz2
lfs:/mnt/lfs/sources$ cd linux-libc-headers-2.6.11.2
lfs:/mnt/lfs/sources/linux-libc-headers-2.6.11.2$ cp -R include/asm-i386 /tools/include/asm
 
Old 07-20-2005, 09:58 AM   #6
satimis
Senior Member
 
Registered: Apr 2003
Posts: 3,695

Original Poster
Rep: Reputation: 56
Hi kjordan,

Tks for your advice.

Quote:
Same problem, you had to be in the directory.

lfs:/mnt/lfs/sources/gcc-build$ cd ../
lfs:/mnt/lfs/sources$ tar xjf linux-libc-headers-2.6.11.2.tar.bz2
lfs:/mnt/lfs/sources$ cd linux-libc-headers-2.6.11.2
lfs:/mnt/lfs/sources/linux-libc-headers-2.6.11.2$ cp -R include/asm-i386 /tools/include/asm
Noted

I figured out to run those commands without changing directories. But I could not figure out a solution to run the patch if not changing to the respective directory.

Now went through this Section and 5.7. Adjusting the Toolchain
http://www.linuxfromscratch.org/lfs/...adjusting.html

without problem. I'll move on to 5.8

B.R.
satimis
 
  


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
LFS Book Chapter 6 - 1st step (chroot to /mnt/lfs) doens't work bauld Linux From Scratch 11 03-15-2006 01:31 AM
LFS-7.0-cross-lfs-20050902-x86_64-Multilib Basel Linux From Scratch 0 09-03-2005 06:03 AM
problems configuring glibc-2.3.4-20040701 for LFS build dimaash Linux From Scratch 1 07-17-2005 10:00 AM
Problems with XawTV on new LFS Electrode Linux From Scratch 0 09-15-2003 06:50 PM
LFS Problems RecoilUK Linux - Software 1 12-22-2001 04:51 PM

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

All times are GMT -5. The time now is 01:52 AM.

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
Open Source Consulting | Domain Registration