[lfs-support] How to upgrade a single package?

2013-01-03 Thread JIA Pei
Hi, all:

sorry for my naive question again.
I now noticed coreutils has been upgraded from 8.19 to 8.20 . I'd love to
upgrade it without rebuilding everything from scratch, but just this single
package.

I can always chroot into the environment required by chapter 6, but how can
I re-enter chapter 5 to prepare the tools coreutils using version 8.20
rather than version 8.19 ?



Cheers




-- 

Pei JIA

Email: jp4w...@gmail.com
cell:+1 604-362-5816

Welcome to Vision Open
http://www.visionopen.com
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: [lfs-support] How to upgrade a single package?

2013-01-03 Thread Chris Staub
On 01/03/2013 04:13 AM, JIA Pei wrote:

 Hi, all:

 sorry for my naive question again.
 I now noticed coreutils has been upgraded from 8.19 to 8.20 . I'd love
 to upgrade it without rebuilding everything from scratch, but just this
 single package.

 I can always chroot into the environment required by chapter 6, but how
 can I re-enter chapter 5 to prepare the tools coreutils using version
 8.20 rather than version 8.19 ?

You can't even get a basic LFS system built right, you don't have any 
hope of successfully upgrading anything. Further, you've asked one 
question (how to upgrade a package) that's answered in the FAQ, and 
another (how to re-enter chroot) that's answered in the book itself.
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: [lfs-support] How to upgrade a single package?

2013-01-03 Thread JIA Pei
Hi, Chris:

I understand now.. The reason why I'm asking this question is because
yesterday I was preparing the tools in Chapter 5 using coreutils-8.19, but
today, the SVN manual has already been changed to coreutils-8.20 , however,
I still haven't finished chapter 6 yet...

But, I guess I got what you mean . I found release 7.2 which is also using
coreutils-8.19. I may be able to continue and finish building the whole
system first, before upgrading coreutils-8.19 to 8.20 ...


Cheers





On Thu, Jan 3, 2013 at 1:42 AM, Chris Staub ch...@beaker67.com wrote:

 On 01/03/2013 04:13 AM, JIA Pei wrote:
 
  Hi, all:
 
  sorry for my naive question again.
  I now noticed coreutils has been upgraded from 8.19 to 8.20 . I'd love
  to upgrade it without rebuilding everything from scratch, but just this
  single package.
 
  I can always chroot into the environment required by chapter 6, but how
  can I re-enter chapter 5 to prepare the tools coreutils using version
  8.20 rather than version 8.19 ?

 You can't even get a basic LFS system built right, you don't have any
 hope of successfully upgrading anything. Further, you've asked one
 question (how to upgrade a package) that's answered in the FAQ, and
 another (how to re-enter chroot) that's answered in the book itself.
 --
 http://linuxfromscratch.org/mailman/listinfo/lfs-support
 FAQ: http://www.linuxfromscratch.org/lfs/faq.html
 Unsubscribe: See the above information page




-- 

Pei JIA

Email: jp4w...@gmail.com
cell:+1 604-362-5816

Welcome to Vision Open
http://www.visionopen.com
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


[lfs-support] Step 5.7 -- ld: cannot find crt1.o

2013-01-03 Thread Chris J. Breisch
This is most likely an FAQ, and I apologize for that. But the mail 
archives seem to be having issues. Using webcache and search engines, 
I've been able to find where some people have asked about this or 
something similar, but I haven't been able to find the answers.

Anyway, after doing the make install of glibc-2.16.0 as directed in step 
5.7, I attempt to compile a dummy C program to test the toolchain.

  echo 'main(){}'  dummy.c
  $LFS_TGT-gcc dummy.c

This fails as the linker is unable to find crt1.o. Here's the relevant 
section of output from $LFS_TGT-gcc -v:

