On 8/5/06, George Boudreau <[EMAIL PROTECTED]> wrote:
  Valid point, and the reason it never failed here is chroot resides in
/usr/bin  (I know.. bad George, bad) So a solution is find out where
chroot is and enter the full path.

You know, I finally gave up on the /bin vs. /sbin thing on my home box
and just gave all my users the full PATH. It's not like having an
executable outside of PATH is some kind of security initiative. But
this was on anduin where I have the "safe" PATH.

   # Add chroot commands
   CHROOT_LOC="`whereis -b chroot | cut -d " " -f2`"   <--NEW
   i=1
   for file in chapter06/*chroot* ; do
     chroot=`cat $file | sed -e "[EMAIL PROTECTED]@$CHROOT_LOC@" | \  <--NEW
                         sed -e '/#!\/bin\/sh/d' \
                             -e 's@ \\\@ @g' | tr -d '\n' | \
                        sed -e 's/  */ /g' \
                            -e 's|\\$|&&|g' \
                            -e 's|exit||g' \
                            -e 's|$| -c|' \
                            -e 's|"$$LFS"|$(MOUNT_PT)|' \
                            -e 's|set -e||'`

That would work. Another would be to just say "You need a path
including /sbin and /usr/sbin" in the README.

--
Dan
--
http://linuxfromscratch.org/mailman/listinfo/alfs-discuss
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to