On 10/08/2013 11:14 AM, Dan McGhee wrote: > On 10/07/2013 08:33 PM, Bruce Dubbs wrote: >> Ken Moffat wrote: >>> On Mon, Oct 07, 2013 at 11:59:00PM +0100, Ken Moffat wrote: >>>> The usual way to look at what gets installed is to run 'make >>>> DESTDIR=/path/to/somewhere install [ optional args ]' - once you get >>>> into DESTDIR installs for looking at what is installed you will find >>>> some packages use other variables (often INSTALLROOT or something >>>> like that) - if shadow is such a package,then running *as a user* >>>> will fail. So try it as a user, to a directory which that user can >>>> write to. >>>> >>> OK, so you can't try a DESTDIR install as a normal user because you >>> are root and 'su' doesn't exist. Build outside the new system as >>> user lfs and do a DESTDIR, e.g. to /home/lfs/somewhere or >>> /tmp/somewhere. The same for su from old coreutils (my notes show >>> that I had to build all of coreutils to get su linked - there might >>> be a shorter series of commands - but NOT which old version of >>> coreutils last contained 'su'. >> If the only thing needed is su, then I'd build shadow with: >> >> ./configure && make && cp src/su /tools/bin >> >> It doesn't need to be suid since it's run by root. >> >> -- Bruce >> > <SNIP> > I have su now in the tool chain. I won't need it until I get to CH. 6, > but with my OCD kicking in I wanted to build it just after coreutils in > CH. 5. I suppose it doesn't really make any difference, but... > <snip> I got to chroot and the copied su from shadow in Ch 5 didn't work. I can find no reason that it didn't. What I want to do now is compile it in chroot environment and install only it there. Just in case I missed some kind of linking. That seems unlikely, but....
ldd /tools/bin/su (on the copied version) provided: > linux-vdso.so.1 (0x00007ffff9b38000) > libcrypt.so.1 => /tools/lib/libcrypt.so.1 (0x00007f20fb668000) > libc.so.6 => /tools/lib/libc.so.6 (0x00007f20fb2b8000) > /tools/lib64/ld-linux-x86-64.so.2 (0x00007f20fb8a0000) as did ldd on my DESTDIR install, so it looks like everything is there. The two lines from the install log that I need are libtool: install: /usr/bin/install -c su /home/dan/LFS-7.4/shadow/bin/su and chmod -f 4755 /home/dan/LFS-7.4/shadow/bin/su; So after I compile I need either make install -c -m 0755 src/su /tools/bin or install -c -m 0755 src/su /tools/bin Which of the two commands will give me the necessary linking I need? Does it make a difference? Is the sytax correct. I apologize for being such a make and install dummy. It's just one of those things that I haven't gotten. BTW, I neither need nor want mode 4755 for the chroot environment. Thanks, Dan -- http://linuxfromscratch.org/mailman/listinfo/lfs-support FAQ: http://www.linuxfromscratch.org/lfs/faq.html Unsubscribe: See the above information page