COMPILER_PATH=/mnt/lfs/tools/bin/../libexec/gcc/x86_64-lfs-linux-gnu/4.7.1/:/mnt/lfs/tools/bin/../libexec/gcc/:/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/../../../../x86_64-lfs-linux-gnu/bin/
LIBRARY_PATH=/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/:/mnt/lfs/tools/bin/../lib/gcc/:/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/../../../../x86_64-lfs-linux-gnu/lib/:/mnt/lfs/tools/lib
COLLECT_GCC_OPTIONS='-v' '-mtune=generic' '-march=x86-64'
  /mnt/lfs/tools/bin/../libexec/gcc/x86_64-lfs-linux-gnu/4.7.1/collect2 
--sysroot=/mnt/lfs --eh-frame-hdr -m elf_x86_64 -dynamic-linker 
/tools/lib64/ld-linux-x86-64.so.2 crt1.o crti.o 
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/crtbegin.o 
-L/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1 
-L/mnt/lfs/tools/bin/../lib/gcc 
-L/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/../../../../x86_64-lfs-linux-gnu/lib
 
-L/mnt/lfs/tools/lib /tmp/ccBLVS1U.o -lgcc -lc -lgcc 
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/crtend.o crtn.o
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/../../../../x86_64-lfs-linux-gnu/bin/ld:
 
cannot find crt1.o: No such file or directory
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/../../../../x86_64-lfs-linux-gnu/bin/ld:
 
cannot find crti.o: No such file or directory

The install of glibc placed it in /tools/lib, and supplying that info on 
the command line (-B/tools/lib) allows the compile to succeed:

COMPILER_PATH=/tools/lib/:/mnt/lfs/tools/bin/../libexec/gcc/x86_64-lfs-linux-gnu/4.7.1/:/mnt/lfs/tools/bin/../libexec/gcc/:/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/../../../../x86_64-lfs-linux-gnu/bin/
LIBRARY_PATH=/tools/lib/:/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/:/mnt/lfs/tools/bin/../lib/gcc/:/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/../../../../x86_64-lfs-linux-gnu/lib/:/mnt/lfs/tools/lib
COLLECT_GCC_OPTIONS='-v' '-B' '/tools/lib' '-mtune=generic' '-march=x86-64'
  /mnt/lfs/tools/bin/../libexec/gcc/x86_64-lfs-linux-gnu/4.7.1/collect2 
--sysroot=/mnt/lfs --eh-frame-hdr -m elf_x86_64 -dynamic-linker 
/tools/lib64/ld-linux-x86-64.so.2 /tools/lib/crt1.o /tools/lib/crti.o 
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/crtbegin.o 
-L/tools/lib -L/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1 
-L/mnt/lfs/tools/bin/../lib/gcc 
-L/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/../../../../x86_64-lfs-linux-gnu/lib
 
-L/mnt/lfs/tools/lib /tmp/ccfKHIb7.o -lgcc -lc -lgcc 
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/crtend.o 
/tools/lib/crtn.o

Using -B/mnt/lfs/tools/lib also works, as expected:

COMPILER_PATH=/mnt/lfs/tools/lib/:/mnt/lfs/tools/bin/../libexec/gcc/x86_64-lfs-linux-gnu/4.7.1/:/mnt/lfs/tools/bin/../libexec/gcc/:/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/../../../../x86_64-lfs-linux-gnu/bin/
LIBRARY_PATH=/mnt/lfs/tools/lib/:/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/:/mnt/lfs/tools/bin/../lib/gcc/:/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/../../../../x86_64-lfs-linux-gnu/lib/:/mnt/lfs/tools/lib
COLLECT_GCC_OPTIONS='-v' '-B' '/mnt/lfs/tools/lib' '-mtune=generic' 
'-march=x86-64'
  /mnt/lfs/tools/bin/../libexec/gcc/x86_64-lfs-linux-gnu/4.7.1/collect2 
--sysroot=/mnt/lfs --eh-frame-hdr -m elf_x86_64 -dynamic-linker 
/tools/lib64/ld-linux-x86-64.so.2 /mnt/lfs/tools/lib/crt1.o 
/mnt/lfs/tools/lib/crti.o 
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/crtbegin.o 
-L/mnt/lfs/tools/lib 
-L/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1 
-L/mnt/lfs/tools/bin/../lib/gcc 
-L/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/../../../../x86_64-lfs-linux-gnu/lib
 
-L/mnt/lfs/tools/lib /tmp/ccOcNwMs.o -lgcc -lc -lgcc 
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.1/crtend.o 
/mnt/lfs/tools/lib/crtn.o

So, clearly the problem is that ld isn't looking for crt1.o where it 
resides. Obviously, I've done something wrong on a preceding step, but 
I'm unable to find it.

But I don't know which step is wrong. Did make install of glibc install 
it in the wrong place? Is ld looking in the wrong place? Did gcc tell ld 
to look in the wrong place? I see that gcc did supply 
-L/mnt/lfs/tools/lib to ld, which clearly didn't help for the .o files, 
but only for libraries.

Now, I could go on, ignoring this issue. Compiling binutils again is 

Re: [lfs-support] Step 5.7 -- ld: cannot find crt1.o

2013-01-03 Thread Baho Utot
Chris J. Breisch wrote:

[putolin]


 So, clearly the problem is that ld isn't looking for crt1.o where it
 resides. Obviously, I've done something wrong on a preceding step, but
 I'm unable to find it.

 But I don't know which step is wrong. Did make install of glibc install
 it in the wrong place? Is ld looking in the wrong place? Did gcc tell ld
 to look in the wrong place? I see that gcc did supply
 -L/mnt/lfs/tools/lib to ld, which clearly didn't help for the .o files,
 but only for libraries.

 Now, I could go on, ignoring this issue. Compiling binutils again is
 next, and I'm pretty sure I can pass appropriate options to configure to
 enable binutils to compile properly. But I'm worried that this will
 cause problems farther down the line, so I'd prefer to fix this cleanly
 now, rather than continue to jump through hoops as the build progresses.

 Any thoughts?


Check the tools symlink
ls -l /tools
should output something like this:  tools - /mnt/lfs/tools/

Make sure it points to /mnt/lfs/tools, if it doesn't then you will need 
to fix that and redo chapter 5.


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


Re: [lfs-support] Step 5.7 -- ld: cannot find crt1.o

2013-01-03 Thread Chris J. Breisch
On 1/3/2013 8:44 AM, Baho Utot wrote:
 Check the tools symlink
 ls -l /tools
 should output something like this:  tools - /mnt/lfs/tools/

It does.


-- 

Chris J. Breischhttp://www.sports-gazer.com
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: [lfs-support] Step 5.7 -- ld: cannot find crt1.o

2013-01-03 Thread Baho Utot
Chris J. Breisch wrote:
 On 1/3/2013 8:44 AM, Baho Utot wrote:
 Check the tools symlink
 ls -l /tools
 should output something like this:  tools - /mnt/lfs/tools/

 It does.


crt1.o is part of the glibc package, you should review the installation 
of that package.
Make sure the environment is correct and that you are the lfs user.

Do a set at the bash prompt and have a look at the bash environment, ie 
PATH LC_ALL LFS LFS_TGT
Check LFS_TGT and compare it to what chapter 4.4.

set | grep PATH
set | grep LFS_TGT
set | grep SHELLOPTS should not have hashall in that line

I got that package wrong before also,  before I scripted my builds.
In my experience this is generally related to the bash environment or 
the host system requirements.
Try running the version-check.sh from the beginning of the book.



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


[lfs-support] Issues compiling File 5.10

2013-01-03 Thread Prudhomme, Harold
I have tried compiling File-5.10 and 5.11 and both keep coming up with
the same errors: 

 

/tools/lib/gcc/x86_64-unknown-linux-gnu/4.6.2/../../../../x86_64-unknown
-linux-gnu/bin/ld: /usr/lib/libz.a(inflate.o): relocation R_x86_64_32S
against `zcalloc` could not be used when making a shared object;
recompile with -fPIC

 

/usr/lib/libz.a: could not read symbols: Bad value

 

Collect2: ld returned 1 exit status

 

Make[2]: *** [libmagic.la] Error 1

Make[2]: Leaving directory `/sources/file-5.10/src'

Make[1]: *** [all-recursive] Error 1

Make[1]: Leaving directory `/sources/file-5.10'

Make: *** [all] Error 2

 

I did see when doing a google search that this was in the mail list
archives but for some reason when I try to access it the page will not
load and the browser tells me that the page cannot be found.  Any help
on this would be great.

 

Thanks

Harold

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


Re: [lfs-support] Step 5.7 -- ld: cannot find crt1.o

2013-01-03 Thread Chris J. Breisch
On 1/3/2013 9:50 AM, Baho Utot wrote:

 crt1.o is part of the glibc package, you should review the installation
 of that package.
 Make sure the environment is correct and that you are the lfs user.

 Do a set at the bash prompt and have a look at the bash environment, ie
 PATH LC_ALL LFS LFS_TGT
 Check LFS_TGT and compare it to what chapter 4.4.

 set | grep PATH
 set | grep LFS_TGT
 set | grep SHELLOPTS should not have hashall in that line

 I got that package wrong before also,  before I scripted my builds.
 In my experience this is generally related to the bash environment or
 the host system requirements.
 Try running the version-check.sh from the beginning of the book.


Thanks. Everything checks out from an environment and version 
standpoint. I am running gcc-4.7.2 which is listed as untested, I can 
probably drop back to an earlier version if I have to do so.

I think at this point I'm just going to start over. Haven't really done 
that much yet, and since I've clearly missed something obscure 
somewhere, it's probably easier to wipe the slate clean than to try to 
figure out what it is.

Thanks again.

-- 

Chris J. Breischhttp://www.sports-gazer.com
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: [lfs-support] Issues compiling File 5.10

2013-01-03 Thread Ken Moffat
On Thu, Jan 03, 2013 at 09:01:18AM -0600, Prudhomme, Harold wrote:
 I have tried compiling File-5.10 and 5.11 and both keep coming up with
 the same errors: 
 
  
 
 /tools/lib/gcc/x86_64-unknown-linux-gnu/4.6.2/../../../../x86_64-unknown
 -linux-gnu/bin/ld: /usr/lib/libz.a(inflate.o): relocation R_x86_64_32S
 against `zcalloc` could not be used when making a shared object;
 recompile with -fPIC
 
  
 
 /usr/lib/libz.a: could not read symbols: Bad value

 On x86_64 a static library cannot be linked into a shared object.
At one time a lot of BLFS programs needed to be recompiled with
CFLAGS including -fPIC passed to configure (or, in the really silly
cases, added into the Makefile).  But in this case I think you broke
libz.so : we move the library to /lib and need to fix up the
symlinks.  In this case, your symlink from /usr/lib is missing or
dangling.  On LFS-7.2 I have:
ken@jtm1 ~ $ls -l {/usr,}/lib/libz.so*
lrwxrwxrwx 1 root root 13 Nov 25 20:19 /lib/libz.so.1 - libz.so.1.2.7
-rwxr-xr-x 1 root root 124401 Nov 25 20:19 /lib/libz.so.1.2.7
lrwxrwxrwx 1 root root 23 Nov 25 20:19 /usr/lib/libz.so - 
../../lib/libz.so.1.2.7

ĸen
-- 
das eine Mal als Tragödie, das andere Mal als Farce
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: [lfs-support] How to upgrade a single package?

2013-01-03 Thread Bruce Dubbs
JIA Pei wrote:
 Hi, all:

 sorry for my naive question again.
 I now noticed coreutils has been upgraded from 8.19 to 8.20 . I'd love to
 upgrade it without rebuilding everything from scratch, but just this single
 package.

 I can always chroot into the environment required by chapter 6, but how can
 I re-enter chapter 5 to prepare the tools coreutils using version 8.20
 rather than version 8.19 ?

I wouldn't bother with Chapter 5.  Just enter chroot and follow the 
instructions in Chapter 6.

   -- Bruce
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page